The International Simutrans Forum


Author Topic: groundobj placement tools  (Read 331 times)

0 Members and 1 Guest are viewing this topic.

Offline Leartin

  • Oh no, not him again!
  • Devotee
  • *
  • Posts: 1590
  • PAK-DEV P192C
  • Languages: DE, EN
groundobj placement tools
« on: December 31, 2020, 12:03:03 PM »
Groundobj placement tool - as a dialog to pick a groundobj or to place a random groundobj depending on the climate.

Things to note:
Instead of just showing the number of seasons, it specifies "has snow" and seasons-1 - This is different than eg. trees, but I think it's a better way to display the number of seasons to a player. (since "snowy" isn't thought of as a season normally)
The price is currently just a number. There must be a function somewhere for displaying currency, since it changes depending on settings, but I didn't find that yet.  [EDIT: it's convert_money() from finance.h]

For some reason, flat groundobj have two phases. I don't know why - so I just accept that only those with more than two phases are fit for slopes. (the groundobj won't be placed on slopes unless the groundobj has more than 2 phases.) A better way to do this would be to check for each slope whether a corresponding graphic exists, but I don't think there are any slope-groundobj in any paksets, so it seems too much. is for pak64 and adds the new tools in the editor (shows icons of tree builder)

EDIT: Reuploaded patch, something was wrong with the other file. However, it now contains a line to use the climate filter, so it kind of requires the climate filter patch,20660
EDIT2: Updated patch file again to fit with changes to the other dialogs.
Code: (New strings for the translator) [Select]
groundobj builder
Has Snow
Has slope graphics
Can be overgrown
"[go]price" was chosen since "price" already existed for vehicles, and there might be a different term required.
« Last Edit: January 07, 2021, 02:05:54 PM by Leartin »

Offline prissi

  • Developer
  • Administrator
  • *
  • Posts: 10828
  • Languages: De,EN,JP
Re: groundobj placement tools
« Reply #1 on: January 09, 2021, 01:48:48 PM »
Incorporated in 9538 (with small changes due to broken references of the other patch), thanks