External Starmap Viewer (v0.3)

Moderator: Makail

Post Reply
User avatar
LuggLD
Posts: 143
Joined: Sun Oct 30, 2011 12:58 pm

External Starmap Viewer (v0.3)

Post by LuggLD » Sun Dec 25, 2011 4:01 am

DOWNLOAD:
Download it here: http://www.pyrron.com/sots2/mapview0.3.zip (v0.3)
ReadMe: http://www.pyrron.com/sots2/mapview-readme.txt

FEATURES:
# 3D rotating view of SotS II .starmap files
# Displays Starting Systems, Node Lines, and Terrain association of stars

FEATURES IN DEVELOPMENT
Coming soon™:
# Standalone .exe version

Coming later:
# GUI version
# Display of additional data for individual stars/terrains

Feature requests? Post them here!

Installation and Usage:
1. Install Python 2.72 from http://www.python.org (This project will not run under Python 3!)

2. Install VPython from http://www.vpython.org/

3. Unzip this package to your Sword of the Stars II starmaps folder (Default location: "C:\Program Files\Steam\steamapps\common\sword of the stars ii\assets\base\starmaps")

4. Open a command line (under Windows, press [Windows key]+[R], type "cmd" and hit [Enter].

5. Navigate to the your starmaps folder (See above)

6. Run this program with the command: python mapview.py [filename.starmap]
If this doesn't work, Python may not be in your system path. In that case, use the full path to the python.exe, e.g. c:\Python27\python.exe mapview.py [filename.starmap]

7. For configuration options, use "mapview.py -h"

Commandline options:
-h: displays help message
-p: highlights starting systems (default: off)
-t: colors stars according to their terrain (default off)
-n: displays nodelines (default off)
-v [X]: sets the verbosity level to X. 0 or 1 for normal usage, higher levels are only useful for debugging (default: 1)
-s [X]: sets display size in pixels of stars (default: 10)

Example:
python mapview.py -ptn mymap.starmap
-> opens mymap.starmap with all display options enabled

Known issues:
# There is no easy way to configure the tool, and there is no GUI[/list]

Please post here if you find bugs!

Changelog:
v0.3
# Added commandline argument parsing
# Fixed terrain translation/rotation issue

v0.2
# Added functionality and configuration options to display starting systems and terrains

v0.11
# Fixed parsing of Systems not within a Terrain block
# Added configuration options within the script file. Simply follow the instructions at the start of the file mapview.py (just edit it with a text editor) to enable/disable nodeline display, and set verbosity level

v0.1
# Initial release


Original Post:
Hey all!

I've spent a few hours this christmas eve writing an external 3d viewer for .starmap files. It works, but it's currently very slow and unoptimized, and I haven't figured out how to pack it for distribution yet - have to admit that I'm a total noob when it comes to this stuff.

Anyways, I was wondering if there's any demand for such a tool, and if yes, what features you'd like it to have. All it does right now is to display the stars and a coordinate system in 3D, and not much else - which suffices for what I needed it for today, but if there's any interest, I would release it and work on it some more.

So, any feature suggestions?
Last edited by LuggLD on Wed Dec 28, 2011 6:27 pm, edited 7 times in total.

User avatar
Daequeous
Posts: 97
Joined: Tue Dec 13, 2011 8:30 pm

Re: External Starmap Viewer

Post by Daequeous » Sun Dec 25, 2011 3:51 pm

I like this. It would open up the possibility of messing around with maps and generators away from the main gaming machine, e.g. on my laptop while commuting.

As for features; being able to rotate the map is high up on the list. As is focusing on a system and zooming in and out. Being able to see the nebulae would be nice, but that's not something I'd push for, as it's not that important, and probably very difficult and time consuming to implement. But the single most important thing I would like is the ability to see all node line connections between the stars, that would be absolutely stellar! Especially since right now there is no way (that I know of) to see this without actually starting a game as Sol Force and explore everything. That feature alone would make me use this tool on a regular basis! :awesome:
Random starmap generator with property sliders (and SotS prime map converter): Galaxy Generator

User avatar
LuggLD
Posts: 143
Joined: Sun Oct 30, 2011 12:58 pm

Re: External Starmap Viewer

Post by LuggLD » Sun Dec 25, 2011 6:00 pm

Daequeous wrote:I like this. It would open up the possibility of messing around with maps and generators away from the main gaming machine, e.g. on my laptop while commuting.

As for features; being able to rotate the map is high up on the list. As is focusing on a system and zooming in and out. Being able to see the nebulae would be nice, but that's not something I'd push for, as it's not that important, and probably very difficult and time consuming to implement. But the single most important thing I would like is the ability to see all node line connections between the stars, that would be absolutely stellar! Especially since right now there is no way (that I know of) to see this without actually starting a game as Sol Force and explore everything. That feature alone would make me use this tool on a regular basis! :awesome:


I'm working on node line display currently, that's also one I really want to have :) Rotating isn't a problem either.
I also managed to get it running smoothly even on my lousy netbook by switching to a different 3d package. It's all very command line at the moment, and I still don't know how to properly compile and distribute it, but if you're willing to install python and a few dependencies, I could just as well upload the sourcecode. Would prefer to have it as a standalone .exe and with a gui, but that's a lot of work I'm currently not very motivated to do ;)

User avatar
LuggLD
Posts: 143
Joined: Sun Oct 30, 2011 12:58 pm

Re: External Starmap Viewer

Post by LuggLD » Sun Dec 25, 2011 7:20 pm

Update: First release

Edit: It still has some issues and doesn't work properly for all starmaps, it seems. Can you say "rushjob"? ;) Also, you can't turn off nodeline display. I'll see what I can do about that.

User avatar
LuggLD
Posts: 143
Joined: Sun Oct 30, 2011 12:58 pm

Re: External Starmap Viewer (v0.11)

Post by LuggLD » Mon Dec 26, 2011 1:27 am

Updated to v0.11.

The program now displays all systems and nodelines as it should, but still doesn't take terrain block rotation/scaling into account. However, it should work for you if you're making your own maps and not using these features.

Changelog:
# Fixed parsing of Systems not within a Terrain block
# Added configuration options within the script file. Simply follow the instructions at the start of the file mapview.py (just edit it with a text editor) to enable/ disable nodeline display, and set verbosity level

dcarde007
Posts: 32
Joined: Sat Dec 03, 2011 9:33 pm

Re: External Starmap Viewer (v0.11)

Post by dcarde007 » Tue Dec 27, 2011 4:00 am

Tisk tisk..
You just created a multiplayer cheat.

You should remove the ability to view nodelines.

User avatar
LuggLD
Posts: 143
Joined: Sun Oct 30, 2011 12:58 pm

Re: External Starmap Viewer (v0.11)

Post by LuggLD » Tue Dec 27, 2011 11:00 am

Hmm... I see what you mean, but I don't think that's a valid point. After all, nodelines on all maps seem to always be the same, so once you've played a map a lot, you can know which planets are connected by a node line anyway, if you have a good memory.

Besides, removing it would kind of defeat the point of allowing map creators to check the custom maps they make for whether all planets are connected by nodelines.

Do you really think this tool could be abused in that way?

dcarde007
Posts: 32
Joined: Sat Dec 03, 2011 9:33 pm

Re: External Starmap Viewer (v0.11)

Post by dcarde007 » Tue Dec 27, 2011 4:57 pm

Sadly yes. :(

As long as node lines are not randomly generated and multiplayer starmaps are not encrypted we should make it as hard as possible for players to not cheat.
It puts SolForce players are a significant disadvantage.

For example:
Open clusters.starmap.
If SolForce starts in the top they must take the single star in the middle or they will effectively never be able to expand below it.

Typically only SolForce players would know that. By making it easy to find out, even players who have never played as SolForce would know how to cripple them.

User avatar
LuggLD
Posts: 143
Joined: Sun Oct 30, 2011 12:58 pm

Re: External Starmap Viewer (v0.11)

Post by LuggLD » Tue Dec 27, 2011 8:30 pm

I respect your opinion, but I don't think your point that this tool is "cheating" is valid, for several reasons.

First of all, the information on node lines that this tool provides is not information you can get exclusively with this tool - in fact, you can get it without even looking at the game files, by simply playing a game as SolForce on the map in question. Secondly, the fact that this tool makes access to that information easier is not an argument. Security through obscurity is not security at all ;-) And thirdly, "cheating" would imply that this tool alters the game state in some way, which it most certainly does not.

You also seem to imply that most players only ever play one race. I for one play most of them equally often, so even if I happen to play against you as a Tarka, I might have remembered the node line layout of the map we're playing from the last time I played it as SolForce.

Now, on the other hand, map creators need a tool like this in order to be able to check their maps for errors without spending hours playing on each iteration of their potentially broken maps - and map creators are this tools intended users. If you ever tried making a map without being able to check this stuff, you'd know what a pain in the bum it is.

In conclusion, I think the utility provided by this tool far outweighs its potential to be used as a cheating tool.

User avatar
LuggLD
Posts: 143
Joined: Sun Oct 30, 2011 12:58 pm

