Fractal Softworks Forum

Please login or register.

Login with username, password and session length
Pages: [1] 2 3 ... 5

Author Topic: Mission editor 0.5 (Updated April 10) LINUX COMPATIBLE  (Read 38171 times)

Xanderzoo

  • Captain
  • ****
  • Posts: 342
    • View Profile
Mission editor 0.5 (Updated April 10) LINUX COMPATIBLE
« on: March 16, 2015, 08:27:15 PM »

This is a program I wrote that facilitates the creation of missions. I was making a mission, and realized just how easy it would be to automate it, while it takes significant time to do by hand. At first I was only going to use it for myself, but I decided that someone else might find it useful. Because of this, it isn't exactly a snap to set up.

THIS PROGRAM WORKS ON WINDOWS ONLY (I'm trying to fix that, but I can't if no one tests for me.) The source (Not the executable) works on Linux, and possibly Mac. If it doesn't work for you, please report it.

Compiled .exe: (WINDOWS ONLY)
Compiled exe

Source (This program was written in Python--google it.): (CROSS PLATFORM)
Source


How to install


If you're on Linux, click here for the instructions by Azmond: Link

If you're on Windows:

Spoiler
First, try this:
  • Click on the .exe link and download
  • Extract the zip file
  • Enter the dist folder
  • Double-click on the MissionMaker program.

If that doesn't work

Python is an interpreted language, not a compiled one. That means that the .exe is not actually a machine code version of the program. It is a bundled version of Python along with the source. Because of this, there are reasons it may not work. Microsoft does not allow distribution of certain DLLs, so I was unable to include them in the executable. Most windows computers should have these DLLs, but not all. If the executable fails for any reason, try following these instructions. I am also unsure if the executable will work on anything other than Windows 7. I now believe it will work on Windows 8 as well as 7.


Spoiler
  • Download Python 2.7 here: https://www.python.org/download/releases/2.7.6/. Click Windows x86 MSI Installer (2.7.6) and install. (Even if you have a 64-bit computer). Make sure to install it in a Python27 folder (It will default to that)
  • Download Pygame here http://www.pygame.org/download.shtml. Click pygame-1.9.1.win32-py2.7.msi and install.
  • Click on the source link for MissionMaker. Download.
  • Place the zipped file in your Python27 folder.
  • Extract.
  • Enter the StarsectorMissionMaker folder
  • The MissionMaker.py file should have an icon that looks sort of like a piece of paper with a blue and yellow plus sign on it. If it doesn't have an icon, either something is horribly wrong or you made a mistake at some point.
  • Double click MissionMaker.py. The computer should know to run it with python.

[close]

Now, you must change the paths.txt file (Note, you have to do this even if you use the executable.)

Make sure to keep the syntax the same.

For the first four, just change "C://Program Files (x86)" to wherever you put Starsector.
For the bottom one, change MissionPack to the mod you want to add missions to. Your mod must already have a missions subfolder in its data folder.

I realize that it's a bit difficult to set up MissionMaker. If you have any problems, post a comment and I'll try to help.

[close]

How to use

Spoiler



