[GS] Renewed Village Growth 9.3 (RVG)

Discuss the new AI features ("NoAI") introduced into OpenTTD 0.7, allowing you to implement custom AIs, and the new Game Scripts available in OpenTTD 1.2 and higher.

Moderator: OpenTTD Developers

How would you rate this game script?

5★ Lev4 'Chimaera'
26
90%
4★ "AsiaStar"
2
7%
3★ Floss "47"
1
3%
2★ Ploddyphut Choo-Choo
0
No votes
1★ Kirby Paul Tank
0
No votes
 
Total votes: 29

User avatar
Firrel
Engineer
Engineer
Posts: 118
Joined: 13 Aug 2019 17:06

Re: [GS] Renewed Village Growth (RVG)

Post by Firrel »

If you have a game without any other game script, it might be possible, but I haven't tried it, so can't tell for sure. It is possible to do in the scenario editor.

You can try to do it this way: viewtopic.php?p=1240195#p1240195

Also I am working on a new version, which should be ready soon™ and would not be compatible with previous version. It will also make it easier to add to the game.
User avatar
pr0saic
Engineer
Engineer
Posts: 5
Joined: 27 Jan 2021 12:33
Location: England
Contact:

Re: [GS] Renewed Village Growth (RVG)

Post by pr0saic »

Firrel wrote: 27 Jan 2021 17:49 You can try to do it this way: viewtopic.php?p=1240195#p1240195
So I managed to add it this way, as well as by modifying info.nut to allow me to set the industry set to FIRS, however, I'm using FIRS 2 and the script only supports FIRS 1 & 3, so when I set it to FIRS 3 - Extreme (I'm using FIRS 2 - Extreme), I got an error saying "the industry set defined in the GS settings doesn't match with the game's initial cargo list". I'm not sure if this is because I added the script part way through the save, or if it's because FIRS 2 isn't supported.

Hope to hear back from you!
Cheers
Ayy Lmao
User avatar
Firrel
Engineer
Engineer
Posts: 118
Joined: 13 Aug 2019 17:06

Re: [GS] Renewed Village Growth (RVG)

Post by Firrel »

pr0saic wrote: 28 Jan 2021 12:43 I'm using FIRS 2 and the script only supports FIRS 1 & 3, so when I set it to FIRS 3 - Extreme (I'm using FIRS 2 - Extreme), I got an error saying "the industry set defined in the GS settings doesn't match with the game's initial cargo list".
FIRS 2 is not supported in this version, but will be in the next one. In the next version, the economies, which are not predefined, will be automatically generated based on the cargo list and cargo type. Hopefully I will get to finish it this weekend, but no promises.

Or you can define the FIRS 2 economy as described here.
User avatar
pr0saic
Engineer
Engineer
Posts: 5
Joined: 27 Jan 2021 12:33
Location: England
Contact:

Re: [GS] Renewed Village Growth (RVG)

Post by pr0saic »

Firrel wrote: 28 Jan 2021 14:19
pr0saic wrote: 28 Jan 2021 12:43 I'm using FIRS 2 and the script only supports FIRS 1 & 3, so when I set it to FIRS 3 - Extreme (I'm using FIRS 2 - Extreme), I got an error saying "the industry set defined in the GS settings doesn't match with the game's initial cargo list".
FIRS 2 is not supported in this version, but will be in the next one. In the next version, the economies, which are not predefined, will be automatically generated based on the cargo list and cargo type. Hopefully I will get to finish it this weekend, but no promises.

Or you can define the FIRS 2 economy as described here.
Perfect! Thank you! :bow:
Ayy Lmao
Argus
Tycoon
Tycoon
Posts: 1203
Joined: 16 Oct 2018 08:31
Location: Heart of the Highlands. Not Scottish. Czech.

Re: [GS] Renewed Village Growth (RVG)

Post by Argus »

I have some games saved with an old version of the script. My cities are not developing now. Is there anything you can do about it? It's not just this script, but also others. The game did not replace the script with a new version, but at the same time it behaves as if it were there. Is it possible to restart it or stop this behavior?
User avatar
Firrel
Engineer
Engineer
Posts: 118
Joined: 13 Aug 2019 17:06

Re: [GS] Renewed Village Growth (RVG)

