Transport Tycoon Forums

The place to talk about Transport Tycoon
It is currently Fri Apr 19, 2019 5:26 pm

All times are UTC




Post new topic  Reply to topic  [ 1265 posts ]  Go to page Previous 160 61 62 63 64 Next
Author Message
PostPosted: Wed Dec 05, 2018 2:27 pm 
Offline
Engineer
Engineer
User avatar

Joined: Wed Jul 18, 2018 5:26 pm
Posts: 49
Location: Germany
Eddi wrote:
  • property 08 is a 4 byte-ID (like GRF-ID, Cargo-Label, etc.), not a String

Ah, that makes sence, so it would work like Railtypelabels, just for stationtypelabels, I guess. For example, I think, that something like "STSP" (=Station Single Platforms) would work, right?

Eddi wrote:
  • where did you get 0xC5 from for "name"? couldn't find that anywhere
  • the action0 complains about C5 being unknown (see previous question)

I got 0xC5 from the nfo output of m4nfo. I saw the C5 in front of the Name in the shown code, so I thought that might be it. So what should be used instead of C5, I could not find reference on the wiki for the definition of the name of a station tile?
Code:
10 * 21    04 04 FF 01 01 C5 "Empty Platform" 00


Eddi wrote:
  • the action2 is completely ill-formed. as far as i understand stations, tile layout should be a property (action0), not "graphics" (action2). no clue what you were trying to achieve there

I took a look at the Airports and Airport tiles, and they worked like the code I showed, that it referred to graphics. Though you might be right, because 0x0E for Stations is a custom layout definition, so that might define the layout and the default is just a single tile.

Eddi wrote:
  • the two action4 complain that you're using language ID 7F (indicating byte-IDs) instead of FF (indicating word-IDs). what that means i have no clue.

Maybe that has to do with the size of the ID? As of output_base.py the size seems to switch between "bytex", "wordx" and "dwordx" according to the size of the value. Could also be because I used C5 for the Name, that those correspond.

planetmaker wrote:
Do you happen to have a WIP git repo for your station code?

Well, kinda. Im currently just testing files and sometimes when I get something to work, I push it to this git repo.

_________________
Image


Top
   
PostPosted: Wed Dec 05, 2018 5:04 pm 
Offline
Tycoon
Tycoon

Joined: Wed Jan 17, 2007 12:14 am
Posts: 7312
PNDA_ wrote:
Eddi wrote:
  • where did you get 0xC5 from for "name"? couldn't find that anywhere
  • the action0 complains about C5 being unknown (see previous question)

I got 0xC5 from the nfo output of m4nfo. I saw the C5 in front of the Name in the shown code, so I thought that might be it. So what should be used instead of C5, I could not find reference on the wiki for the definition of the name of a station tile?
Code:
10 * 21    04 04 FF 01 01 C5 "Empty Platform" 00
yeah, but that is in an action 4, not an action 0. let's dissect that:

Code:
10 * 21 // sprite number and length
04 //action 4 (string)
04 //feature 4 (station)
FF //language ID (like i mentioned above, FF for Word-sized IDs instead of 7F)
01 //one string
01 //lower byte of the ID, which station
C5 //upper byte of the ID, indicating "station name"
"Empty Platform" //actual string
00 //terminating 0


nmlc likely will have a flag somewhere to define that action4 should be output with word-sized IDs instead of byte-sized, look at e.g. how houses do it differently to vehicles.

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


Top
   
PostPosted: Sun Dec 09, 2018 7:51 am 
Offline
Traffic Manager
Traffic Manager
User avatar

Joined: Thu Jul 02, 2015 8:05 am
Posts: 177
Location: Czech Republic
Hi all, is possible to code in NML houses what will be dependent on road possition? We need to rotate houses into right possition to do best vizual effect :) We found this function in NFO. Is there any way how to code it in NML? Thanks :)
Attachment:
nfo.png [43.27 KiB]
Not downloaded yet

_________________
Image


Top
   
PostPosted: Mon Dec 10, 2018 2:05 am 
Offline
OpenTTD Developer
OpenTTD Developer
User avatar

Joined: Wed Nov 07, 2007 10:44 pm
Posts: 9260
Location: Sol d
Yes. Check the "nearby" variables, nearby_tile_class in particular and simply check for the presence of road. I believe FIRS uses similar for more than 5 years for the petrol pump.

