Questions about Advanced ConsoleCommands

  • L974
    22nd Sep 2016 Member 0 Permalink

    Hi!

     

    I enjoy experimenting with TPT  A LOT. It is really great but I ran into a problem when I tried to change some elements in the console.

     

    I can't seem to find any information on how to change the hightemperature in the console exactly.

     

    I tried this: "tpt.el.ignc.hightemperature = 1000.0"

     

    result in "console:1: Invalid property"

     

     

    What am I doing wrong ?

     

    Is there any documentation on ALL console commands? (also the advanced ones)

  • Emperor_Bowserinator
    22nd Sep 2016 Member 0 Permalink

    The "advanced" ones are LUA commands

    And the wiki has a list of some of them: https://powdertoy.co.uk/Wiki/W/Powder_Toy_Lua_API.html (Elements > elements.element)

     

    Also it's tpt.el.ignc.hightemperaturetransition (I think)

    Edited once by Emperor_Bowserinator. Last: 22nd Sep 2016
  • L974
    23rd Sep 2016 Member 0 Permalink

    @Emperor_Bowserinator (View Post)

     

    The information in the links is completely useless for the console since the commands don't work.

     

    "Also it's tpt.el.ignc.hightemperaturetransition (I think)".....Nope not working either

  • jacob1
    23rd Sep 2016 Developer 0 Permalink
    Copying this from another script, using the new API the method is:

    elements.property(elements.JWARD_PT_PTRL, "HighTemperature", 333.15)
    elements.property(elements.JWARD_PT_PTRL, "HighTemperatureTransition", elements.JWARD_PT_PTLV)

    This would make PTRL turn into PTLV at 333.15K (60C)

    There is some documentation on all of the properties you can set here: https://powdertoy.co.uk/Wiki/W/Element_Properties.html
    Info on all of the Lua API functions is here: https://powdertoy.co.uk/Wiki/W/Powder_Toy_Lua_API.html

    tpt.el.* has almost no documentation anywhere. The Element_Properties page I linked should be enough though, that documents how to use the replacement. I did just look up how the old api works though, you probably want tpt.eltransition.ignc.tempHighValue and tpt.eltransition.ignc.tempHighType
    Edited once by jacob1. Last: 23rd Sep 2016
  • L974
    23rd Sep 2016 Member 0 Permalink

    @jacob1 (View Post)

     

    I got it to work!

    Thanks A LOT!

     

    TPT is very cool. One of the best simulations on the internet(I have tried many)

     

     

    _______________________________________________

    I made my first element script. It is basically compacted gunpowder (slower burning) that can be used for firework rocket engines. Works well.

     

    The Script Manager is REALLY helpful btw! (Should be added to TPT I think)

    Edited once by L974. Last: 23rd Sep 2016