1 month ago when I imported a character to my game I ended up with twice the same sprite. Same number and same graphic. It (probably) erased a previous sprite on a different folder. It tooks time for me to discover it. (Until I found a guy hook to the wall instead of a key) :D Both of them had the same behavior (re-importing one, change the other etc...)
I don't remember exactly how I got rid of the issue, I probably used 2 new different sprites and the editor removed the double thing alone.
But now, I just realised that the following commands :
bHeadline.NormalGraphic = 585;
bHeadline.MouseOverGraphic = 586;
Set the graphic to : 285 and 286 instead. (They are (Almost) the previous ones in the same sprite FOLDER)
I carefully looked for all the possible things who can change the values (main and local script) , commented them etc... but I'm pretty sure it's the editor....
I'll try to overturn it, guessing the values... but I'm affraid it will create problems in the long run.
Thanx :(
LUniqueSadDan
Sry for Double post.
bHeadline.NormalGraphic = 88;
bHeadline.MouseOverGraphic = 89;
will set them to 85, 86 (which is the 2 previous in the same folder. 85,86,87,88,89
I recreate a new folder with the same sprites, and it works just fine. It's not the end of the world, but my questions are :
1- Do you think it's stable or is it a symptom of a bigger issue?
2- Is it going to spread?
3- Should I continue working on this ?
tx again
That sounds like somehow your sprite file has become corrupted but yet remains in a semi-functional state. No idea how that could have happened, but this whole thing sounds rather strange all around.
If setting the graphic properties of your buttons is apparently not working, I'd say go ahead and test their values immediately after changing them (Display or even AbortGame would work very nicely for testing the values). If they are in-fact different than what you've set them to, then it's bug confirmed (whether it's a bug in AGS itself or just in your project will remain to be seen). Otherwise, I'd say track down anything that might be referencing those properties and make sure that it's not being surreptitiously changed elsewhere.
Worst case scenario, you could possibly upload the project (if you wouldn't mind doing that) and we could take a look. If you do go that route, I'd definitely recommend that both you and the downloader try and use virus scanners to make sure that you don't by chance happen to have a virus that has corrupted your project. I mean, seems a pretty abstract thing for a virus to do, but you can't be too careful with these types of issues. ;)
And no need to be Sad Dan, we'll get it figured out, one way or another! :)
Quote from: monkey_05_06 on Sun 31/07/2011 13:35:58
That sounds like somehow your sprite file has become corrupted but yet remains in a semi-functional state.
That happens to me regularly. Well every couple of months at least. IIRC, the simplest way to deal with it is to remove every reference to that sprite anywhere, then delete both versions.
EDIT: on a related note, I've noticed it is possible to delete sprites that are used in views, I think by simply deleting their folder. The game won't complain until it comes time to remove the sprite from memory after use, and then... CRASH. I use 3.02 so possibly this has been fixed, or maybe I should just expect less hand holding when I delete folders. :)
I also had this happen. It was caused by using an SVN to share the code between myself and another coder. I forgot to update my SVN with the other coder's new changes before starting to add my own changes, and the SVN tried to combine the two conflicting versions of the spriteindex.dat.
In your case, it could have happened through some automated backup/recovery or just you copying some files somehow.
I was able to fix it, as tolworthy mentioned, by deleting all those sprites and re-importing them. Better to bite the bullet and fix it now rather than have some big blowup later.
After I did this to repair it, it hasn't happened since.