[MOD EXT] Empyrion Scripting - Scripts

Discussion in 'The Hangar Bay' started by Ephoie, Mar 22, 2020.

  1. ASTIC

    ASTIC Rear Admiral

    Joined:
    Dec 11, 2016
    Messages:
    1,105
    Likes Received:
    736
    NPP habe no default moustache/handlebars syntaxhighlight but VisualStudioCode

    [​IMG]
     
    #961
    TOFFEL likes this.
  2. BloodAngel099

    BloodAngel099 Lieutenant

    Joined:
    Jan 24, 2023
    Messages:
    41
    Likes Received:
    2
    Is it possible for an inventory management script to delete items? I was setting up some inventory management scripts on a new ship and now a bunch of my constructor input box items are missing.....
     
    #962
  3. ASTIC

    ASTIC Rear Admiral

    Joined:
    Dec 11, 2016
    Messages:
    1,105
    Likes Received:
    736
    There are several fallback backups in case the transaction of items did not work out. However, if a playfield change occurs in between, even these may no longer work. But I haven't heard anything like that so far. As a rule, the script creators have made a mistake so that other containers may even have received the items on other structures.
     
    #963
  4. BloodAngel099

    BloodAngel099 Lieutenant

    Joined:
    Jan 24, 2023
    Messages:
    41
    Likes Received:
    2
    I have all the container names setup up right and each ship get a unique 3 digit code with anything script related so that it doesnt even look at other containers. I had a backup I was able to roll back to get most of my stuff back.

    I am used to using this in single player, but didnt opening a container lock it so that scripts couldn't use it even on servers? I find my inventory sorting gives me lots of lag when im trying to open containers while its working. It used to lock the container which seemed to stop scripts from using it.
     
    #964
  5. ASTIC

    ASTIC Rear Admiral

    Joined:
    Dec 11, 2016
    Messages:
    1,105
    Likes Received:
    736
    The API functions are unfortunately not very good in single player mode. If your computer is powerful enough, it is better to run a local dedicated server and install the mods there. But of course you always have the possibility to unlock the “h” function via console command “im” to get lost things back.
     
    #965
  6. BloodAngel099

    BloodAngel099 Lieutenant

    Joined:
    Jan 24, 2023
    Messages:
    41
    Likes Received:
    2
    I am running it on a dedicated server now. Got tired of the scripts stopping when changing playfields. Is there a way to revert the mod so that scripts wont affect containers that players are in?
     
    #966
  7. ASTIC

    ASTIC Rear Admiral

    Joined:
    Dec 11, 2016
    Messages:
    1,105
    Likes Received:
    736
    The mod checks whether a container is in use and then does not access it
     
    #967
  8. BloodAngel099

    BloodAngel099 Lieutenant

    Joined:
    Jan 24, 2023
    Messages:
    41
    Likes Received:
    2
    Something is wrong then. For weeks now (maybe longer, my ability to play hasn't been consistent for awhile) I can be inside of a container and watch as inventory scripts are taking items out/putting them in. It didnt used to do this. I have hated it because it causes a lot of lag when it happens.
     
    #968
  9. ASTIC

    ASTIC Rear Admiral

    Joined:
    Dec 11, 2016
    Messages:
    1,105
    Likes Received:
    736
    Or do you (still) have the mod installed in both SP and dedicated server, then you MUST delete it in SP
     
    #969
  10. BloodAngel099

    BloodAngel099 Lieutenant

    Joined:
    Jan 24, 2023
    Messages:
    41
    Likes Received:
    2
    That seems to have fixed it, thank you. Didnt realize the game loaded mods like that. Good to know.
     
    #970
  11. ASTIC

    ASTIC Rear Admiral

    Joined:
    Dec 11, 2016
    Messages:
    1,105
    Likes Received:
    736
    This wasn't the case in the past either, as the game deactivated the local mods when EAC was activated with a server.
    But for some time now the game simply loads all mods and executes them :-(
     
    #971
  12. BloodAngel099

    BloodAngel099 Lieutenant

    Joined:
    Jan 24, 2023
    Messages:
    41
    Likes Received:
    2
    Oh, gotcha. I thought I remembered not having to do that before, but just figured I must have been remembers wrong. lol Thank you again!
     
    #972
  13. TOFFEL

    TOFFEL Ensign

    Joined:
    Oct 13, 2023
    Messages:
    11
    Likes Received:
    0
    Hi Astic,
    whats the meaning of "#" in front of a command
    {{#setcacheblock ...
    {{setcacheblock ...

    Both work to my surprise :)
     
    #973
  14. ASTIC

    ASTIC Rear Admiral

    Joined:
    Dec 11, 2016
    Messages:
    1,105
    Likes Received:
    736
    {{#abc }} is a block that ends with {{/abc}}
     
    #974
  15. TOFFEL

    TOFFEL Ensign

    Joined:
    Oct 13, 2023
    Messages:
    11
    Likes Received:
    0
    Sorry, still don't understand why both work? Another example:
    {{#test ...
    {{test ...
     
    #975
  16. BloodAngel099

    BloodAngel099 Lieutenant

    Joined:
    Jan 24, 2023
    Messages:
    41
    Likes Received:
    2
    Astic, is there a command that will show what scripts are currently being executes, or list active scripts that are in que? Essentially anything that could be turned into a readout for what the mod is doing?
     
    #976
  17. ASTIC

    ASTIC Rear Admiral

    Joined:
    Dec 11, 2016
    Messages:
    1,105
    Likes Received:
    736
    Look at the demo CV there is an LCD in the back that shows this
     
    #977

Share This Page