(If the above image isn't showing up, you can go here to see a screenshot: https://www.dropbox.com/s/fiqx2fh114duwgq/Screenshot.JPG?dl=0)

MissionMaker is quite simple to use. Use the mouse wheel to scroll through the available ships. Left click to add the ship to the active fleet. Left arrow to set active fleet to player, right arrow to set active fleet to enemy. You can remove a ship from the active fleet by right clicking on it. You can add Nav Buoys, Comm Relays and Sensor Arrays with the left/middle/right mouse buttons. You can add nebulae by left clicking and dragging, and remove them by right clicking.  You can add asteroid fields by left clicking and dragging, however you cannot remove them yet. After you've set up both fleets and finished with objectives/nebulae, press the spacebar. You can load missions by pressing 'L'. Loading missions is a work in progress; it will only load ships, not nebulae asteroid belts or objectives.

You will now be asked some questions.
  • What to call the mission folder: If you've ever made a mission before, you know what to do. This cannot have any spaces, and should probably be lowercase.
  • What is the name of the mission? This can be whatever you want.
  • What is the difficulty of the mission? Again, whatever you want.
  • It will ask you for the width and height of the map. Just enter a number
  • It will ask you for the number of command points the player gets. Just enter a number.
  • The program will now generate your mission.

What MissionMaker doesn't do

  • Set an icon for the mission MissionMaker now sets a default icon, but you are suggested to change it.
  • Add objectives or nebulae MissionMaker can now do this.
  • Set the background image MissionMaker now sets a default background, but you are suggested to change it.
  • Add the mission to mission_list.csv

[close]

Limitations of MissionMaker
Spoiler
As much as I would like to say this is perfect, it is still a work in progress. Here are some things it cannot do

  • Add ships from a mod (Annoying, will try to fix) - FIXED!
  • Work on operating systems other than Windows (Really annoying, will try to fix) - Partially fixed. Source will run on Linux, and possibly Mac, but no EXE.
  • Install easily (Annoying, but I don't think I can do much about it because I wrote it in Python.)
[close]

Releases:
Spoiler
Code
0.1: The initial release

0.2: Adds the ability to place objectives in the program. For information, see the update comment.

0.21: Adds the ability to delete objectives in the program. For more information, see the update comment.

0.3: Adds the ability to add nebulae in the program. For more information, see the update comment.

0.31: Sets a default icon and background image. For more information, see the update comment.

0.4: You can now scroll by clicking and dragging the middle mouse. You can now add ships from mods. There are now five items required in paths.txt.
For more information, see the update comment.

0.41: Code is now commented

0.42: Asteroid field capability added. Draw order modified. See update comment for details

0.43: You can now toggle mod ships by pressing 'm'. See update comment for details

0.44: Fixes a bug related to zip files. See update comment for details.

0.45: Asks the user for the width and height of the battlefield. Also asks for the player's command points.

0.46: The user an now enable/disable mods on a per-mod basis. See update comment for details.

0.47: Started work on loading missions. See update comment for details.

0.5: Source works on Linux, possibly Mac. Mission loading still only partially implemented. Automatically modifies mission_list.csv. See update comment for details.
[close]

TODO (In the order they will probably be implemented):

Spoiler
  • Add objectives in the program - Completed!
  • Add nebulae in the program - Completed!
  • Add asteroid belts - Completed!
  • Add option to show/unshow modded ships - Obselete
  • Add option to show/unshow modded ships on a per mod basis - Completed!
  • Add ability to remove asteroid belts Hard
  • Support other operating systems - Partially completed. Source will run on Linux, and possibly Mac.
  • Ability to add ships from mods - Completed!
  • Automatically add mission to mission_list.csv - Completed!
  • Ability to load already created missions - Partially completed
[close]

If you have any difficulties getting this to work, just post a comment and I'll try to help.

If you have got this to work, I'd really appreciate some feedback.
« Last Edit: April 11, 2015, 08:56:04 AM by Xanderzoo »
Logged

c plus one

  • Commander
  • ***
  • Posts: 174
  • 'Make Jumpgates Great Again!'
    • View Profile
Re: Mission editor
« Reply #1 on: March 16, 2015, 10:23:37 PM »

Immediate thoughts:

1) Squeeee!  :-* At last, a mission editor!

2) This utility mod sounds potentially outstanding. Thank you for devoting your efforts to it.

3) I hope you'll add a version number to future iterations of this editor.

4) As for the Windows-only thing, I'm sympathetic to that and will be patient for a Mac OS X version at some future date.

5) For the future -- On my crufty old Mac, I can't play any 64-bit version of the game. There is a newer Mac in the house but I'm not allowed to play games on it. Does your editor care if it's being asked to generate content for a 32-bit version of the game? Sometimes I dust-off older versions of Starsector in order to avoid some vanilla things I dislike, or to play with mods that are no longer updated.
Logged
Quote from: Lopunny Zen
you are playing them wrong then..

