Either I am trying to use it wrong, or it is not working. Every time I try to use GSCompanyMode to build something (specifically, an airport and levelling the ground around where the airport will go) it fails with an ERR_PRECONDITION_FAILED. From what I can tell, the only precondition that is not valid is the GSCompanyMode.
I've attached the scripts I was using to try this.
I am completely aware I may just have screwed up my script. I have glanced at the SplitScenarioGS though, and can see pretty much the same thing there as what I was trying to do.
GSCompanyMode not working properly
Moderator: OpenTTD Developers
-
- Engineer
- Posts: 28
- Joined: 29 Dec 2008 22:28
- Location: my own mind
GSCompanyMode not working properly
- Attachments
-
- IS Airport.zip
- (14.17 KiB) Downloaded 31 times
Re: GSCompanyMode not working properly
Code: Select all
GSSign.BuildSign(100, "testing");
GSCompanyMode(companyIdx);
GSLog.Info("Switched to mode for " + GSCompany.GetName(companyIdx));
Solution:
Code: Select all
local cm = GSCompanyMode(companyIdx);
My OpenTTD contributions (AIs, Game Scripts, patches, OpenTTD Auto Updater, and some sprites)
Junctioneer (a traffic intersection simulator)
Junctioneer (a traffic intersection simulator)
Who is online
Users browsing this forum: No registered users and 22 guests