Profile image

So Jundroo accidentally added 1 part custom images to the game...

73.7k hpgbproductions  3 months ago

By abusing the "color" tags, I made a program that converts images to a Label. Tested with Beta 1.11.103.0, generated aircraft run on any platform.

Quick Guide

No support for "how to run this", I don't know either

Running the program (release):
1. Go to the Releases page, download the latest version
2. Install .NET Runtime (if you have Visual Studio, you already have this)
3. Unzip the release version into anywhere in your Users folder
4. If it still does not work, you will need Visual Studio 2019 to build the software yourself
5. You can drag images onto text fields (including command prompts) and the file path will be automatically pasted
6. Subassembly XML is placed on the desktop. Move into the SP folder to use it.

Preparing your image:
- Get an image editor like GIMP
- Crop out empty areas and scale down your image
- Run the posterizing or dithering filters to reduce the number of color changes

GitHub repository ~ current: V1.1
- external script using .NET Core 3.1
- can only run on Windows due to the use of System.Drawing.Common.dll
- note that if you have SP on Mac or old version of Android, you can transfer files from PC to your game



A heavily dithered 100x62 picture of a certain comet. Runs well until you try to open the settings. Aircraft (subassembly 66KB)


128x69 USAF marking with a whopping one whole part. The same slow-down level as above, but the settings seem to open quicker. Aircraft (subassembly 42KB, 32KB with V1.1)

Bigger images didn't fare so well, with single-digit FPS and freezing the game when trying to open the settings.
- Try to stick to small images (e.g. 10,000 pixels or less across all your images)
- Use dithering or posterizing filters to reduce color changes
- Lag occurs when looking at the Label, so it's a rendering issue

How it works:
- Use monospace and line height tags with the filled square character
- Color (with transparency) is set for each pixel, unless the previous pixel is the same color
- Writes a subassembly XML file with only the label part. This file is placed on the desktop with the name [image-name].xml

Usage information:
- Do not post exported contents by themselves. They should be well-integrated into your aircraft's design.
- Credit is not required.

Why should you use this?
- Easy to move, rotate, and scale decals
- Label part features
- Replicate complicated images quickly
- Using label "raster graphics" in conjunction with fuselage "vector graphics" will save on pixel count, so you can use them where you need them most.

Why should you NOT use this?
- Low quality (especially when zoomed in)
- Huge performance penalty - 2 tris per character. As a rule of thumb, 50 pixels = 1 part
- Color and image contents cannot be changed
- Simple decals can be done better with just fuselage blocks

Running the program (release):
- install .NET Runtime
- unzip into anywhere in your Users folder

Running the program (source code):
- copy to somewhere in your user folder
- use Visual Studio to build with the SLN file
- as a last resort you can use Visual Studio to make a .NET Core 3.1 console app, copy Program.cs into it, and use the project manager to add System.Drawing.Common.dll

Version history:

1.0 (211008) >

  • Initial release

1.1 (211009) >

  • [Optimization] Transparent pixels are now rendered as horizontal space (except for the rightmost pixel in an image, due to text alignment behavior)
  • [Source code] Character size is no longer "magic" and gets its own constant

(211018) >

  • [Source code] Some directories were removed, to hopefully prevent users installing into a Users folder they don't have

(211027) >

  • [Source code] Test for release as a portable EXE, which won't require Visual Studio to run. You still need the .NET Runtime.

FAQ:

