YouTube Tutorials

Hi guys! I've started a new YouTube channel and have dedicated a playlist to learning/sharing Scripting tutorials.
I've started with (Lua) Mudlet and would like to eventually branch off into other Clients like (JavaScript) Nexus.

The reason why I've started doing these videos is that I figure the fastest way for me to learn and grow, personally, is by putting them out there for you guys to watch. 
I have no coding background, and everything I've learned about scripting has been from you guys. And of course trial and error. :D
I know that by doing this, since we have such a brilliant community, you guys will be able to quickly point out any mistakes or even better ways of doing things.
I have no problem editing/re-uploading videos as long as I'm not putting out misinformation.
That's really all I hope this will be. A place to come to learn scripting in layman's terms.

If you have any tutorial videos, or videos that relate, please share them here!


Have fun and start learning!


Comments

  • KlendathuKlendathu Eye of the Storm
    myToggle = not myToggle



    Tharos, the Announcer of Delos shouts, "It's near the end of the egghunt and I still haven't figured out how to pronounce Clean-dat-hoo."
  • edited April 2016
    Wow! That really simplified the code. I almost feel like a dumb-dumb for posting the video, but I wouldn't have learned otherwise! Thank you.

    How would I use cecho with this simplified version?
  • A quick tutorial to show you how to download and install Reflex Packages within the Nexus Achaea Client. Enjoy!


  • KlendathuKlendathu Eye of the Storm
    Jian said:
    Wow! That really simplified the code. I almost feel like a dumb-dumb for posting the video, but I wouldn't have learned otherwise! Thank you.

    How would I use cecho with this simplified version?
    Sadly, you'll still need to use if myToggle, unless you used the toggling to raise an event, then had an event handler to do the cecho... but then you're starting to get a lot more advanced, and it's probably not worth the effort for such a trivial routine :)

    Your code:
    if myToggle then
      myToggle = false
      cecho("<red>Toggle is off")
    else
      myToggle = true
      cecho("<green>Hey, it works")
    end


    New code:
    myToggle = not myToggle
    if myToggle then
      cecho("<red>Toggle is off")
    else
      cecho("<green>Hey, it works")
    end

    So in this example, you'd save precisely one line of code!

    Tharos, the Announcer of Delos shouts, "It's near the end of the egghunt and I still haven't figured out how to pronounce Clean-dat-hoo."
  • edited April 2016
    Well, if all you wanted to do is save some lines, you could technically do:

    myToggle = not myToggle
    cecho(myToggle and "<green>Hey, it works" or "<red>Toggle is off")


    The question is just, as always in such cases: does compressing the code like this harm readability, and if so, is it worth it? In a tutorial, I'd certainly go with the more verbose, but simpler form.
Sign In or Register to comment.