_________________
Image
OpenTTD: manual | online content | translations | Wanted contributions and patches
#openttdcoop: blog | wiki | public server | DevZone | NewGRF web translator
DevZone - home of the free NewGRFs: OpenSFX | OpenMSX | OpenGFX | Swedish Rails | OpenGFX+ Trains|RV|Industries|Airports|Landscape | NML


Top
   
PostPosted: Tue Mar 05, 2019 11:45 am 
Offline
Engineer
Engineer

Joined: Wed Feb 24, 2016 4:40 pm
Posts: 10
Hello
NML 4 need a update.
can someone help please.

Thank you

Vanderbildt


Top
   
PostPosted: Tue Mar 05, 2019 9:32 pm 
Offline
Tycoon
Tycoon
User avatar

Joined: Sat Feb 14, 2015 12:44 am
Posts: 2896
Location: Newcastle, Australia
I get my updates to NML from here https://bundles.openttdcoop.org/nml/?C=M&O=D

_________________
Soot Happens
All my projects are GPLv2 License unless stated.
Auz Project Releases: viewtopic.php?f=67&t=84725
AuzTrains: http://www.tt-forums.net/viewtopic.php?f=26&t=74193
Auz Industry Sets: http://www.tt-forums.net/viewtopic.php?f=26&t=74471
AuzObjects: viewtopic.php?f=26&t=75657
AuzBridges: viewtopic.php?f=26&t=75248
AuzStations: viewtopic.php?f=26&t=76390
AuzTracks: viewtopic.php?f=26&t=82691


Top
   
PostPosted: Wed Mar 06, 2019 9:35 am 
Offline
Engineer
Engineer

Joined: Wed Feb 24, 2016 4:40 pm
Posts: 10
Thank you.
SORRY my request was not precise.
NML needs a update for:https://github.com/OpenTTD/OpenTTD/pull/6867

Vanderbildt


Top
   
PostPosted: Wed Mar 06, 2019 9:41 am 
Offline
Tycoon
Tycoon
User avatar

Joined: Sat Feb 14, 2015 12:44 am
Posts: 2896
Location: Newcastle, Australia
information I received before say it could be several months before that update is available .. I to is waiting for that update :D

_________________
Soot Happens
All my projects are GPLv2 License unless stated.
Auz Project Releases: viewtopic.php?f=67&t=84725
AuzTrains: http://www.tt-forums.net/viewtopic.php?f=26&t=74193
Auz Industry Sets: http://www.tt-forums.net/viewtopic.php?f=26&t=74471
AuzObjects: viewtopic.php?f=26&t=75657
AuzBridges: viewtopic.php?f=26&t=75248
AuzStations: viewtopic.php?f=26&t=76390
AuzTracks: viewtopic.php?f=26&t=82691


Top
   
PostPosted: Wed Mar 06, 2019 11:38 am 
Offline
Tycoon
Tycoon
User avatar

Joined: Sat Mar 31, 2007 2:23 pm
Posts: 4824
Location: Lost in Music
For 16-cargo-in-16-cargo-out, there's a set of updates from nielsm here https://github.com/PeterN/nml/commits/16-in-out

I'm testing them with FIRS, they work so far, but they may be incomplete.

If you know how to build NML yourself from the sources, you can try them, helping test will be very valuable.

https://github.com/OpenTTD/nml/
https://github.com/OpenTTD/nml/pull/15

Meanwhile...

NML has no regular maintainer or active contributors currently.

It has been kept on life support by frosch, planetmaker and me. But none of us are able to develop it or release it regularly.

To be quite precise then, it if newgrf authors wish to continue using NML, new contributors will need to emerge :)

Otherwise I think NML will die.

I am already evaluating the alternatives (nfo, m4nfo).

_________________
FIRS Industry Replacement Set (Released) | HEQS Heavy Equipment Set (trucks, industrial trams and more) (Finished)
Squid Ate FISH (ships) (Released) | CHIPS Has Improved Players' Stations (Finished)
Iron Horse (trains, released) | Termite (tracks for Iron Horse, released) | Busy Bee (game script, released)

Road Hog (road vehicles, released)


Top
   
PostPosted: Wed Mar 06, 2019 12:10 pm 
Offline
Tycoon
Tycoon
User avatar

Joined: Sat Feb 14, 2015 12:44 am
Posts: 2896
Location: Newcastle, Australia
andythenorth wrote:
For 16-cargo-in-16-cargo-out,


