Please help urgent due FRIDAY
I am working on coding a game in excel 2048. I haven’t used any macros or VBA’s and I have made I combined function for the movement and whether a 2 or 4 can spawn in that cell with an IF AND function. I finished off the function and everything seemed fine until i got the too many arguments alert. Sorry about how long the formula is. But i need an option as its due friday
=IF(AND($L$5=1,$M$5=2,F5<2),4,IF(AND($L$5=1,$M$5=1,F5<2),2,IF(AND(G10=”down”,F5=F6,F6<>F7,F7<>F8),0,IF(AND(G10=”down”,F6=0),0,IF(AND(G10=”down”,F6<>F5,F6=F7),0,IF(AND(G10=”down”,F6<>F5,F6<>F7,F7=F8),0,IF(AND(G10=”down”,F5<>F6,F7=0),0,IF(AND(G10=”down”,F5<>F6,F7<>F6,F8=0),0,IF(AND(G10=”right”,F5<>G5,G5<>H5,H5=I5),0,IF(AND(G10=”right”,F5<>G5,G5=H5),0,IF(AND(G10=”right”,F5=G5),0,IF(AND(G10=”right”,F5<>G5,G5<>H5,H5<>I5,I5=0),0,IF(AND(G10=”right”,F5<>G5,G5<>H5,G5=0),0,IF(AND(G10=”left”,F5<>G5,G5<>0),F5,IF(AND(G10=”left”,F5<>G5,G5=0,H5<>F5,H5=0,F5<>I5),F5,IF(AND(G10=”left”,F5<>G5,G5=0,F5<>H5,H5=0,F5=I5),F5+I5,IF(AND(G10=”left”,F5<>G5,G5=0,F5=H5),F5+H5,IF(AND(G10=”left”,F5<>G5,G5=0,F5<>H5,H5=0,F5<>I5),0,IF(AND(G10=”left”,F5=G5,f5>0),F5+G5,IF(AND(G10=”up”,F5=F6,f5>0),F5+F6,IF(AND(G10=”up”,F5<>F6,F6=0,F5=H5),F5+H5,IF(AND(G10=”up”,F5<>F6,F6=0,F5<>F7,F7=0,F5=F8),F5+F8,F5,IF(AND(g10=”left”,f5<>g5,f5=0,g5>0,h5<>g5,h5<>0),f5+g5,IF(AND(g10=”left”,f5<>g5,f5=0,g5>0,h5<>g5,h5=0,g5=i5),g5+I5,IF(and(g10=”left”,f5=0,g5=0,h5>0,i5<>h5),f5+h5,IF(AND(g10=”left”,f5=0,g5=0,h5=0,i5>0),f5+i5,IF(and(g10=”left”,f5=0,g5=h5,g5>0),g5+h5,IF(AND(g10=”left”,f5=0,g5=0,h5>0,i5=h5),i5+h5,IF(AND(g10=”up”,f5=0,f6>0,f7<>f6,f7<>0),f5+f6,IF(AND(g10=”up”,f5=0,f6=0,f7>0,f7<>f8),f5+f8,IF(AND(g10=”up”,f5=0,f6=0,f7=0,f8<>0),f5+f8,IF(AND(g10=”up”,f5=0,f6>0,f6=f7),f6+f7,IF(AND(g10=”up”,f5=0,f6=0,f7=0,f8>0),f5+f8,IF(AND(g10=”up”,f5=0,f6=f7,f6>0),f6+f7,IF(AND(g10=”up”,f5=0,f6>0,f7=0,f8=f6),f6+f8,IF(AND(g10=”up”,f5=0,f6=0,f7=f8),f7+f8,))))))))))))))))))))))))))))))))))))
I am working on coding a game in excel 2048. I haven’t used any macros or VBA’s and I have made I combined function for the movement and whether a 2 or 4 can spawn in that cell with an IF AND function. I finished off the function and everything seemed fine until i got the too many arguments alert. Sorry about how long the formula is. But i need an option as its due friday =IF(AND($L$5=1,$M$5=2,F5<2),4,IF(AND($L$5=1,$M$5=1,F5<2),2,IF(AND(G10=”down”,F5=F6,F6<>F7,F7<>F8),0,IF(AND(G10=”down”,F6=0),0,IF(AND(G10=”down”,F6<>F5,F6=F7),0,IF(AND(G10=”down”,F6<>F5,F6<>F7,F7=F8),0,IF(AND(G10=”down”,F5<>F6,F7=0),0,IF(AND(G10=”down”,F5<>F6,F7<>F6,F8=0),0,IF(AND(G10=”right”,F5<>G5,G5<>H5,H5=I5),0,IF(AND(G10=”right”,F5<>G5,G5=H5),0,IF(AND(G10=”right”,F5=G5),0,IF(AND(G10=”right”,F5<>G5,G5<>H5,H5<>I5,I5=0),0,IF(AND(G10=”right”,F5<>G5,G5<>H5,G5=0),0,IF(AND(G10=”left”,F5<>G5,G5<>0),F5,IF(AND(G10=”left”,F5<>G5,G5=0,H5<>F5,H5=0,F5<>I5),F5,IF(AND(G10=”left”,F5<>G5,G5=0,F5<>H5,H5=0,F5=I5),F5+I5,IF(AND(G10=”left”,F5<>G5,G5=0,F5=H5),F5+H5,IF(AND(G10=”left”,F5<>G5,G5=0,F5<>H5,H5=0,F5<>I5),0,IF(AND(G10=”left”,F5=G5,f5>0),F5+G5,IF(AND(G10=”up”,F5=F6,f5>0),F5+F6,IF(AND(G10=”up”,F5<>F6,F6=0,F5=H5),F5+H5,IF(AND(G10=”up”,F5<>F6,F6=0,F5<>F7,F7=0,F5=F8),F5+F8,F5,IF(AND(g10=”left”,f5<>g5,f5=0,g5>0,h5<>g5,h5<>0),f5+g5,IF(AND(g10=”left”,f5<>g5,f5=0,g5>0,h5<>g5,h5=0,g5=i5),g5+I5,IF(and(g10=”left”,f5=0,g5=0,h5>0,i5<>h5),f5+h5,IF(AND(g10=”left”,f5=0,g5=0,h5=0,i5>0),f5+i5,IF(and(g10=”left”,f5=0,g5=h5,g5>0),g5+h5,IF(AND(g10=”left”,f5=0,g5=0,h5>0,i5=h5),i5+h5,IF(AND(g10=”up”,f5=0,f6>0,f7<>f6,f7<>0),f5+f6,IF(AND(g10=”up”,f5=0,f6=0,f7>0,f7<>f8),f5+f8,IF(AND(g10=”up”,f5=0,f6=0,f7=0,f8<>0),f5+f8,IF(AND(g10=”up”,f5=0,f6>0,f6=f7),f6+f7,IF(AND(g10=”up”,f5=0,f6=0,f7=0,f8>0),f5+f8,IF(AND(g10=”up”,f5=0,f6=f7,f6>0),f6+f7,IF(AND(g10=”up”,f5=0,f6>0,f7=0,f8=f6),f6+f8,IF(AND(g10=”up”,f5=0,f6=0,f7=f8),f7+f8,)))))))))))))))))))))))))))))))))))) Read More