Thanks for getting back to me on this. The plan was always to compile a list of pixel coordinates but then you mentioned ripping out code. This might be above my pay grade! More tinkering required!jimbob wrote:
Hey, I'm affraid I can't really remember much about this script, but I believe I ran it through the debug console. Because parts of the script were ran through a company (roads) and rail and canals were planned it was converted to an AI which only run in a game. Having let the script run in the new game, you can rename the extension to open the "game save" as a scenario again.
The UK heightmap I used was a geospatial TIFF which was in OSGB coordinates, I had to sample coordinates at the two ends of the UK to get scaling factor to convert between OSGB and pixels. All my points for towns/rivers/roads were loaded from a number of Ordance Survey layers also in OSGB. QGIS is very good at handling all the coordinates and heightmap information as well as all the different strange coordinates systems maps use. I would do everything in QGIS before converting your layers to any projection which uses Eastings and Northings in meters, then manually do the conversion between meters and pixels.
Of course if your heightmap is not a geospatial image (the good news is you don't have to worry about GIS, but the bad news is you can't just auto generate your towns from map data), I would start off with pixels coordinates, any decent image editor should be able to get your pixel coordinates, and just move your cursor to the point and copy the numbers into that section of the nut file. This would also need ripping out all of the code which converts OSGB to pixels
I don't know anything about patch packs but if the pack can load vanillia scenarios I'd run it all in vanillia before loading it with JGR.
Moderator: OpenTTD Developers
No worries, you should be able to handle it, it currently has a list of coordinates like your plan, only they get passed through a function f(x)=ax+c f(y)=by+dle_harv wrote: Thanks for getting back to me on this. The plan was always to compile a list of pixel coordinates but then you mentioned ripping out code. This might be above my pay grade! More tinkering required!
where a,b,c,d are to convert from British National Grid meters into map pixels
either remove the transform functions or set a,b,c,d = 1
some of the industries and trees are a little fancier as you can set the top left and bottom right bounding box to create many industry/trees within the box. likewise the roads you can set the two positions to build a road between.
Yes, it was hard coded for some UK data but if you can change the excel file and copy and paste the code into the nut file you can make it work for anywhere you can find data for
Users browsing this forum: No registered users and 5 guests