Re: External Starmap Viewer (v0.2)

Post by LuggLD » Tue Dec 27, 2011 9:11 pm

Updated to v0.2!

Changelog:
# Added functionality and configuration options to display starting systems and terrains

dcarde007
Posts: 32
Joined: Sat Dec 03, 2011 9:33 pm

Re: External Starmap Viewer (v0.11)

Post by dcarde007 » Tue Dec 27, 2011 9:29 pm

A definition of cheat:
Cheat (verb): to take an examination or test in a dishonest way, as by improper access to answers.

If the devs balanced SolForce with the knowledge that node lines create bottle necks that any competitive player will know about
and exploit, then it's not a cheat.

If the general consensus is that SolForce is so powerful that they need to be hindered by every race knowing exactly where they can go, then it's not a cheat. And we should ask the devs to enable all races to see the node lines from the beginning of the game. Perhaps make it a toggle so they can see them only when they want to see them.
(Though, that doesn't make much sense.. why would the other races know the path of the node lines if they don't have that technology?) Another idea would be to tie it into a tech that any race could research, but who would research it when you could Alt-Tab and just look at it.

I agree that map makers need to visually see the node lines as well as save and then open those files.
Now if both of the above are not true, then perhaps you could disable the cheat in public and provide it by request?
It's a fact that the harder you make it to cheat, the less cheaters there will be.

User avatar
LuggLD
Posts: 143
Joined: Sun Oct 30, 2011 12:58 pm

Re: External Starmap Viewer (v0.2)

Post by LuggLD » Tue Dec 27, 2011 9:41 pm

dcarde007 wrote:If the devs balanced SolForce with the knowledge that node lines create bottle necks that any competitive player will know about
and exploit, then it's not a cheat.


I would say that that's a deliberate quality of the SolForce propulsion technology. They're fast, but have to travel along node lines. Players knowing about the location of these node lines can act on that knowledge and try to block them.

If the general consensus is that SolForce is so powerful that they need to be hindered by every race knowing exactly where they can go, then it's not a cheat. And we should ask the devs to enable all races to see the node lines from the beginning of the game. Perhaps make it a toggle so they can see them only when they want to see them.


The technology to see human nodelines is only a 2nd tier C3 technology for all races, if I'm not mistaken.

Anyway, I would say that the success of your strategies when playing as SolForce doesn't depend solely on the other player(s) knowing which routes you can and can't go. It also depends on them being able to actually do something about it. Intel is half the battle, but it's still only half ;)

And if you're worried that someone will use this tool to get a good look at the nodeline layout when playing against you while you are playing as SolForce, I think you should just ask them not to. After all, there isn't any public matchmaking in the game that I'm aware of, so you probably know the person you're playing against. And we're all gentlepeoples, right? ;)

User avatar
ProjectLevyDelta
Posts: 3945
Joined: Fri Nov 12, 2010 4:42 am

Re: External Starmap Viewer (v0.11)

Post by ProjectLevyDelta » Wed Dec 28, 2011 5:19 pm

dcarde007 wrote:A definition of cheat:
Cheat (verb): to take an examination or test in a dishonest way, as by improper access to answers.




Lets walk this through slowly.

This... it the modding forum...

I believe Mods change the way the game works or adds new content not currently in the game for other people to use. If you feel like making a map where everyone can see the node lines I believe you have a right to do so, if you want to swap Cruisers with Leviathans well then why not, if you want to give all Hivers 100% to all technology then go ahead :twisted: . :lol: it the modding forum... not the General Discussion forum.
Image

User avatar
LuggLD
Posts: 143
Joined: Sun Oct 30, 2011 12:58 pm

Re: External Starmap Viewer (v0.3)

Post by LuggLD » Wed Dec 28, 2011 6:27 pm

Update: v0.3

See original post for download link!

Changelog:
# Added commandline argument parsing
# Fixed terrain translation/rotation issue 8)

Thanks to GammaPaladin for pointing me in the right direction on that last one :)

Mordachai
Posts: 24
Joined: Tue Apr 03, 2012 2:58 am

Re: External Starmap Viewer (v0.3)

Post by Mordachai » Wed Apr 04, 2012 2:00 am

It would be great to see this integrated as an option on Daequeous' Galaxy Generator. A simple button that launches this tool on the map just generated would be a nice feature! 8)

One question: Having generated one map from Daequeous' Galaxy Generator, I can see no node lines. Everything else appears to be working. Any thoughts?

Also: is there a zoom function in the viewer - the rotate is clear... but how to zoom in/out?

Post Reply

Return to “Modding”

Who is online

Users browsing this forum: No registered users and 2 guests