Town Name Sets - Scenario Opportunity
Moderator: TTDPatch Moderators
Re: Town Name Sets - Scenario Opportunity
I guess this could be patched into TTDPatch aswell, but the impact may be bigger in TTDPatch.
Still loading a height map into TTDPatch would be nice as well, I wonder if someone could send me a heightmap.s (gcc -S)
from OTTD, -edit- Have copied the relevant part and produced my own assembler dump
Still loading a height map into TTDPatch would be nice as well, I wonder if someone could send me a heightmap.s (gcc -S)
from OTTD, -edit- Have copied the relevant part and produced my own assembler dump
TTDPatch dev in retirement ... Search a grf, try Grf Crawler 0.9 - now with even faster details view and new features...


Re: Town Name Sets - Scenario Opportunity
Oskar, I installed r2073, made sure I had a 256x256 headerless raw image named height.raw in my TTDX folder, started TTDX and entered the Scenario editor and ran cht: heightmap. I got an error message: Cannot carry out sign cheat action Invalid parameter.
I tried cht: heightmap height, cht: heightmap height.raw, and cht: heightmap 6 (assuming that a height might be needed) and I got the same error each time.
Just in case, I checked my new patch cfg for a switch but there was none.
Did I do something wrong? Or maybe the cheat is not ready for use yet?
I tried cht: heightmap height, cht: heightmap height.raw, and cht: heightmap 6 (assuming that a height might be needed) and I got the same error each time.
Just in case, I checked my new patch cfg for a switch but there was none.
Did I do something wrong? Or maybe the cheat is not ready for use yet?
wallyweb on tt-forums: Screenshots - Wallyweb World - Projects & Releases
wallyweb on Simuscape: Projects - Releases
Other Stuff: TTDPatch 2.6 "Nightly" download - cirdan's OpenTTD branch (New Map Features)
Screenshot Of The Month Contest Winner: August 2015 - Tied May 2016 - January 2018 - December 2018 - May 2019
wallyweb on Simuscape: Projects - Releases
Other Stuff: TTDPatch 2.6 "Nightly" download - cirdan's OpenTTD branch (New Map Features)
Screenshot Of The Month Contest Winner: August 2015 - Tied May 2016 - January 2018 - December 2018 - May 2019
Re: Town Name Sets - Scenario Opportunity
I guess I should add some more error checking at the evening, currently this cheat has no error checking then telling it failed...
You could send me the heightmap please so I can look into it, thanks...
You could send me the heightmap please so I can look into it, thanks...
TTDPatch dev in retirement ... Search a grf, try Grf Crawler 0.9 - now with even faster details view and new features...


Re: Town Name Sets - Scenario Opportunity
I thought you might ask ... It is posted below, but, before you open it, you must promise not to laugh.eis_os wrote:You could send me the heightmap please so I can look into it, thanks...

- Attachments
-
- height.zip
- (4.17 KiB) Downloaded 234 times
wallyweb on tt-forums: Screenshots - Wallyweb World - Projects & Releases
wallyweb on Simuscape: Projects - Releases
Other Stuff: TTDPatch 2.6 "Nightly" download - cirdan's OpenTTD branch (New Map Features)
Screenshot Of The Month Contest Winner: August 2015 - Tied May 2016 - January 2018 - December 2018 - May 2019
wallyweb on Simuscape: Projects - Releases
Other Stuff: TTDPatch 2.6 "Nightly" download - cirdan's OpenTTD branch (New Map Features)
Screenshot Of The Month Contest Winner: August 2015 - Tied May 2016 - January 2018 - December 2018 - May 2019
Re: Town Name Sets - Scenario Opportunity
That seems to be true color, currently the code loader only supports gray scale, the filesize needs to be exact 65536 bytes, or 64KiB.
The problem is that currently TTDPatch doesn't allow dynamic allocations so porting libpng isn't a trivial task
The problem is that currently TTDPatch doesn't allow dynamic allocations so porting libpng isn't a trivial task
Re: Town Name Sets - Scenario Opportunity
I will convert it to gray scale and try again.eis_os wrote:That seems to be true color, currently the code loader only supports gray scale, the filesize needs to be exact 65536 bytes, or 64KiB.
The problem is that currently TTDPatch doesn't allow dynamic allocations so porting libpng isn't a trivial task

wallyweb on tt-forums: Screenshots - Wallyweb World - Projects & Releases
wallyweb on Simuscape: Projects - Releases
Other Stuff: TTDPatch 2.6 "Nightly" download - cirdan's OpenTTD branch (New Map Features)
Screenshot Of The Month Contest Winner: August 2015 - Tied May 2016 - January 2018 - December 2018 - May 2019
wallyweb on Simuscape: Projects - Releases
Other Stuff: TTDPatch 2.6 "Nightly" download - cirdan's OpenTTD branch (New Map Features)
Screenshot Of The Month Contest Winner: August 2015 - Tied May 2016 - January 2018 - December 2018 - May 2019
Re: Town Name Sets - Scenario Opportunity
So, does this want an image in a specific format, or does it want 64KiB's worth of bytes representing height?eis_os wrote:That seems to be true color, currently the code loader only supports gray scale, the filesize needs to be exact 65536 bytes, or 64KiB.
~ Lakie
TTDpatch Developer 2005 - 2010 ~ It all started because of shortened vehicle not loading correctly, now look where I've gone with it!
Grfs coded ~ Finnish Train Set (Teaser) | Bm73 (Release 3) | Emu 680 (Release 3)| Glass Station (Release 1) | UK Roadset (Version 1.1a) | New Water Coasts (Version 7)
Pikka: "Lakie's a good coder, but before he'll add any feature to TTDP you have to convince him that you're not going to use it to destroy the world as we know it."
Grfs coded ~ Finnish Train Set (Teaser) | Bm73 (Release 3) | Emu 680 (Release 3)| Glass Station (Release 1) | UK Roadset (Version 1.1a) | New Water Coasts (Version 7)
Pikka: "Lakie's a good coder, but before he'll add any feature to TTDP you have to convince him that you're not going to use it to destroy the world as we know it."
Re: Town Name Sets - Scenario Opportunity
My understanding is that it wants the latter. I have not looked at the code, though.
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
Projects: NFORenum (download) | PlaneSet (Website) | grfcodec (download) | grfdebug.log parser
Re: Town Name Sets - Scenario Opportunity
IT WORKS! IT WORKS!
The attached zip contains the raw file I used. It also contains four png screenshots.
I was able to build a town using the Canadian Town Set. Sorry ... It's not in the screenshots.
Note that the invalid parameter error still occurs, but hey! IT WORKS!
The only thing I would change, besides the error, is to make the raw file selecteable instead of having to rename it to height.raw.
Cookies are cooking

