Topic: Map analyse script
kaputtnik Topic Opener |
Posted at: 2023-12-02, 20:29
This topic can also be made in Coding and Scripting but since my new script is probably most important for map designers, i put it in this forum. I am working on a map analysis tool which gathers some information about a map. The information it provides are:
Currently this script can only be used with debug builds, but it is planned to make it accessible via the UI as addon. But i want to ask if you think if this script is useful at all. So if you want to test it:
Then you have three possibilities:
Attached is the script. A screenshot will be attached to the next post. Fight simulator for Widelands: |
||||||||||||
kaputtnik Topic Opener |
Posted at: 2023-12-02, 20:31
A screenshot for statistics of a whole map. The map was a 160x160 map and running Edited: 2023-12-02, 20:31
Fight simulator for Widelands: |
||||||||||||
kaputtnik Topic Opener |
Posted at: 2023-12-21, 16:04
I gave the script some more love and now it shows also the vicinity of a player: The player analysis shows which resources are nearby the players starting position (as defined in the map), which amount of this resource is available and how far away this resource deposit is. I was also able to make it incredible fast and shrunk drastically the memory consumption. For comparison: If i ran this script on the map Europe 1.2 ( with a dimension of 512x512 the biggest map) and examining the whole map:
For smaller maps this script runs without any noticeable delay. Attached a screenshot of the current state. For a comparison i made also a screenshot with the default widelands theme. Fight simulator for Widelands: |
||||||||||||
kaputtnik Topic Opener |
Posted at: 2023-12-21, 16:14
Here is the updated version of the script. Edit: The script contains currently some memory statements which prints the used memory to stdout (or the console). If you are interested you can compare the output and the corresponding places inside the script to get an impression of memory usage and which statement is clearing memory. Edited: 2023-12-21, 16:24
Fight simulator for Widelands: |
||||||||||||
kaputtnik Topic Opener |
Posted at: 2023-12-21, 16:35
The table of "Players and their vicinity" and an explanation:
The icons below the players table are self explaining, imho. Edited: 2024-01-24, 09:29
Fight simulator for Widelands: |