Newb Scripting Question

KalinaarKalinaar Member Posts: 152 ✭✭✭
I'm trying to learn how to write my own scripts and I'm using scripts written in source to understand how they work. I understand a lot of the concepts of if/then/else and such but where I'm getting hung up is, I don't know what these sort of things are ps.defs.active.mounted, ps.vitals.stance, pvp.affs.leftlegbroken, ps.limiters.offense etc. What are these called? Is there a list somewhere for all of the possible options I could use and what they mean?

Comments

  • LeanaLeana Member Posts: 225 ✭✭✭
    Kalinaar said:

    I'm trying to learn how to write my own scripts and I'm using scripts written in source to understand how they work. I understand a lot of the concepts of if/then/else and such but where I'm getting hung up is, I don't know what these sort of things are ps.defs.active.mounted, ps.vitals.stance, pvp.affs.leftlegbroken, ps.limiters.offense etc. What are these called? Is there a list somewhere for all of the possible options I could use and what they mean?

    So all the things you listed are Variables. They can store information or functions. In short, the 'ps' is the catch-all for all Source variables (Project Source). 'pvp' is where the tracker stores affliction information. 'ps.limiters.offense' is so you don't spam your offense 100000000 times before it makes it to the mud and lags you out. You will use them all in scripting with Source, but the first step is to study Lua code. Lua code is the backbone of Mudlet coding.

    There are a number of free guides to help get you the basics:

    A quick overview:
    Lua CRASH COURSE

    More detailed education:
    Lua.org official website

    Most importantly:
    Mudlet Manual
    This is where all the built in functions come from.

    Review these a bit and the system will make more sense. You'll still need help, but you'll be able to ask the right questions (you can still ask questions about all this Lua stuff).



    Aloli
  • EliadonEliadon Somewhere Over the RainbowMember Posts: 177 ✭✭✭
    edited April 2018
    Also, if you're on any of the Discords, I often help people with coding stuff. Ingame is a little more fiddly, because pasting code, but I'm good for that too usually :P

    ^ She knows a lot more about Source than I do though, I never used it.
    LeanaAloli
Sign In or Register to comment.