Page MenuHomeFeedback Tracker

EventHandler "Loaded" not firing
Closed, ResolvedPublic


I am talking about

I have added this to a mods init.sqf:
handle1 = addMissionEventHandler ["Loaded",{systemchat "BLAH"}];

After savegame load, the systemchat entry is not displaying. The event is not triggered, code is not starting. I think, the eventhandler is 100% broken.

I have seen some people reporting it.

You would make modders/missionmakers lives way easier - because survival of savegames without that eventhandler is a tricky thing.


Not A Bug
Operating System
Windows 7
Steps To Reproduce
  1. Add code to an init.sqf or appropriate place:

handle1 = addMissionEventHandler ["Loaded",{systemchat "BLAH"}];

  1. Start mission, save mission, reload mission.
  2. No text appearing in systemchat area bottom left.

Event Timeline

tortuosit updated the task description. (Show Details)
tortuosit edited Steps To Reproduce. (Show Details)

The EH works fine, I have just tested it. What you have to realise that no event handler will fire if you add it after event it supposed to monitor. This EH monitors loading of the game from save and you are adding it after the game loaded.

I suggest you create a function with preInit = 1; which will execute in pre init, so that when the game is loaded from save the EH exists.

This comment was removed by tortuosit.

It's working from preinit, thx.

BIS_fnc_KK closed this task as Resolved.Dec 8 2019, 7:24 AM
BIS_fnc_KK changed Resolution from Open to Not A Bug.