Wish I could help but my knowledge of coding is limited.

Even visiting those sites you provided links to I get lost looking at what you have there.

If can PM what I need, happy to test with my Industry or with you fires and see what I can find any problems.

Cheers

Garry

_________________
Soot Happens
All my projects are GPLv2 License unless stated.
Auz Project Releases: viewtopic.php?f=67&t=84725
AuzTrains: http://www.tt-forums.net/viewtopic.php?f=26&t=74193
Auz Industry Sets: http://www.tt-forums.net/viewtopic.php?f=26&t=74471
AuzObjects: viewtopic.php?f=26&t=75657
AuzBridges: viewtopic.php?f=26&t=75248
AuzStations: viewtopic.php?f=26&t=76390
AuzTracks: viewtopic.php?f=26&t=82691


Top
   
PostPosted: Wed Mar 06, 2019 8:44 pm 
Offline
Route Supervisor
Route Supervisor
User avatar

Joined: Wed Jan 08, 2003 11:09 pm
Posts: 440
Location: Denmark
I'm trying to splice together support for the 16-in-16-out feature, it works on the basic level, but yes it still needs a lot of care to be good.

Some tasks that aren't (as) dependent on grokking Python, parsers, and their combination:
- Writing better examples and test cases (NML code)
- Writing documentation and a migration guide for going from the old syntax and variables to the new


Top
   
PostPosted: Fri Mar 08, 2019 5:07 pm 
Offline
Tycoon
Tycoon
User avatar