Post by Firrel »

Argus wrote: 29 Jan 2021 15:18 I have some games saved with an old version of the script. My cities are not developing now. Is there anything you can do about it? It's not just this script, but also others. The game did not replace the script with a new version, but at the same time it behaves as if it were there. Is it possible to restart it or stop this behavior?
You will need to specify the problem. Which version are you using? Which version are you trying to upgrade to? What other scripts? How to reproduce it? You can send me your save game and more info to PM.

The versioning system works the way that the major versions are savegame incompatible and minor version should be compatible, so you can upgrade from 4.2 to 4.3, but not to 5.0 without breaking it. Keeping all versions savegame compatible would be too much work for what its worth.

It might be possible to restart and upgrade it with a small code change, but it might also break in so many ways, so you can do it at your risk. Here is how:
[+] Spoiler
1. Untar the game script (when upgrading, untar the new version) located in /path/to/OpenTTD/content_download/game
2. Open info.nut and change this line: (so that it can load previous versions)

Code: Select all

function MinVersionToLoad()	{ return 1; }
3. Open main.nut and comment out the content of the loading function

Code: Select all

function MainClass::Load(version, saved_data)
{
  /* ... */
}
4. Start the game and wait for the initialization to be complete. The game script should restart itself. Then save it (to a different save) that will contain saved data of the new version.
5. Revert the code changes
Argus
Tycoon
Tycoon
Posts: 1203
Joined: 16 Oct 2018 08:31
Location: Heart of the Highlands. Not Scottish. Czech.

Re: [GS] Renewed Village Growth (RVG)

Post by Argus »

Now I don't have time for that, but it's a pity that the game doesn't behave like in the case of newgrf, when it simply turns off the missing graphics. As for the script version, I have downloaded the current one, and unfortunately I have no idea what version was originally in the saved game - I transferred the games and everything else to a new computer and some are even two years old ... I didn't think of transferring scripts, I had no idea there was such a problem. I do not want to change anything in the script, I'm sorry that the game does not have a more elegant solution for these cases ... Unfortunately, I will not describe the problem with my level of English better, simply if I give the ai / game settings, the script is not listed at all. However, the game behaves as if it has been loaded.
User avatar
pr0saic
Engineer
Engineer
Posts: 5
Joined: 27 Jan 2021 12:33
Location: England
Contact:

Re: [GS] Renewed Village Growth (RVG)

Post by pr0saic »

Argus wrote: 29 Jan 2021 18:28 Now I don't have time for that, but it's a pity that the game doesn't behave like in the case of newgrf, when it simply turns off the missing graphics. As for the script version, I have downloaded the current one, and unfortunately I have no idea what version was originally in the saved game - I transferred the games and everything else to a new computer and some are even two years old ... I didn't think of transferring scripts, I had no idea there was such a problem. I do not want to change anything in the script, I'm sorry that the game does not have a more elegant solution for these cases ... Unfortunately, I will not describe the problem with my level of English better, simply if I give the ai / game settings, the script is not listed at all. However, the game behaves as if it has been loaded.
I had the same issue when I was messing around with some of the files, if the GS is not in a folder or a .tar in the Documents/OpenTTD/content_download/game folder, OpenTTD doesn't detect it
Probably not the problem, but might be worth checking? :|
Ayy Lmao
Argus
Tycoon
Tycoon
Posts: 1203
Joined: 16 Oct 2018 08:31
Location: Heart of the Highlands. Not Scottish. Czech.

Re: [GS] Renewed Village Growth (RVG)

Post by Argus »

No, that's not it. In short, the saved game has an older version than the one currently downloaded. I expect the new games to behave the same when I update this script. Now I find that, for example, GS Think globally act locally, with which the problem is the most, I have it in several versions, in the given folder. Except for the current versions 12, 16 and 17. This script is only in version 5. I'll try to see if something has wandered somewhere, but I doubt it.
Argus
Tycoon
Tycoon
Posts: 1203
Joined: 16 Oct 2018 08:31
Location: Heart of the Highlands. Not Scottish. Czech.

Re: [GS] Renewed Village Growth (RVG)

Post by Argus »

