[JASS] OrderId2String() returns null after loading a saved game

Not open for further replies.
Level 10
May 31, 2019
This is an issue pertaining to my campaign/mod that uses a modified blizzard.j

What seems to be happening is that any functions that had a unit order event registered to them, be it a point order, unit order, or 'no target' order will not work, but only after loading a saved game. they will work just fine otherwise.

What's also interesting is this issue is not present in the current release of the zerg campaign, which has all its core functionality in gui triggers as opposed to this upcoming release which does everything in blizzard.j.

I've attached a a test map and a stripped-down version of the required War3Mod.mpq (no sounds/portraits so that the download is relatively small). Like the zerg campaign, it requires version 1.28 of war3.

The map is simple, it just has some units you can test the problem with. You can verify that functions which don't rely on checking the unit's orderstring work just fine after loading a saved-game. Specifically, you can morph larva. But you can not set the hatchery's rallies or open the drone build menus (which check the orderstring)

Update - Solved (kind of)

It seems I mis-diagnosed the issue.
What's actually happening is that OrderId2String() will return null after loading a saved-game, but String2OrderId() is always safe to use.

I don't know if this is a bug specific to 1.28 or not, but switching to checking orderIds rather than the result of OrderId2String() fixed the issue for me.



  • zergsavetest.7z
    31.1 MB · Views: 17
Last edited:
Not open for further replies.