Jump to content

Recommended Posts

I'm trying to create a mod to acceleate game running. 

with the following script, but it seem to be unable to load, my guess is that "TheSim ... " won't be able to run until other things are loaded, any ideas?

 

local accelerate_factor = 1.5
 
print(TheSim:GetTimeScale())
print(TheSim:GetTimeScale() ~= accelerate_factor)
if TheSim:GetTimeScale() ~= accelerate_factor then
    TheSim:SetTimeScale(accelerate_factor)
end
Link to comment
https://forums.kleientertainment.com/forums/topic/156330-question-on-mod-creation/
Share on other sites

12 hours ago, Rickzzs said:

Your code looks correct. You can see my mod Speed Me Up, which works in a world without caves. To acclerate a world with caves, networking is required.

Was able to check the mod, and I think it does work in the cave... at least in solo server. 

I think my issue was with "TheSim" is not initialized (can't confirm as I don't know how to debug this with this... ), my script has it as a single call, but you used button for function call. 

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...