BeamNG Lua

Discussion in 'Programming' started by bigcrazycarboy, Jun 21, 2015.

  1. bigcrazycarboy

    bigcrazycarboy
    Expand Collapse

    Joined:
    May 11, 2015
    Messages:
    78
    Hey guys, I have a question. I know and understand Lua pretty well now (at least the Lua used in ROBLOX) and it seems like when I transfer to BeamNG Lua, it is a whole new language. I just figured you could go script.Parent and that would be the folder the Lua file is in, but it seems like it's not. Anybody mind explaining what is going on?:confused:
     
  2. StinchinStein

    StinchinStein
    Expand Collapse

    Joined:
    Jul 16, 2014
    Messages:
    754
    Lua is lua.. Roblox lua is the same as BeamNG lua. How is it different in your case?
     
  3. bigcrazycarboy

    bigcrazycarboy
    Expand Collapse

    Joined:
    May 11, 2015
    Messages:
    78
    ROBLOX Lua operates in a single workspace, rather than in different folders around your computer. in ROBLOX, it is like writing a script in the World Editor of BeamNG, just locating different things in the tree. (i,e. you could say script.Parent.Part.CanCollide = false)
     
  4. StinchinStein

    StinchinStein
    Expand Collapse

    Joined:
    Jul 16, 2014
    Messages:
    754

    Okay so, what's the problem here then? Not being able to access other files from the main file?
     
  5. bigcrazycarboy

    bigcrazycarboy
    Expand Collapse

    Joined:
    May 11, 2015
    Messages:
    78
    Pretty much, yes. I don't know how to
    make my own values and have the functions happen.
     
  6. tdev

    tdev
    Expand Collapse
    Developer
    BeamNG Team

    Joined:
    Aug 3, 2012
    Messages:
    3,031
    You can do that in beamng as well: scenetree.<object>.property = 123

    What you are speaking about is how the API looks like to the game. This is very different. The underlying language (Lua) is the same :)
     
    #6 tdev, Jun 21, 2015
    Last edited: Jun 21, 2015
  7. bigcrazycarboy

    bigcrazycarboy
    Expand Collapse

    Joined:
    May 11, 2015
    Messages:
    78
    Oh
     
  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice