Jump to content

Changing events


alainmcd
  • Pending

Not sure if it's intended that we change the world events via ApplySpecialEvent() from simutil.lua, but since the function overwrites WORLD_SPECIAL_EVENT, it's impossible to change to the default special event setting, e.g. a world with Hallowed Nights can't opt out of Hallowed Nights to default, it has to either opt out of every event via "none" or opt in to Winter's Feast specifically. Still, changes aren't saved, so to change the setting persistently one must use TheWorld.topology.overrides.specialevent. Maybe ApplySpecialEvent() can allow the special event setting be set to default correctly, and if possible save the setting?


Steps to Reproduce
ApplySpecialEvent(SPECIAL_EVENTS.HALLOWED_NIGHTS) ApplySpecialEvent("default") print(WORLD_SPECIAL_EVENT)
  • Like 1



User Feedback


Is there a way to change my world from the Halloween event to the Christmas event?

Edited by MathiusXII

Share this comment


Link to comment
Share on other sites

@MathiusXII, the "default" event setting is that your game changes according to the current special event. For example, if you create now a new world with the default setting, you will have the Winter's Feast event activated for now, it will automatically be disabled when it ends, and the next event will be activated whenever that comes.

So, if you want to change your world to only WF, you need to type in the console (being host/admin):

ApplySpecialEvent(SPECIAL_EVENTS.WINTERS_FEAST)
TheWorld.topology.overrides.specialevent(SPECIAL_EVENTS.WINTERS_FEAST)

However, if you want to change it to default and have events change automatically, use this instead:

ApplySpecialEvent(SPECIAL_EVENTS.WINTERS_FEAST)
TheWorld.topology.overrides.specialevent("default")

 

Share this comment


Link to comment
Share on other sites

Huh. Yeah. I have to run those commands every time I re load the world. It doesn't save. I hope klei fixes this

 

Edited by MathiusXII

Share this comment


Link to comment
Share on other sites

Not fix yet..

The simple fact go in caves, theses commands lost their use, so need to use this command everytime that I go up and down caves/over.

(non-dedicated)

Share this comment


Link to comment
Share on other sites

To those who are having the problem of it not being persistent amongst saves, the problem the 2nd line of code is referring to a variable, not a function. So to actually assign the value, you have to do this instead:

TheWorld.topology.overrides.specialevent = SPECIAL_EVENTS.WINTERS_FEAST

Then just save and exit your game and it will reboot your world as if it were in that event. You actually don't even need the first line of code at all, the game does that part automatically when you restart.

Without restarting your game, the crafting tabs won't get updated and will still be stuck on the previous event (as well as maybe a couple of other things), so restarting your game is just the safest way to make sure everything involving your designated event initializes properly.

  • Like 1

Share this comment


Link to comment
Share on other sites



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 account

Sign in

Already have an account? Sign in here.

Sign In Now

×
  • Create New...