Joined: Sat Jan 18, 2014 6:10 pm
Posts: 1148
I los my laptop together with all openttd dev environmen and, what is worse, together with command history.
Now I don't remeber, how to set-up properly nmlc on my new computer.
I have nmlc installed, nmlc dir added to the path, ply dir from ply-3.11 copied to nml-master dir,
now I'm trying to perform command
import ply.lex as lex
then computer is stalled for while, later I got message:
import: not authorized `lex' @ error/constitute.c/WriteImage/1028.
(even with sudo).
Any clue what goes wrong?


Top
   
PostPosted: Fri Mar 08, 2019 5:18 pm 
Offline
Tycoon
Tycoon

Joined: Wed Jan 17, 2007 12:14 am
Posts: 7312
i would guess it's trying to write a temp file somewhere it shouldn't.

have you tried using pip to install ply, instead of manually copying?

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


Top
   
PostPosted: Fri Mar 08, 2019 11:38 pm 
Offline
Tycoon
Tycoon
User avatar

Joined: Sat Jan 18, 2014 6:10 pm
Posts: 1148
Eddi wrote:
have you tried using pip to install ply, instead of manually copying?

Thanks, sudo apt-get install python-ply works well and is much more simply than generic method desrcibed on ply page.

_________________
My experimental openTTD server: 149.156.194.203:3979 non-standard client, now testing: JGRPP http://tiny.pl/ggnch
Projects: Reproducible Map Generation patch, NewGRFs: Manpower industries, PolTrams, Polroad, 600mm narrow gauge, preindustrial houses, wired, ECS industry extension.
Addicted to freeciv longturn.


Top
   
PostPosted: Tue Mar 12, 2019 10:25 am 
Offline
Tycoon
Tycoon
User avatar

Joined: Fri Oct 21, 2005 9:26 am
Posts: 975
Location: Birmingham, England
andythenorth wrote:
For 16-cargo-in-16-cargo-out, there's a set of updates from nielsm here https://github.com/PeterN/nml/commits/16-in-out

I'm testing them with FIRS, they work so far, but they may be incomplete.

If you know how to build NML yourself from the sources, you can try them, helping test will be very valuable.

https://github.com/OpenTTD/nml/
https://github.com/OpenTTD/nml/pull/15

Meanwhile...

NML has no regular maintainer or active contributors currently.

It has been kept on life support by frosch, planetmaker and me. But none of us are able to develop it or release it regularly.

To be quite precise then, it if newgrf authors wish to continue using NML, new contributors will need to emerge :)

Otherwise I think NML will die.

I am already evaluating the alternatives (nfo, m4nfo).


I'd love to help...BUT... I don't have regular internet access, I'm unable to compile anything at the moment, and barely know how to do it anyway.

I am very good at testing existing/new code and wrangling out bugs, so I'm very happy to assist with those tasks.

If there's anyone who has compiled this forked-nml and can send me a copy, then I'd love to give it a go. (via PM is fine)


Top
   
PostPosted: Thu Mar 14, 2019 3:05 pm 
Offline
Tycoon
Tycoon

Joined: Wed Jan 17, 2007 12:14 am
Posts: 7312
you don't have to compile nmlc, it's a python program that you can just run with an installed version of python

the .exe is just provided for convenience, and is basically just python and nmlc wrapped up in one bundle

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


Top
   
PostPosted: Tue Mar 19, 2019 10:17 am 
Offline
Tycoon
Tycoon
User avatar

Joined: Fri Oct 21, 2005 9:26 am
Posts: 975
Location: Birmingham, England
Ah, didn't know that. I'll give it a go. I can do some python programming, My skill level is about 5 out of 100 (so not exactly brilliant!)


Top
   
PostPosted: Thu Mar 21, 2019 8:01 am 
Offline
Traffic Manager
Traffic Manager
User avatar

Joined: Thu Jul 02, 2015 8:05 am
Posts: 177
Location: Czech Republic
Hi. I have a question about houses graphics. Is possible to have a house graphics dependent at population of the city? I know that way how to classify houses or city object generaly is due to city zones. But there is still a lot of objects what could be dependent at population. For example housing estates in the cities are in outskirts. Village has outskirt too but there are no housing estates. In case of population depndency I can for example say that this and this bulding will show in outskirt but the first building will be build in the cities under 1500 population and second in the cities above 1501. This will make cities more different - we will get smaller cities with "older" village's elements and bigger cities with modern elements.

Stefino_cz

_________________
Image


Top
   
PostPosted: Thu Mar 21, 2019 8:10 am 
Offline
Graphics Moderator
Graphics Moderator
User avatar

Joined: Mon Sep 13, 2004 1:21 pm
Posts: 5372
Location: The Moon
stefino_cz wrote:
Hi. I have a question about houses graphics. Is possible to have a house graphics dependent at population of the city?


Short answer: Yes. Long answer: Yeeees. Check the town variables.

You're probably better off having two different buildings (unless you want "old village" to become "modern city" instantly when the population hits 1501), and either gradually supplanting one with the other once a city reaches the size limit, having some buildings reserved for OpenTTD "Cities", or finding some other mechanism to decide when each is built.

_________________
Pikkarail.com blog | Patreon
Current development: UKRS3 - Av9.8 - TaI32 - CivilAI
Dev reference: NML Specs - NewGRF Specs - Savegame Internals - NoAI API - NoGo API


Top
   
PostPosted: Thu Mar 21, 2019 9:24 am 
Offline
OpenTTD Developer
OpenTTD Developer
User avatar

Joined: Wed Nov 07, 2007 10:44 pm
Posts: 9260
Location: Sol d
PikkaBird wrote:
You're probably better off having two different buildings (unless you want "old village" to become "modern city" instantly when the population hits 1501), and either gradually supplanting one with the other once a city reaches the size limit, having some buildings reserved for OpenTTD "Cities", or finding some other mechanism to decide when each is built.


Indeed. Don't make your lief needlessly complicated: use different houses / houseIDs for different looks.
Use placement rules for (dis)allowing construction instead of (ab)using animation for a single house.
As additional benefit you gain the advantage of the houses being constructed (constuction stages shown) when they change as a town grows beyond a size threshold instead of changing view in an instant.

https://newgrf-specs.tt-wiki.net/wiki/NML:Towns and https://newgrf-specs.tt-wiki.net/wiki/NML:Houses
Especially interesting might be the town variables is_city and population. And the house variables other_class_count_town (if you define house classes (property building_class) and use different for different towns). Use these variables in the houses construction_check callback.

_________________
Image
OpenTTD: manual | online content | translations | Wanted contributions and patches
#openttdcoop: blog | wiki | public server | DevZone | NewGRF web translator
DevZone - home of the free NewGRFs: OpenSFX | OpenMSX | OpenGFX | Swedish Rails | OpenGFX+ Trains|RV|Industries|Airports|Landscape | NML


Top
   
Display posts from previous:  Sort by  
Post new topic  Reply to topic  [ 1265 posts ]  Go to page Previous 160 61 62 63 64 Next

All times are UTC


Who is online

Users browsing this forum: No registered users and 3 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-2019 phpBB Limited

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