bencameron137
New Member
- Joined
- Jun 6, 2018
- Messages
- 3
https://drive.google.com/file/d/1fsl-nLcgM2Z8p4anOg_JW8fBndei59qG/view?usp=sharing
I have a worksheet that uses VBA to replicate an old game called 2048 (https://gabrielecirulli.github.io/2048/)
The game works alright, there are a few issues I need to iron out, but there's one main problem I need help with.
I added a function (WinLoseCheck) to both check if you had won (achieving a 2048 square), in which it would tell you, and to check if you lost (not being able to move), in which it would also tell you.
The winning system worked, it was just used a for each to determine if any of the cells were 2048. The losing system, however, had to check if there was a space to move into, and if any of the cells could merge. When I implemented this, it threw a application-defined or object-defined error.
If anyone could tell me why this is happening and a solution, I would be ever grateful. Thanks in advance.
I have a worksheet that uses VBA to replicate an old game called 2048 (https://gabrielecirulli.github.io/2048/)
The game works alright, there are a few issues I need to iron out, but there's one main problem I need help with.
I added a function (WinLoseCheck) to both check if you had won (achieving a 2048 square), in which it would tell you, and to check if you lost (not being able to move), in which it would also tell you.
The winning system worked, it was just used a for each to determine if any of the cells were 2048. The losing system, however, had to check if there was a space to move into, and if any of the cells could merge. When I implemented this, it threw a application-defined or object-defined error.
If anyone could tell me why this is happening and a solution, I would be ever grateful. Thanks in advance.