I have all the scripts where they should be. However, I additionally found out that there are scripts in the backup from the old computer in the end, so maybe the problem was solved.
Edit: Problem solved only partially, some versions probably still missing. But if it can't be solved other than by intervening in the script code and possibly breaking the saved game, I probably won't solve it anymore. It is a pity that it is not possible to find out which version was in that particular game.
User avatar
Firrel
Engineer
Engineer
Posts: 118
Joined: 13 Aug 2019 17:06

Re: [GS] Renewed Village Growth (RVG)

Post by Firrel »

Argus wrote: 29 Jan 2021 21:27
Added link to every RVG version to the first post under changelog spoilers. You can download and try them. Hopefully this will solve your problem.
Argus
Tycoon
Tycoon
Posts: 1203
Joined: 16 Oct 2018 08:31
Location: Heart of the Highlands. Not Scottish. Czech.

Re: [GS] Renewed Village Growth (RVG)

Post by Argus »

Thanks :)
User avatar
Firrel
Engineer
Engineer
Posts: 118
Joined: 13 Aug 2019 17:06

Re: [GS] Renewed Village Growth (RVG)

Post by Firrel »

New update for Renewed Village Growth 6.0 is available in BaNaNaS

This version received another rework of the town info box to allow few more parameters, that are already used up by a new feature. The feature adds a best contributor for each town, which is decided on how much each player contributed to the town in the previous month concerning fulfilling categories. Each player now receives points for increasing the population of towns over its maximum for each most contributed towns. The points are displayed in the Goals UI along with some more statistics.

Image

Another requested feature is added, the industry stabilizer. When enabled, it will fund raw industries on the map and maintain that number of industries. As a bonus, it can be used to create a map with only raw industries, which suits well with the randomization gameplay.

Removed the need to select industry NewGRF, now the correct economy is choses from the list of explicitely supported economies. Now also featuring FIRS 2 thanks to pr0saic. If the industry is not explicitely supported, the categories will be proceduraly generated to support any Industry NewGRF now or in the future.

Added several more randomization options also with a new type: industry. This randomization type will create categories based on industry types in the game. Each category then represents one (or more if needed) industry type by their input cargo types. This is most useful for big economies like FIRS Steeltown or XIS.

The limiter is also reworked to show only underperforming cargo types. This also allows to define different limited cargo types, like ITI now has pax, mail and waste and YETI has pax, mail, yeti and tired yeti. The percentage is now the average of all limited cargo types.

These were big changes to the code, so if you encounter any problem, please post it here. You can download the update from the first post of this thread or from BaNaNaS.

Complete changelog
[+] Spoiler
* Not compatible with previous versions
- new: Growth statistics for each player based on most contributed towns
- new: Added FIRS 2.1.5 predefined cargo categories (pr0saic)
- new: Updated texts in story book to include randomization cases
- new: The supported economy is automatically detected from the cargo list
- new: Added industry randomization option based on number of inputs of an industry
- new: Added more cargo randomization options
- new: Raw industry stabilizer that prospects raw industries based on a setting
- new: Added warning for too many towns to save
- modified: Removed cargo stockpiled number from town info box
- modified: Reworked showing of limiter information to show only underperforming cargos with color indication
- modified: Reworked limiter, now limits growth based on average value of all limited cargos (supports more cargos than passangers and mails)
- modified: Changed all parameters to be changeable and handled edge cases
- modified: Added Waste for ITI and Yeti, Tired Yeti for YETI as additional limited cargos
- fix: Prevent showing all cargos when the randomization is none
- fix: Growth rate is limited to 1 day minimum
- fix: Ignore CZTR cargo LVPT when randomizing cargo categories
Attachments
statistics.png
statistics.png (48.07 KiB) Viewed 5335 times
User avatar
2TallTyler
Route Supervisor
Route Supervisor
Posts: 495
Joined: 11 Aug 2019 18:15
Contact:

Re: [GS] Renewed Village Growth (RVG)

Post by 2TallTyler »

I love the new feature which shows which company has contributed most to a town's growth. That will be very fun in a citybuilding multiplayer game.

I got a crash with the latest version. Attached are a screenshot of the AI/GS debug window showing the error, as well as the savegame (if it helps).
Attachments
rvg_error.png
(77.59 KiB) Not downloaded yet
rvg_crash_game.sav
(511.3 KiB) Downloaded 103 times
User avatar
Firrel
Engineer
Engineer
Posts: 118
Joined: 13 Aug 2019 17:06

Re: [GS] Renewed Village Growth (RVG)

Post by Firrel »

Thank you, will look into it. Seems like an issue with cargo list, so the savegame will be valuable.

Also thank you for your feedback, glad you like it.
User avatar
Firrel
Engineer
Engineer
Posts: 118
Joined: 13 Aug 2019 17:06

Re: [GS] Renewed Village Growth (RVG)

Post by Firrel »

New update for Renewed Village Growth 6.1 is available in BaNaNaS
- new: Slovak translation
- new: Czech translation
- fix: crash when a town stopped to be monitored

If you are interested in providing a translation to the RVG game script, you can find a template file in the first post of this thread with additional information. All translations will be appreciated and credited.
User avatar
khamseen
Engineer
Engineer
Posts: 16
Joined: 12 Aug 2016 02:33

Re: [GS] Renewed Village Growth (RVG)

Post by khamseen »

Thank you for this script, I used to use Renewed City Growth and after not playing for a while I decided to get back in for another long haul session with the latest FIRS etc but RCG hasn't been updated in a long time so didn't support it out of the box and this seems like an excellent replacement.

I was wondering though, is it safe/possible, to adjust the settings of the script in an existing save game? I'd like to play around with a few of the settings like Randomisation (because it's hard to understand exactly what it'll do) and minimum quotas etc to find a good balance between fun and challenging vs irritating and nightmarish haha.
User avatar
Firrel
Engineer
Engineer
Posts: 118
Joined: 13 Aug 2019 17:06

Re: [GS] Renewed Village Growth (RVG)

Post by Firrel »

It is possible to change all parameters in a running game except town sign, randomization and display cargo from start. Industry stabilizer can be only increased in density. You can find the description of all parameters in the readme file.

There are three presets: easy, medium, hard. You can select them in the game settings under AI difficulty. You can get inspired by those presets.

For randomization, if you want to see what each of them does, you can enable parameter display cargo from start, start a new game and check the towns what they require.

If you plan to play FIRS 4 Steeltown, I would suggest you to use randomization descending, industry stabilizer enabled and game setting industry density to fund only. With the randomization, each category will be a different industry. So when you have industry accepting four cargo types, those will be made into a category. So every town has its identity. The industry stabilizer will allow for a map with only raw industries, so that you can fund accepting industries near towns that require them.
User avatar
khamseen
Engineer
Engineer
Posts: 16
Joined: 12 Aug 2016 02:33

Re: [GS] Renewed Village Growth (RVG)

Post by khamseen »

Firrel wrote: 05 Apr 2021 06:53 It is possible to change all parameters in a running game except town sign, randomization and display cargo from start. Industry stabilizer can be only increased in density. You can find the description of all parameters in the readme file.

There are three presets: easy, medium, hard. You can select them in the game settings under AI difficulty. You can get inspired by those presets.

For randomization, if you want to see what each of them does, you can enable parameter display cargo from start, start a new game and check the towns what they require.

If you plan to play FIRS 4 Steeltown, I would suggest you to use randomization descending, industry stabilizer enabled and game setting industry density to fund only. With the randomization, each category will be a different industry. So when you have industry accepting four cargo types, those will be made into a category. So every town has its identity. The industry stabilizer will allow for a map with only raw industries, so that you can fund accepting industries near towns that require them.
Ok thanks for confirming which settings can't be changed after starting, that's good to know!
I appreciate the tips for recommended settings as I do plan on using the Steeltown industry, I used the Hot Country industry last time I played and it was pretty fun but Steeltown seems like it'll provide even more challenge of multi input/output handling so figured it's worth a try. :)
User avatar
Firrel
Engineer
Engineer
Posts: 118
Joined: 13 Aug 2019 17:06

Re: [GS] Renewed Village Growth 6.2 (RVG)

Post by Firrel »

New update for Renewed Village Growth 6.2 is available in BaNaNaS
- new: Simplified Chinese translation (SuperCirno)
Post Reply

Return to “OpenTTD AIs and Game Scripts”

Who is online

Users browsing this forum: No registered users and 6 guests