citylimits/scripts/command_handler.gd
Tony Bark 72e2c96542 SC3k-style Ordinances
This wound up being a bigger commit than I had initially planned.

- New SC3k-style policies based on the advisor code.
- Added license file to Font Awesome folder.
- Refactored the advisor code so it can handle multiple files.
- Updated icons. Should be more consistent now.
- Replaced Sims with Animals in ticker text.
- Moved dialogs to windows directory.
2021-05-27 10:33:08 -04:00

32 lines
622 B
GDScript

extends Node
enum {
ARG_INT,
ARG_STRING,
ARG_BOOL,
ARG_FLOAT
}
const valid_commands = [
["money", [ARG_STRING] ],
["whereyoufrom", [ARG_STRING] ],
["whatyearisit", [ARG_STRING] ],
["show_policy", [ARG_INT]]
]
func show_policy(policy):
SimEvents.emit_signal("policy_message", policy)
func _budget_print(value: int):
return "Budget increased to " + str(value)
func money(value):
SimData.budget += int(value)
func whereyoufrom(value):
SimData.city_name = str(value)
return "Changed city name to: " + str(value)
func whatyearisit(value):
SimData.year = int(value)
return "Change year to: " + str(value)