Don't tell me I'm playing anything wrong in a singleplayer sandbox game. Just don't.

Xanderzoo

  • Captain
  • ****
  • Posts: 342
    • View Profile
Re: Mission editor
« Reply #2 on: March 16, 2015, 10:33:20 PM »

1)  ;) I've always wanted one two.
2) Well, it's not really a mod, and it wasn't that hard to make, but thank you for the compliment!
3) When I release a new version, I'll give it a version number.
4) I only have Windows and Ubuntu, so it might be difficult for me to make this work on Mac. Maybe you could help me with that?
5) I'm 99.9% sure it'll work. If it doesn't, please tell me so I can try to fix it.

Edit: I added version number
« Last Edit: March 16, 2015, 10:46:37 PM by Xanderzoo »
Logged

Xanderzoo

  • Captain
  • ****
  • Posts: 342
    • View Profile
Re: Mission editor 0.2 (Updated Feb 17)
« Reply #3 on: March 17, 2015, 11:34:10 AM »

Mission Editor 0.2 Release

You can now place objectives in the program. After you've finished setting up the player and enemy fleets, press the right arrow to go into the objectives mode. Use the left mouse button to place Nav Buoys, the middle mouse button for Comm Relays, and the right mouse button for Sensor Arrays.

The download links have been updated.

If you have any problems, or discover a bug please tell me so I can fix it.
Logged

Xanderzoo

  • Captain
  • ****
  • Posts: 342
    • View Profile
Re: Mission editor 0.2 (Updated March 18)
« Reply #4 on: March 17, 2015, 08:27:00 PM »

Mission Editor 0.21 Release

You can now remove objectives you have already placed. Right click on an already placed objective to remove it.

The download links have been updated.

If you have any problems, or discover a bug, or have a suggestion/request, please tell me so I can fix/add it.
« Last Edit: March 18, 2015, 08:03:10 PM by Xanderzoo »
Logged

Xanderzoo

  • Captain
  • ****
  • Posts: 342
    • View Profile
Re: Mission editor 0.3 (Updated March 18)
« Reply #5 on: March 17, 2015, 10:44:02 PM »

Mission Editor 0.3 Release

You can now add/remove nebulae. After you've finished with objectives, press the right arrow key to go into nebulae mode. Use left mouse button and drag to add nebulae, and right mouse button to remove them.

The download links have been updated.

If you have any problems, discover a bug, or have a suggestion/request, please tell me so I can fix/add it.

Also, I am wondering if anyone has actually tried this. If you have downloaded this program please leave a comment.  :) I just want to figure out if anyone has tried this and if I should continue to post updates.
Logged

Xanderzoo

  • Captain
  • ****
  • Posts: 342
    • View Profile
Re: Mission editor 0.3 (Updated March 18)
« Reply #6 on: March 18, 2015, 10:12:16 AM »

Mission Editor 0.31 Release

MissionMaker will now automatically set a default background image and icon. You are suggested to change these, however.

The download links have been updated.

If you have any problems, discover a bug, or have a suggestion/request, please tell me so I can fix/add it.

This will probably be the last update because it doesn't seem like anyone is using this and I don't want to clog the forum with something no one is using. I'll keep working on it, but I probably won't post updates. If anyone does have interest in this, I will continue to post updates.
Logged

WKOB

  • Admiral
  • *****
  • Posts: 732
  • Odobenidine Benefactor
    • View Profile
Re: Mission editor 0.3 (Updated March 18)
« Reply #7 on: March 18, 2015, 10:42:40 AM »

Oh wow, a bunch of updates. This is a very cool endeavor. It's tools like this and Trylobot's that will keep this modding community going even when the modders who really know what they're doing take breaks, allowing for new pros, old pros to come back and modding noobs to learn.

