-
Notifications
You must be signed in to change notification settings - Fork 36
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Bridge management #158
base: master
Are you sure you want to change the base?
Bridge management #158
Conversation
Probably needs documenting somewhere (newgrf-wiki?) and ideally it should be tested as well... |
'max_length' : { 'num': 0x0A, 'size': 1 }, | ||
# 0x0B - cost factor (old way) | ||
'speed_limit' : { 'num': 0x0C, 'size': 2, 'unit_type': 'speed', 'unit_conversion': (5000, 1397), 'adjust_value': lambda val, unit: ottd_display_speed(val, 1, unit)}, | ||
'sprite' : { 'num': 0x0D, 'size': 2 }, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This seems wrong, based on my reading of the specs.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hmm... I did it based on https://newgrf-specs.tt-wiki.net/wiki/Action0/Bridges
What is wrong according to you?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
prop 0D is not a simple 2 bytes value, it's more complex. See the example at the bottom of the page.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sprites are clearly wrong... Need to find some to generate output, will be able to share full version then.
I've tested all except
sprite
andflags
...The code to edit a bridge becomes 👍
name
,description_rail_bridge
anddescription_road_bridge
have also been tested and working fine.