SuperHBob Posted September 2, 2005 Share Posted September 2, 2005 I'm pretty sure this is an easy fix, but I couldn't find anything in a search and my brain is too far melted to try to understand the error. I'm making a window to make a simple map editor (with simple graphics) and it was working pretty well until I started tweaking the code to make it run smoother. Basically there's a 10x10 map of tiles (currently grass or empty tiles) and when the mouse moves over that section of the window a little red cursor follows the mouse letting the user know which tile the mouse is on. (sort of like the Starcraft campaign editor without the triggers) *note: all the tiles are using the GUICtrlCreatePic thing to work. Thus being forced to reload (GUICtrlSetImage) the tile after the cursor moves off the tile. It was working fine until just recently I noticed that the window will now simply end giving me the run time error: " ==> Array variable has incorrect number of subscripts or subscript dimension range exceeded.: " (it crashes after the mouse moves the cursor about 50 times.) Then it points to the array that contains the indexed constants of the file names as though that would help me fix the problem. I was wondering what exactly this error was referring to (the problem not the object, I already know the object) But I really didn't know what to do at this point, but I was wondering if it had anything to do with loading too many pictures or if I needed to destroy then remake the controls or what. Any help would be appretiated. (I'll also post the code, but I didn't think it would help in this case) thanx .... my brain ---> Link to comment Share on other sites More sharing options...
SuperHBob Posted September 2, 2005 Author Share Posted September 2, 2005 nvmd. I seemed to have fixed my own problem. I screwed with it for half an hour. Finally found it. Turns out I had done some bad math and it made my rounding function throw the cursor to a location that didn't exist. Giving me that error that actually didn't have anything wrong with. Link to comment Share on other sites More sharing options...
therks Posted September 2, 2005 Share Posted September 2, 2005 Just a curiousity.. how are you adding this 'cursor' to the tiles? From the description, I'm imagining like a red square border around the 'highlighted' tile. My AutoIt Stuff | My Github Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now