General wiki questions

Got a problem with TTDPatch? Get help here.

Moderator: TTDPatch Moderators

Post Reply
DaleStan
TTDPatch Developer
TTDPatch Developer
Posts: 10285
Joined: 18 Feb 2004 03:06
Contact:

General wiki questions

Post by DaleStan »

1) The action 7 wiki page says:

Code: Select all

07/09            B    Action type
<variable>       B    Which variable to base the decision on
<varsize>        B    How many bytes to read from the variable
<condition-type> B    What condition to check
<value>          V    Value to compare with (**size equals <varsize>**)
<num-sprites>    B    How many sprites to skip
The USSet goes out of its way to prove the emphasized section wrong, using <varsize>=04 and then <value>=01, as well as using <varsize>=0.

What gives?
Specifically: In what cases is <varsize> not (necessarily) the length of <value>, and what is the length of <value> in those cases?

(Yes those are all bit-tests, but it looked to me like the wiki said that <varsize> must be 01 for bit-tests)

2) The action 7 wiki page says that variable 88 (GRFid) has a length of "B"
Again, the USSet disagrees.

3) There is no listing for the possible values of action 7 variable 8B. Some possible values are scattered in various action 0 pages, and possibly other places, but I think they should all be collected in one place.

4) There is no mention either way as to whether or not it is possible for an action 6 to modify an action 10. This seems like it would be asking for severe problems, especially if there's an action 9 pointing to the potentially modified action 10.

OT: I guess I need to change my computerized spellchecker to English(UK); I insist on typing "theatre", "rumour", "emphasised", &c. Nevermind that I've lived in .us all my life. :roll:
To get a good answer, ask a Smart Question. Similarly, if you want a bug fixed, write a Useful Bug Report. No TTDPatch crashlog? Then follow directions.
Projects: NFORenum (download) | PlaneSet (Website) | grfcodec (download) | grfdebug.log parser
Patchman
Tycoon
Tycoon
Posts: 7575
Joined: 02 Oct 2002 18:57
Location: Ithaca, New York
Contact:

Post by Patchman »

1)
wiki wrote:For bit tests, this size is ignored. Value must be a BYTE for bit tests, no matter what the size of the variable being tested.
2) Mistake, should be a 4*B. Fixed.

3) Fixed. This information was only in newgrf.txt so far...

4) Well, action 6 is kind of strange at the moment. It's only applied during the initialization of the file and never afterwards. So it should be safe to modify action 10. However, I'm considering to have action 6 be reapplied every time the .grf file is parsed. There used to be good reasons against this in the past, but I don't remember what they were, and don't think they still hold.
Josef Drexler

TTDPatch main | alpha/beta | nightly | manual | FAQ | tracker
No private messages please, you'll only get the answering machine there. Send email instead.
User avatar
Oracle
Tycoon
Tycoon
Posts: 2138
Joined: 22 May 2003 09:59

Post by Oracle »

Well at least I'm right :).
(I almost always use newgrf.txt while coding so I'm not a heavy user of the wiki.)
DaleStan
TTDPatch Developer
TTDPatch Developer
Posts: 10285
Joined: 18 Feb 2004 03:06
Contact:

Post by DaleStan »

And one more. This time I checked both the wiki and newgrf.txt.

5) Neither of the emphasized phrases (from the standard 02 for stations section) make much sense to me:
wiki wrote:The sets from the most recent action 1 to use for this set ID, in the above order of track types, one for each track type that has different graphics.
newgrf.txt wrote:Number of sprite set in most recent action 1, for each of the track types
Is "One for each of numlittlesets and numlotssets" what they mean? (All GRF files I've checked parse using that interpretation.)

"Track type", at least to me, means railroad/elect.RR/monorail/maglev.
To get a good answer, ask a Smart Question. Similarly, if you want a bug fixed, write a Useful Bug Report. No TTDPatch crashlog? Then follow directions.
Projects: NFORenum (download) | PlaneSet (Website) | grfcodec (download) | grfdebug.log parser
Patchman
Tycoon
Tycoon
Posts: 7575
Joined: 02 Oct 2002 18:57
Location: Ithaca, New York
Contact:

Post by Patchman »

On which wiki page is this exactly? I can't find it.

[edit]Never mind, I didn't read your message properly. Ok, this was correct about a year ago... back then, instead of cargo states, the sets were for the three/four different track types. That proved to be useless, so I changed it to cargo instead.
Josef Drexler

TTDPatch main | alpha/beta | nightly | manual | FAQ | tracker
No private messages please, you'll only get the answering machine there. Send email instead.
Post Reply

Return to “Problems with TTDPatch”

Who is online

Users browsing this forum: No registered users and 8 guests