OpenXcom Forum

OpenXcom => Troubleshooting => Topic started by: breaker52 on November 20, 2022, 11:41:15 pm

Title: babby's first cheat mod. Help
Post by: breaker52 on November 20, 2022, 11:41:15 pm
Using openxcom extended, and x-com files. Unsure if this is more a openxcom extended issue or not. so I made a rule file, put it in its own folder, even got the metadata.yml for it. I said the master was x-com files,   The openxcom wiki https://www.ufopaedia.org/index.php/Rulesets_(OpenXcom) (https://www.ufopaedia.org/index.php/Rulesets_(OpenXcom)) said near the bottom of the page i need to edit the 'options.cfg' file to add an aditional ruleset, which may be easier than what I am doing.  however, there is nothing about any rulesets in the 'options.cfg'   Either way, this is the .rul file.
Code: [Select]
  - name: STR_FREE_POINTS
    cost: 1
    points: 6000000
Upon activating that mod in game I get the following error:
Code: [Select]
yaml-cpp: error at line 2, column 9: illegal map valueAny idea what is causing the error?
To clarify in advanced: I am trying to make a ruleset that adds a research to add score so I can salvage my game without loading an earlier save.
Title: Re: babby's first cheat mod. Help
Post by: Yankes on November 21, 2022, 02:04:59 am
Would be easier hack your save?

For bug itself check if you do not put some invalid characters in that line, yaml is bit picky about what you can place there (like tab vs space).
Title: Re: babby's first cheat mod. Help
Post by: Chuckebaby on November 21, 2022, 01:01:23 pm
Would be easier hack your save?


I agree.

Go to line 44 and under researchScores: Boost the last two months to 5000. That should keep you a float for 2 more months.

Note: I'm not good at modding,So my advice is like very thin paper. I figured this out myself and also had "ALOT" of help from members here on this awesome webpage
Title: Re: babby's first cheat mod. Help
Post by: Solarius Scorch on November 21, 2022, 03:34:28 pm
Blind guess: you used tabs instead of spaces.
Title: Re: babby's first cheat mod. Help
Post by: breaker52 on November 22, 2022, 08:20:26 pm
thanks for all your replies yall, i'll give them a look!
Title: Re: babby's first cheat mod. Help
Post by: The Reaver of Darkness on November 23, 2022, 06:24:58 pm
Using openxcom extended, and x-com files. Unsure if this is more a openxcom extended issue or not. so I made a rule file, put it in its own folder, even got the metadata.yml for it. I said the master was x-com files,   The openxcom wiki https://www.ufopaedia.org/index.php/Rulesets_(OpenXcom) (https://www.ufopaedia.org/index.php/Rulesets_(OpenXcom)) said near the bottom of the page i need to edit the 'options.cfg' file to add an aditional ruleset, which may be easier than what I am doing.  however, there is nothing about any rulesets in the 'options.cfg'   Either way, this is the .rul file.
Code: [Select]
  - name: STR_FREE_POINTS
    cost: 1
    points: 6000000
Upon activating that mod in game I get the following error:
Code: [Select]
yaml-cpp: error at line 2, column 9: illegal map valueAny idea what is causing the error?
To clarify in advanced: I am trying to make a ruleset that adds a research to add score so I can salvage my game without loading an earlier save.

Is this code the entire piece of the ruleset entry?
It should look like this:
Code: [Select]
research:
  - name: STR_FREE_POINTS
    cost: 1
    points: 6000000

Error at line 2 column 9 is the colon ( : ) at the end of cost. My best guess: the ruleset accepts an entry starting with "name:" when it has not been placed into a category, but once you try to apply an attribute to that name called "cost", it becomes an invalid entry because uncategorized entries do not have a cost attribute associated with them.