Transport Tycoon Forums

The place to talk about Transport Tycoon
It is currently Wed Dec 13, 2017 3:28 am

All times are UTC




Post new topic  Reply to topic  [ 5 posts ] 
Author Message
PostPosted: Wed Mar 18, 2015 12:02 pm 
Offline
Transport Coordinator
Transport Coordinator

Joined: Fri Jun 15, 2007 9:27 am
Posts: 343
Skype: madchimiste
Location: Berlin, Deutschland
In NFO, it is possible to determine whether another GRF is loaded or not (via var 88).

But is there a way to determine which version (VRSN) of this other GRF is loaded?

_________________
Some screenshots of mine...


Top
   
PostPosted: Wed Mar 18, 2015 4:54 pm 
Offline
OpenTTD Developer
OpenTTD Developer

Joined: Wed Dec 20, 2006 1:31 pm
Posts: 973
Location: Aschaffenburg
Yes, take a look at:
https://newgrf-specs.tt-wiki.net/wiki/R ... Parameters
Code:
<Sprite-number> * <Length> 0D <target> 00 FE FE <GRFID>

_________________
⢇⡸⢸⠢⡇⡇⢎⡁⢎⡱⢸⡱⢸⣭⠀⢸⢜⢸⢸⣀⢸⣀⢸⣭⢸⡱⠀⢰⠭⡆⣫⠰⣉⢸⢸⠀⢰⠭⡆⡯⡆⢹⠁⠀⢐⠰⡁


Top
   
PostPosted: Wed Mar 18, 2015 7:45 pm 
Offline
Transport Coordinator
Transport Coordinator

Joined: Fri Jun 15, 2007 9:27 am
Posts: 343
Skype: madchimiste
Location: Berlin, Deutschland
Thank you for the quick answer, frosch.

That raises another question, however. In the action D code:
Code:
<Sprite-number> * <Length> 0D <target> 00 FE FE <GRFID>

<target> is the parameter to read from the other NewGRF.

What target should I use, then? "VRSN"? "VRSN" 00 ? Would that work, considering the specs say that <target> should be Byte-sized?

_________________
Some screenshots of mine...


Top
   
PostPosted: Wed Mar 18, 2015 9:17 pm 
Offline
Tycoon
Tycoon

Joined: Wed Jan 17, 2007 12:14 am
Posts: 6934
no, "target" is the place where you want to store the value to that you read from the other GRF, for use in later operations

_________________
You might not exactly be interested in Ferion, but if you are, have fun :)


Top
   
PostPosted: Wed Mar 18, 2015 11:44 pm 
Offline
Transport Coordinator
Transport Coordinator

Joined: Fri Jun 15, 2007 9:27 am
Posts: 343
Skype: madchimiste
Location: Berlin, Deutschland
Oops.

Sorry, I didn't read attently the specs...

I appreciate your help, thank you!

_________________
Some screenshots of mine...


Top
   
Display posts from previous:  Sort by  
Post new topic  Reply to topic  [ 5 posts ] 

All times are UTC


Who is online

Users browsing this forum: No registered users and 2 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
Powered by phpBB © 2000-2017 phpBB Limited

Copyright © Owen Rudge/The Transport Tycoon Forums 2001-2017.
Hosted by Zernebok Hosting.