Can this be run on Mac/ Android/ web browsers?
No. However, you may port it to such platforms if you wish.

  • Log in to leave a comment
  • Profile image
    4,021 Micmekox

    It is incredible how people find ways to get things done in this game

    11 hours ago
  • Profile image
    3,812 Tankistrus37

    Is it possible to do on mobile devices?

    4 days ago
  • Profile image
    457 starxiao

    @Amirabadi i just found out myself (if i'm right):
    first open the dotnet.exe using cmd, than type in the program file(Rastermatic.exe) location(or drag it in), hit enter and drag in the image file(for me it only works if you have the img on desktop), hit enter than you should get the .xml file on your desktop.
    and finally..move that .xml file to SP's game folder(usually at C:\Users*yourname*\AppData\LocalLow\Jundroo\SimplePlanes\AircraftDesigns). Open the game and try to open the craft :)

    6 days ago
  • Profile image
    457 starxiao

    I've put the xml file in the "AircraftDesigns", but when loading it in the game it says"There was a error loading the AircraftDesign." and nothing loaded.
    i've tried converting from .bmp .png and 100x100 and 40x40 and black white only pics. (and i'm using .NET 3.1)
    what could be wrong?

    6 days ago
  • Profile image

    @WolfHunter9111 it loaded perfectly for me
    You can't change the size of the label (Label.width and Label.height) after it is generated. Use font size or scale tool to change label size. Use an image editor to remove empty edges.

    7 days ago
  • Profile image

    @hpgbproductions I have tried to put my picture to desktop, and it works well. But all i get was a strange looking stripes. Are the picture with transparent/removed background was unsupported?

    This is what image that i use

    And then this is what i get

    7 days ago
  • Profile image

    @WolfHunter9111 your image path seems to be half combined with another path, C:\Users... appeared twice

    7 days ago
  • Profile image

    @Stinkypinky looks like BMP, GIF, PNG, JPEG, TIFF ( info )
    It also worked with a random ICO file I have lying around

    7 days ago
  • Profile image

    Export failed - an error occured when importing the specified file
    System.IO.FileNotFoundException: C:\Users\ASUS\Downloads\release-1.1\publish\"C:\Users\ASUS\OneDrive\Pictures\Saved Pictures\45b124225b455bd907c1fac788c55ee1.png"
    at System.Drawing.Image.FromFile(String filename, Boolean useEmbeddedColorManagement)
    at Rastermatic.Program.Main(String[] args)
    .

    It doesn't work. What is this even mean?

    7 days ago
  • Profile image
    13.7k Kittyhawk208

    @hpgbproductions You're awsome thankyou!

    umm what kind of image files are compatable?

    7 days ago
  • Profile image

    @Stinkypinky drag the image from the file explorer to the command window

    8 days ago
  • Profile image

    @Upv0te ok, I changed the guide at the top to link to the releases page, so hopefully more people can find it

    8 days ago
  • Profile image
    13.7k Kittyhawk208

    @Upv0te Hey upvote i got the program running but how do i input the file path for the image?

    8 days ago
  • Profile image
    19.1k Upv0te

    @hpgbproductions Oh Geez. I'm sorry. I didn't know that's what to look for on GITHUB. I swear websites like that need a popup which explains how to read and use their website.

    8 days ago
  • Profile image
    8,035 xNotDumb

    @hpgbproductions Bruh, Not aviable for me.

    9 days ago
  • Profile image

    @xNotDumb there is 1.12

    9 days ago
  • Profile image

    @Upv0te ikr (isn't the release version executable)

    9 days ago
  • Profile image
    19.1k Upv0te

    Why can't anyone ever go that extra step and just package something like this into an executable package? 🙄

    9 days ago
  • Profile image
    8,035 xNotDumb

    @hpgbproductions Are new versions aviable?

    10 days ago
  • Profile image

    @xNotDumb it will, but why are you still on 1.11

    10 days ago
  • Profile image
    8,035 xNotDumb

    Hey will it work in beata 1.11.106.0?

    10 days ago
  • Profile image
    13.7k Kittyhawk208

    @AndrewGarrison Oh don't worry. you're mods are gonna have there hands full

    11 days ago
  • Profile image
    13.7k Kittyhawk208

    I'mma let you big guns make roundels and stuff and download/save as they become available

    11 days ago
  • Profile image
    2,210 TailessAce

    @hpgbproductions Hey, is it alright if you could show us how the program works so we could use decals on our builds? Or could you make a certain image to be a decal. It's our company logo/coat of arms. Would credit if you like

    12 days ago
  • Profile image
    3,919 Erc90F4RU

    how run it?

    13 days ago
  • Log in to see more comments