The attached zip contains the raw file I used. It also contains four png screenshots.
I was able to build a town using the Canadian Town Set. Sorry ... It's not in the screenshots.
Note that the invalid parameter error still occurs, but hey! IT WORKS!
The only thing I would change, besides the error, is to make the raw file selecteable instead of having to rename it to height.raw.
Cookies are cooking



- Attachments
-
- height.zip
- (84.2 KiB) Downloaded 236 times
wallyweb on tt-forums: Screenshots - Wallyweb World - Projects & Releases
wallyweb on Simuscape: Projects - Releases
Other Stuff: TTDPatch 2.6 "Nightly" download - cirdan's OpenTTD branch (New Map Features)
Screenshot Of The Month Contest Winner: August 2015 - Tied May 2016 - January 2018 - December 2018 - May 2019
wallyweb on Simuscape: Projects - Releases
Other Stuff: TTDPatch 2.6 "Nightly" download - cirdan's OpenTTD branch (New Map Features)
Screenshot Of The Month Contest Winner: August 2015 - Tied May 2016 - January 2018 - December 2018 - May 2019
Re: Town Name Sets - Scenario Opportunity
Currently 256x256 Bytes, this is called raw or binary data in graphic applications. (Not raw as in camera files, but it's the same idea, get the rough binary data from the camera chip)Lakie wrote:So, does this want an image in a specific format, or does it want 64KiB's worth of bytes representing height?eis_os wrote:That seems to be true color, currently the code loader only supports gray scale, the filesize needs to be exact 65536 bytes, or 64KiB.
~ Lakie
No idea why it doesn't set the flags right so the cheat is successfully, as I said the current code doesn't do much error checking, it still lacks a reset landscape call and checking if it's in a scenario editor or not...
I do think supporting a real file format would be nice, any idea maybe including a GPL compatible lib we can add to TTDPatch?
Re: Town Name Sets - Scenario Opportunity
Success is indicated by the carry flag upon return from the cheat handler. Clear means success: http://svn.ttdpatch.net/trac/browser/tr ... ht.asm#L83
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
Projects: NFORenum (download) | PlaneSet (Website) | grfcodec (download) | grfdebug.log parser
Re: Town Name Sets - Scenario Opportunity
png?eis_os wrote:I do think supporting a real file format would be nice, any idea maybe including a GPL compatible lib we can add to TTDPatch?
wallyweb on tt-forums: Screenshots - Wallyweb World - Projects & Releases
wallyweb on Simuscape: Projects - Releases
Other Stuff: TTDPatch 2.6 "Nightly" download - cirdan's OpenTTD branch (New Map Features)
Screenshot Of The Month Contest Winner: August 2015 - Tied May 2016 - January 2018 - December 2018 - May 2019
wallyweb on Simuscape: Projects - Releases
Other Stuff: TTDPatch 2.6 "Nightly" download - cirdan's OpenTTD branch (New Map Features)
Screenshot Of The Month Contest Winner: August 2015 - Tied May 2016 - January 2018 - December 2018 - May 2019
Re: Town Name Sets - Scenario Opportunity
libpng is quite big and as far as I remember it tries to do direct fileio via fopen/fclose... , it isn't GPL either...
- edit-
DaleStan: it's simply a missing jmp before .fail
http://svn.ttdpatch.net/trac/browser/tr ... p.asm#L193
- edit-
DaleStan: it's simply a missing jmp before .fail
http://svn.ttdpatch.net/trac/browser/tr ... p.asm#L193
TTDPatch dev in retirement ... Search a grf, try Grf Crawler 0.9 - now with even faster details view and new features...


Re: Town Name Sets - Scenario Opportunity
Oskar, can you add a comment explaining those NOPs, please? Also, why you used a 5-byte AND instead of a 3-byte MOVZX?
Finally, ax is not a valid 16-bit address register, but I've fixed that one.
Finally, ax is not a valid 16-bit address register, but I've fixed that one.
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
Projects: NFORenum (download) | PlaneSet (Website) | grfcodec (download) | grfdebug.log parser
Re: Town Name Sets - Scenario Opportunity
Simply bad code quality and simply the fact I didn't work much on TTDPatch actually nothing.
The nops are a debugging session place holder.. should be removed.
The nops are a debugging session place holder.. should be removed.
Who is online
Users browsing this forum: No registered users and 9 guests