SoniPlane

Discussion in 'Utilities' started by AURORA☆FIELDS, Apr 17, 2015.

  1. AURORA☆FIELDS

    AURORA☆FIELDS so uh yes Exiled

    Joined:
    Oct 7, 2011
    Messages:
    759
    As you may know by now, while PlanED is useful tool, but it has many flaws, and is unreliable. So, I present you; SoniPlane! This is a plane editor, which is made to be safe to use and user-friendly. This tool is still in early beta and may have fatal bugs. It is recommended to backup any work prior to editing!
    Note: This post is still incomplete and new information may be added at any given time. It is recommended to check from time to time for updates.

    Help wanted

    While working on 

    SoniPlane, and making it more extensive and more compatible for extending it, I ran into some huge bugs, issues, inconsistencies and limitations. Overall, I ran into a point where I figured I should rather than try to work hard and make hacky solutions to hopefully make it work, I decided to rewrite it instead.

    The restart will be on a lot improved engine, OpenGL (to draw everything I want properly and efficiently, avoiding slowdown and annoying bugs like in the earlier versions), using LibGDX and I will finally fix a lot of the annoying bugs, make the code readable, up to the Java standards, compatible, efficient, and make a mod/extension api, to make users able to add their own features they'd like! But, that is an awful lot of work and something I could definitely not make, especially considering I am way more busy than when I started SoniPlane originally, so to try do that all AND make sure it WORKS 100%, would take even up to one YEAR!

    I don't know about you, but that's awfully long and that's exactly the reason why I ask YOU to help make this a thing faster! In other words, I am inviting you to join a core development team to work on SoniPlane and possibly specify in certain areas, such as UI, Graphics, API, core, additional features. Anyone with some expertise with Java is eligible to join the team (except for the graphics people, who need to be able to draw something half-decent), and will have to have something to show they are capable of working on SoniPlane in any form. I will keep the team size at first small, so I have less people to deal with and can coordinate more.

    So, what are my plans? well, I mentioned some stuff earlier, but here is more complete list:
    • Launcher tool that can check everything is correct, see if there is updates, open up a downloader tool if updates are needed, and load SoniPlane itself along with needed mods and extensions and whatnot.
    • API to allow modification of almost anything in SoniPlane, and include most functions the user would need (to minimize need for Java supplied functions, you see why later)
    • Mod Database, so the users can submit their modifications for others to use. Also would need checking to reject mods which use SoniPlane directly or most Java functions (some would need to be allowed, such as String's)
    • Automatic crash reporting (with option to turn off) and troubleshooting guide for common issues.
    • Proper Javadocs, and easily readable online source code(also hopefully an easy way to see what changed since last version)(Github is fine but not optimal for this)
    • Completely rewritten engine and better way of handling [input everything here].
    • Java versions of compressors (gets rid of the need for WINE on Linux and OSX)
    • Cross-platform compatibility.
    • Easy-to-use UI and window handling.
    • Graphics that don't look horrible and/or bland.
    I don't expect to do a release anytime soon, nor would I expect constant work towards SoniPlane, but I aim towards releasing the tool as soon as possible with still keeping quality at the best. If you want to ask me further questions, I am occasionally at IRCirc.badnik.net #ssrg - or just message me here!

    Features & Releases

    Releases

    - Downloader - Download

    ChangeLog
    beta 1.1
    + Windows have borders
    + Windows can be resized and moved
    + Windows can be minimized and maximized
    + cursor images can be customized
    + proper hotkeys for menu functions
    + when project is loaded the taskbar will blink until the app is focused.
    + save states added
    * commandline would not work properly
    * all tiles were not rendered properly
    * now all menu items are grayed out instead of hidden when not used
    * program reset is not CTRL+ESCbeta 1.0.4

    + select multiple tiles

    + added new information to debug screen
    + moving parts of plane with mouse
    + new advanced manager for program parts
    + optimizations
    * not closing when opening a project too quickly
    * made sure SoniPlane not trying to launch when using incorrect directory
    * system information output now outputs Bytes, KiloBytes, MegaBytes and Terabytes depending on the size of each drive/memory unit
    - Menu entries for shifting plane position
    beta 1.0.3

    + SoniPlane now runs under Java 7 instead of Java 8 like before (Convenience for the user)

    * Improved textfields and fixed bunch of bugs
    * Improved file chooser
    beta 1.0.2

    + Redesigned file selection button.

    + Icons for on/off switches.
    + Output of data in SoniPlane folder
    + Program icon
    * Not updating update checker status with very fast internet connection.
    * Hopefully fixed launch path detection
    - Removed "No backups" screen
    beta 1.0.1

    + Added ability to edit or delete projects from the project selection screen

    * update box appearing when not checking for updates
    * debug screens crashing
    * issues caused by editing certain files
    beta 1.0

    + now updates are handled via SoniPlane downloader.

    + the engine is completely rewritten.
    + window is redrawn only when something is changed.
    + automatic update checking.
    + instead of using KensSharp, now SoniPlane uses FW_KENC.
    + Comper support.
    + ugly in-program menus changed to window menus.
    + most things use proper version controllers.
    + compression system overhaul.
    * optimizations, tweaks, etc.
    * a lot of bugs, also some new may be introduced.
    - ability to change framerate - deemed useless due to engine rewrite.

    And whatever else I forgot :I
    beta 0.1.3

    + name field of compression format and mapping, tile, and palette modules are shown instead of filename.

    + implemented feature to remove autosaves after certain amount of space is used.
    + settings menu to easily manage preferences added in beta 0.1.2
    * crash issue on saving art (modules/tile/MD.jar).
    * inability to type space ( ) on textfields.
    * you could only open 1 instance of SoniPlane with run.bat (edited script)
    beta 0.1.2

    + added preferences! It allows you to edit certain aspects of the program.

    + button to reset the program (autosaves, preferences, etc.)
    + ability to use different commandlines per compression format.
    + ability to modify text field styles.
    + changed mappings, art and palette modules to .txt files to describe them and not have multiple files do that.
    * "Exception in thread "LWJGL Application" java.lang.ArithmeticException: / by zero".
    * opening main menu on project load when using commandline.
    * fixed positioning of errors in project creator
    * fixed program title without version number
    * changed loading texts
    beta 0.1.1

    + ability to choose palette line offset

    + commandline support
    + You can now select tile from the plane using O instead of only Middle Click
    * using Numpad on text fields would type "Numpad #" instead of "#"
    * pressing Numpad 9 or Num 9 would not work
    * you cant use colon or semicolon to write said characters
    * if you have less palettes than what plane uses, it will crash (Warning: now it just reads from existing lines!)
    * you are able to edit multiple textfields at once
    * compression format "Uncompressed" fails to automatically exit its command prompt and must be exited manually.
    * The editor itself may not be in a filepath that contains any whitespace characters ( ) due to a bug with commandline. However, edited files can be in any kind of filepath.

    Features
    - Support for "Uncompressed", "Nemesis", "Kosinski", "Enigma", "Comper" and custom compression formats.
    - Supports any MegaDrive games mappings, art, and palette, and can be extended for other systems similar.
    - Lot of options for editing plane mappings easily and efficiently.
    - Palette and tile editor.
    - Project file creator.
    - Autosave and save backup features.
    - High and low plane, tile flip, and palette line support.
    - Any number of palette lines, tiles, and mapping size supported.
    - Ability to customize the program
    - State save/load support

    To Do
    - add/remove/move tiles
    - import/export tiles from image
    - import/export plane from image
    - import/export palette from image
    - add support for multiple palette files

    How to Update SoniPlane

    First, if you don't have it already, download the downloader from this post, and move it to the directory you want to install SoniPlane in. Next, execute it with Java 7 or later. The updater will do everything needed from there. If the application does not start, make sure you have Java 7 installed, 

    Downloader.jar is not renamed and you have working internet connection.
    Media

    nothing here yet :(
    System requirements & Source code & misc notes

    Source code:
    SoniPlane
    Downloader
    Graphics library

    System minimum requirements:

    Operating system:  Windows XP, Windows 7, Linux (Ubuntu 14 tested) (Windows 8, and OS X untested)
    CPU:               ? (Recommended dual core 1GHz or better)
    System memory:     20MB or more
    Hard Drive:        5MB (15MB recommended)
    Java version:      Java 7 or better
    Wine: Needed in Linux and OS X (compressors are not cross-platform)

    Miscellaneous notes:

    If the application does not start normally or crashes, see run.txt for the errors. If the error is not listed as known issue or isnt found in troubleshooting section, nor has anyone reported in this threads replies, you can reply to this topic with everything you know about this issue, as well as short description about your computer (such as Operating System and Java version). You can also contact me via BadnikNet IRC, with the nickname "Natsumi", or write a private message on the forums.
    Tutorials

    Controls
    Text fields
    Text fields have been updated to being controlled by Java default text fields. They should work correctly in any computer with any keyboard style. Only remember all other textfields and controls are blocked while you are editing one. You can press
    Enter to exit a textfield.
    Plane editor

    F1 - reset window positions
    F3 - change debug information mode
    CTRL+ESC - reset preferences and remove autosaves
    CTRL+S - save project
    CTRL+R - reload project
    CTRL+E - edit project configuration
    CTRL+O - go back to main menu
    CTRL+Q - disable/enable draw high plane
    CTRL+W - disable/enable draw low plane
    CTRL+6 - Increase plane width
    CTRL+7 - Decrease plane width
    CTRL+8 - Increase plane height
    CTRL+9 - Decrease plane height
    CTRL+Y - Deselect
    CTRL+L - Clear tiles from selection
    CTRL+I - Remove tiles from selection
    CTRL+K - Insert tiles to selection
    CTRL+O - Fill selection with tile
    CTRL+U - Set selection to high/low plane
    CTRL+G - Flip tiles in selection horizontally
    CTRL+B - Flip tiles in selection vertically
    CTRL+H - Increase palette line in selection
    CTRL+N - Decrease palette line in selection
    CTRL+J - Increase tile index in selection
    CTRL+M - Decrease tile index in selection
    Mouse controls

    Tile Editor:
    Left hold: Draw pixels to tile.
    Right/Middle hold: Select palette offset from pixel.
    Palette Editor: Left/Right hold: Change value
    Palette selector: Left click: Select palette line and offset.
    Tile selector: Left click: Select tile. 
    Plane editor
    Left hold: Place tiles to plane
    Middle click/Key O: Select tile
    Right hold: Select an area
    Control/Shift + right hold: Copy/Move selection (when you let go of Control/Shift, the selection is Copied/Moved)
    Text tutorials

    Creating a new project
    While opening "Create new" from main menu, you can create new projects through there. Whilst it should be pretty self-explanatory, here is the list of data you must fill, and brief explanations (NOTE: This will be changed in near future and this will be obsolete):
    Project file: the file where project is saved to. The file should be on directory "projects" (relative to filepath of SoniPlane).
    Project name: the name given to the project. This will be displayed when opening projects.
    Palette file: direct filepath for the palette file
    Palette type: dropdown menu for available palette decoding modules
    Palette line offset: Offset of palette lines. Can be negative.
    Transparent line: line number for transparent color
    Transparent entry: offset (in current line) for transparent color
    Art file: direct filepath for the art file
    Art type: dropdown menu for available art decoding modules
    Art compression: dropdown menu for available art decompression types
    Mapping file: direct filepath for the mapping file
    Mapping type: dropdown menu for available mapping decoding modules
    Mapping compression: dropdown menu for available mapping decompression types
    Plane width: width of plane mappings (in tiles)
    Plane height: height of plane mappings (in tiles)
    Map offset: addition to tile offset values in decoded mappings (For example, Sonic 1 title screen would have -512)
    Autosave delay (Minutes): How many minutes between autosaving your current progress (0 will disable this feature)

    Project files must be saved to "projects" folder in programs filepath in order to work!

    Project file format:
    (NOTE: This will be changed in near future and this will be obsolete)

    SoniPlaneProject: 1.x: Used to determine this is valid project.
    name: Project display name.
    palette type: Palette module filename (No extension)
    palette file: Direct path to palette file.
    line offset: Offset of palette lines.
    trans line: Line number for transparent color.
    trans off: Offset (in current line) for transparent color
    art file: Direct path to art file.
    art type: Art module filename (No extension)
    art compression: Art compression script filename (No extension)
    map file: Direct path to mappings file.
    map type: Mappings module filename (No extension)
    map compression: Mappings compression script filename (No extension)
    map offset: Offset for tile drawing in plane.
    map width: Plane width in tiles.
    map height: Plane height in tiles.
    autosave: Delay between autosaving in milliseconds.

    If you are still confused with the project format, here is an example project.
    Adding new compression formats

    Due to the design of compression, you can easily add more compression formats, as long as you have application that supports commandline. You may not use batch, however.

    Existing compression formats are stored in application_path/modules/comp/ and new ones must be stored here as well. You can look at other files for example, but here is a short tutorial to it. All compression files must be .txt files! 
    version: Version of this compression format caller. Usually your best bet is to have it be same as with any other of the files.
    name: String to be displayed on project creator.
    compress: Commandline to be executed when attempting to compress existing file. Only called when when cmd field contains %cmd%
    decompress: Commandline to be executed when attempting to decompress existing file. Only called when when cmd field contains %cmd%
    cmd: called when _OS_SPECIFIC.asm has %cmd% in command field.

    There is few rules and special commands to commandline:
    • %CD% can be used to get direct filepath to comp folder (also include extra slash (/))
    • %%I is used to describe where direct path to input file goes. Recommended to enclose in double quotation marks in case of spaces in filepath.
    • %%O is used to describe where direct path to output file goes. Recommended to enclose in double quotation marks in case of spaces in filepath.
    • %copyfile% is used for uncompressed file formats, to simply copy input file to output file location. Cannot be used with any other arguments.
    Launching using commandline

    Since beta 0.1.1, this application has had ability to directly launch parts of the program from commandline arguments. Here is guide how to use them.

    First of all, in order to launch the program to begin with, you must use line similar to this


    Java -jar SoniPlane.jar


    Here is all the commandline arguments available:

    "-new" - Opens project creator
    "-edit <file>" - Opens project editor with specified file
    "-open <file>" - Opens the plane editor with specifier file

    Fail to use commandline properly and the app will boot normally. Here is example with commandline arguments:

    Code:
    Java -jar SoniPlane.jar -open <path>/projects/S1Title.SPP
    
    more coming soon!
    Video tutorials

    coming soon!
    Known issues

    When you use right click -> open with -> Java, the program wont open normally
    Troubleshooting

    "Unsupported major.minor version"
    This is because you are trying to run with older Java version. Make you sure install Java 7 or higher, and if problem persist, you can use run.bat, with replacing "Java" at beginning with this (Replace "jreX" with jre7 or jre8 depending on which version of Java you have installed):
    64-bit Java on 64-bit OS: "C:program FilesJavajreXbinjava.exe"
    32-bit Java on 32-bit OS: "C:program FilesJavajreXbinjava.exe"
    32-bit Java on 64-bit OS: "C:program Files (x86)JavajreXbinjava.exe"
    "My issue is not listed as known issue, nor exists in troubleshooting section and no reply does note about this" - You can reply to this topic with everything you know about this issue, as well as short description about your computer (such as Operating System and Java version). You can also contact me via BadnikNet IRC, with the nickname "Natsumi", or write a private message on the forums.
    Copyright

    This software and all of it's components are lisenced under 

    Open Software License v. 3.0 (OSL-3.0)
    Copyright 2014-2015 Green Snake. Some Rights Reserved.
     
    Last edited by a moderator: Apr 19, 2015
  2. Ashuro

    Ashuro Anti-Cosmic Metal Of Death Member

    Joined:
    Sep 27, 2014
    Messages:
    550
    Location:
    France
    What the fuck? Too hard to make it work.
     
  3. AURORA☆FIELDS

    AURORA☆FIELDS so uh yes Exiled

    Joined:
    Oct 7, 2011
    Messages:
    759
    I am aware of this. I am planning to remake this tool when I have more time.
     
  4. Ashuro

    Ashuro Anti-Cosmic Metal Of Death Member

    Joined:
    Sep 27, 2014
    Messages:
    550
    Location:
    France
    No problem, i'll wait.