Frictional Games Forum (read-only)

Full Version: My collide functions doesn't work properly
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Pages: 1 2
So, as I watch one of my beta testers play through my mod, he sometimes gotta restart here and there thanks to bugs (but are passable). Now, what I notice is that the collide functions aint responding correctly after an autosave. He clicks Continue and got to the last autosave and they refuse to work now. All the important stuff that is necessary for the level to function correctly has been disabled for some reason.

Why is this happening? It has become a big problem for my recent maps and I have to fix this somehow. If not, my mod is gonna be a big mess.
I have actually encountered this myself and I'm still curious as to what is causing it...
Try setting the Collide callbacks to this:

AddEntityCollideCallback("Thing", "Thing2", "Event", false, 1);

This true/false determines if the callback is erased when the callback is called. I dunno what's with the checkpoint, but this might fix it.
No, it's not that it's removed after use, but the fact that it simply disappears before even executed. Something with autosaves. Could it be a bug?
OnStart() vs OnEnter()?

Edit:

Does having your collides in OnStart() differ from having them in OnEnter()?
Hmmm.. never encountered anything like this before.
On Premonition i have an autosave on the start of every map....
ALL my scripts functions are on OnStart()
and all my AUTOSAVES are OnEnter()
Some of the collide functions are in Onstart and some are in OnEnter. Still the same thing. It's so weird. But like Mudbill says, I'm expecting a bug.
Perhaps it has something to do with when the autosave occurs. Perhaps it conflicts with something, causing it to not save the whole file.

What seems to be happening is that when starting a map, you have all the callbacks in OnStart. Later, back in the menu after saving and exiting, you load a previous autosave from that map. Once loaded, the callbacks that had already been added when the save was made no longer apply to the objects in the level, causing a major halt in the middle of the story (because these callbacks are often essential to progress). I don't think this happens every time, but I have indeed seen it happen in a video for one of my projects. It's kinda sad, because the player will blame the author of the story for it (as that would be the more likely cause than a fault in the game itself).
(04-25-2014, 03:54 PM)Mudbill Wrote: [ -> ]Perhaps it has something to do with when the autosave occurs. Perhaps it conflicts with something, causing it to not save the whole file.

What seems to be happening is that when starting a map, you have all the callbacks in OnStart. Later, back in the menu after saving and exiting, you load a previous autosave from that map. Once loaded, the callbacks that had already been added when the save was made no longer apply to the objects in the level, causing a major halt in the middle of the story (because these callbacks are often essential to progress). I don't think this happens every time, but I have indeed seen it happen in a video for one of my projects. It's kinda sad, because the player will blame the author of the story for it (as that would be the more likely cause than a fault in the game itself).

[Image: cristiano-ronaldo-jews.gif]
(04-25-2014, 03:54 PM)Mudbill Wrote: [ -> ]Perhaps it has something to do with when the autosave occurs. Perhaps it conflicts with something, causing it to not save the whole file.

What seems to be happening is that when starting a map, you have all the callbacks in OnStart. Later, back in the menu after saving and exiting, you load a previous autosave from that map. Once loaded, the callbacks that had already been added when the save was made no longer apply to the objects in the level, causing a major halt in the middle of the story (because these callbacks are often essential to progress). I don't think this happens every time, but I have indeed seen it happen in a video for one of my projects. It's kinda sad, because the player will blame the author of the story for it (as that would be the more likely cause than a fault in the game itself).

I guess so. For now I guess I have to deal with it. Until I (or we) can find a way to fix this thing, I have to keep working on the mod I guess.
Pages: 1 2