I'll admit, it's a little bit too limited and rough to use as a tool for personal modding just yet, but of course you've only just started and it is a good basis.

Anyway, good work, mate.
Logged

Xanderzoo

  • Captain
  • ****
  • Posts: 342
    • View Profile
Re: Mission editor 0.3 (Updated March 18)
« Reply #8 on: March 18, 2015, 11:00:17 AM »

All right, if people are interested, I will continue to update it.  :)

When you say it's a little bit to limited and rough to use, do you think you could give me some examples so I can work on improving it?
Logged

WKOB

  • Admiral
  • *****
  • Posts: 732
  • Odobenidine Benefactor
    • View Profile
Re: Mission editor 0.3 (Updated March 18)
« Reply #9 on: March 18, 2015, 11:39:41 AM »

Well, actually, this latest batch of updates helped immensely. :D Outside of that, it's things you're aware of, like mod support.
Logged

Xanderzoo

  • Captain
  • ****
  • Posts: 342
    • View Profile
Re: Mission editor 0.3 (Updated March 18)
« Reply #10 on: March 18, 2015, 11:47:39 AM »

Yeah, adding mod support will be vital. I'm actually putting together a set of missions using this editor to demonstrate it. I'll put them on the forum soon.
Logged

Xanderzoo

  • Captain
  • ****
  • Posts: 342
    • View Profile
Re: Mission editor 0.3 (Updated March 18)
« Reply #11 on: March 18, 2015, 12:11:55 PM »

I've created a set of example missions here if you're interested.
Logged

Thaago

  • Global Moderator
  • Admiral
  • *****
  • Posts: 7209
  • Harpoon Affectionado
    • View Profile
Re: Mission editor 0.3 (Updated March 18)
« Reply #12 on: March 18, 2015, 02:41:11 PM »

Thank you for making this - I'm definitely going to play with this later. Nice to see another Python user!

It should be fairly simple to make Linux compatible, as (almost) all distributions have python installed and on the path. The main code, a copy of pygame, and a .sh file should do the trick.

Macs I have no idea - my old laptop died about 4 years back and I haven't used one since.
Logged

Xanderzoo

  • Captain
  • ****
  • Posts: 342
    • View Profile
Re: Mission editor 0.3 (Updated March 18)
« Reply #13 on: March 18, 2015, 03:42:41 PM »

@Thaago:

Unfortunately, it's not quite that simple. While Linux does have Python, it may not have the correct version (2.7). The user could still download the correct version, but there's another problem: file paths. I developed this on Windows, so it uses Windows paths. Eventually, I will replace all paths with os.path.join calls, but that still won't fix the problem of paths in the MissionDefinition.java file.

Eventually I will probably get Linux comparability (and possible Mac), but it will probably be after I've finished the other features.

If you have any ideas on how get it to work, I would appreciate it.  :)
« Last Edit: March 18, 2015, 03:46:54 PM by Xanderzoo »
Logged

Xanderzoo

  • Captain
  • ****
  • Posts: 342
    • View Profile
Re: Mission editor 0.4 (Updated March 18) MODDED SHIP SUPPORT ADDED
« Reply #14 on: March 18, 2015, 07:57:24 PM »

Mission Editor 0.4 Release

I added it! Modded ships can now be added. I should note that my system is not 100% successful--some mod configurations will mess it up. However, I have tested it with a variety of mods (Blackrock, Citadel, Exigency, Neutrino, Interstellar Imperium, Starsector+, Templars, and Valkirians, and they all seem to work. If you encounter any crashes or strange behavior, please tell me.

You can now also scroll by clicking the middle mouse button and dragging.

The download links have been updated.

If you have any problems, discover a bug, or have a suggestion/request, please tell me so I can fix/add it.
« Last Edit: March 18, 2015, 08:05:47 PM by Xanderzoo »
Logged
Pages: [1] 2 3 ... 5