[Tool] EmpyrionStuff - EPB read/write

Discussion in 'The Hangar Bay' started by Apan Loon, Jun 7, 2018.

  1. Myrmidon

    Myrmidon Rear Admiral

    Joined:
    Mar 26, 2016
    Messages:
    1,729
    Likes Received:
    2,058
    My imagination tells me that it would be great if both your tools could somehow be combined. A tool to copy/transfer vessels from one save game ton another with the ability to show them visually.
     
    #101
    byo13 likes this.
  2. Apan Loon

    Apan Loon Lieutenant

    Joined:
    Jun 7, 2018
    Messages:
    91
    Likes Received:
    52
    Thanks. I forgot to update the specification. The new floats for “Attack” and “Defence” are just before the device groups. The best way to be sure that you are updated is to check the BinaryReader extension class source code in EPBLib.
     
    #102
    byo13 likes this.
  3. byo13

    byo13 Captain

    Joined:
    Jul 13, 2020
    Messages:
    415
    Likes Received:
    638
    Yes, BinaryReader was very helpful to understand.
    I have a similar process of approaching binary files. Thanks!

    I'm very interested in understanding the source code of how he renders all of that information.
    Clearly a lot of work was invested on it.
     
    #103
  4. Myrmidon

    Myrmidon Rear Admiral

    Joined:
    Mar 26, 2016
    Messages:
    1,729
    Likes Received:
    2,058
    I have a question. How may I be able to run for example EPBLab on linux (debian)?
     
    #104
  5. Apan Loon

    Apan Loon Lieutenant

    Joined:
    Jun 7, 2018
    Messages:
    91
    Likes Received:
    52
    I don't know if you can. This application is built on .Net Framework 4.6.1 and relies on Windows Presentation Foundation (WPF). As far as I know, WPF was not included in Mono for linux or Mac. Even if I were to update the project to .Net Core 3.1 or .Net Framework 5.0 I am still not sure about the portability of WPF. For the 3D view, this application also uses System.Windows.Media.Media3D and I don't know if that is portable either.

    EPBLib, on the other hand should be usable with little to no modifications.

    Edit: I suppose that you should be able to run it under one of the various Windows emulator thingies...
     
    #105
  6. Myrmidon

    Myrmidon Rear Admiral

    Joined:
    Mar 26, 2016
    Messages:
    1,729
    Likes Received:
    2,058
    Thank you for the reply. I tried to run it with Proton to no avail.
     
    #106
  7. Apan Loon

    Apan Loon Lieutenant

    Joined:
    Jun 7, 2018
    Messages:
    91
    Likes Received:
    52
    Media3D is part of the .Net Framework and it provides a simple 3D rendering engine. This version of it, however, isn’t were well integrated with WPF. This means that the dynamic binding between the 3D data and the view isn’t very efficient. Large blueprints are likely to crash the program.

    As for the block models themselves, I do not draw them the way the game does. The game engine cleverly figures out what sides of the block to draw based on what blocks are next to them. This makes the rendering more efficient.

    My use of the Media3D engine simply renders complete blocks that I crudely modelled in my 3D modelling software of choice, Realsoft3D, exported to an ASCII OBJ file and ran a script on. The script generates C# source code that sets up the vertices and triangles of the meshes. This generated source file is huge and makes the project take a long time to render. Some day I might make the code read in the OBJ file directly - if I can figure out a good way of doing that.
     
    #107
    byo13 likes this.
  8. byo13

    byo13 Captain

    Joined:
    Jul 13, 2020
    Messages:
    415
    Likes Received:
    638
    #108
  9. Sup

    Sup Ensign

    Joined:
    Aug 26, 2020
    Messages:
    9
    Likes Received:
    5
    Have you tried using WINE? I can run most applications with that.
     
    #109
  10. Myrmidon

    Myrmidon Rear Admiral

    Joined:
    Mar 26, 2016
    Messages:
    1,729
    Likes Received:
    2,058

    I have tried Proton, the most 3 latests versions, as well as the custom GE. It will not run. Proton is based on WINE. Should I try using WINE? Should I try using steam through Lutris that uses WINE and install EPBLab in as non steam game?
     
    #110
  11. Sup

    Sup Ensign

    Joined:
    Aug 26, 2020
    Messages:
    9
    Likes Received:
    5
    Out of curiosity I just tried starting the tool on my GNU/Linux laptop (running Ubuntu 20.10).

    I have installed the following packages with apt:
    -wine 5.0
    -winetricks (because I'm lazy)
    (not sure if necessary:
    -libntlm0
    -winbind
    )

    In winetricks / wine, install in your prefix:
    -Latest .NET runtime (4.8)
    -vcredist_2019 (I had to install it manually due to a possible bug in winetricks)
    -d3dcompiler_47

    I then ran "EPBLab.exe" and it has worked. I haven't thoroughly tested it, but I could create a new blueprint and have created a pyramid (see attached screenshot).

    Bildschirmfoto von 2020-12-25 21-15-00.png
     
    #111
    Apan Loon and Myrmidon like this.
  12. Myrmidon

    Myrmidon Rear Admiral

    Joined:
    Mar 26, 2016
    Messages:
    1,729
    Likes Received:
    2,058


    Congratulations. Seems it does work. It's been over a year since I last worked winetricks. I remember Empyrion's prefix was/is 383120. What is the prefix for EPB read/write? Or am I forgetting something? :oops:
     
    #112
  13. Sup

    Sup Ensign

    Joined:
    Aug 26, 2020
    Messages:
    9
    Likes Received:
    5
    You mean the Steam ID, but in WINE context the prefix is simply the "environment" you are using. Empyrion itself is not involved in any way.

    And I just remembered that I forgot one important fact in my notes: you'll have to set WINE to win32bit (i. e. "export WINEARCH=win32") - it hasn't worked for me with 64bit.
     
    #113
    Myrmidon likes this.
  14. Myrmidon

    Myrmidon Rear Admiral

    Joined:
    Mar 26, 2016
    Messages:
    1,729
    Likes Received:
    2,058
    Thank you for the information. I did not know that. So after all this, all you have to do is point EPB to the proper folder to load/save blueprints.

    Good show ;)
     
    #114
    Sup likes this.
  15. Apan Loon

    Apan Loon Lieutenant

    Joined:
    Jun 7, 2018
    Messages:
    91
    Likes Received:
    52
    Awesome! Thanks for figuring this out.

    I don't know why my project is set for 32 bit. However, I would prefer porting it to a newer .Net framework before trying to fiddle with that. Unfortunately I am too busy with another project... (Not Empyrion-related)
     
    #115
    Sup likes this.
  16. johnwhile

    johnwhile Ensign

    Joined:
    Feb 27, 2021
    Messages:
    10
    Likes Received:
    12
    Hi, I completely read the EPB file while making my tool:
    Tell me if you want the source code or the 010Editor template about epb format.
     
    #116
    Sup, jmcburn, Myrmidon and 2 others like this.
  17. linskyter

    linskyter Ensign

    Joined:
    Nov 30, 2022
    Messages:
    1
    Likes Received:
    0
    I believe this the main thread discussing about
    EmpyrionStuff
    I have fix the current bug and forked updating on my github.
    Though git is not my familier revision tool, I update it in a very rough way.

    The link, please enjoy it.
    https://github.com/skyter/EmpyrionStuff
     
    #117
  18. Lanthanum

    Lanthanum Ensign

    Joined:
    Nov 2, 2017
    Messages:
    12
    Likes Received:
    1
    cool! epb.exe works, but EpbLab Crashes when I try to load or create a new epb.
     
    #118

Share This Page