OpenXcom Forum

Modding => Work In Progress => Topic started by: Thirsk on February 08, 2017, 01:54:37 am

Title: Randomise starting base facilities
Post by: Thirsk on February 08, 2017, 01:54:37 am
Is it possible to randomise the positions of starting base facilities? I don't really want to place them myself in advanced options since it feels cheat-y..

It just seems like something that can offer new experiences and more replayability in base defense missions.
Title: Re: Randomise starting base facilities
Post by: R1dO on February 08, 2017, 05:48:03 pm
True random will not be possible, since it will lead to disconnected facilities.

If you want to feel less cheat-y when manually placing you can call an external randomize function (via spreadsheet or other software) to determine where to place a specific facility.
For my games i use a bash script with the code below to provide me the coordinates of the entrance, the rest of the facilities will be placed based on personal preferences.

Code: [Select]
for i in {1..2}; do echo $(($RANDOM % 6 + 1)); done
Please note that this script is based on the personal preference of defining the upper left spot to be {1,1}, it is not based on any coordinate system used by the game itself.
Title: Re: Randomise starting base facilities
Post by: yrizoud on February 09, 2017, 04:26:34 am
A script could (re-)generate an actual mod which defines the starting base layout.
Title: Re: Randomise starting base facilities
Post by: Thirsk on February 09, 2017, 08:28:34 am
A script could (re-)generate an actual mod which defines the starting base layout.

Oh that would be perfect but the question is if anyone would actually make one :'(