Results 1 to 7 of 7
  1. #1
    Master Sergeant brayden's Avatar
    Reputation
    11
    Join Date
    Apr 2008
    Location
    Maybe behind you....
    Posts
    99
    Thanks (Given)
    0
    Thanks (Received)
    0
    CoreCoins
    0
    Trade Feedback
    0 (0%)

    [Lua] How to write notes to yourself

    Hello, mmowned.
    This guide is going to teach you how to make a note to yourself inside your LUA script.

    What do I want to have for this guide? (I say want because they're not required but LUA is way easier with them).

    - First you will need a LUA engine. I recommend Notepad++ which you can get here.


    _________________________________________________________________
    Now lets get started. Before we start I am going to tell you that if you go down to the end of this post and copy/paste the script into your scripts folder you will learn noting!

    Allright so first I am going to teach you how to write notes for yourself inside the script.

    1. If your note can be inserted within one line then you simply would do this.

    _________________________________________________________________

    -- "Your note here"

    _________________________________________________________________

    Except without the quotes ofcourse.

    2. If your note cannot be inserted within 1 line then you will do this.

    _________________________________________________________________

    --[[
    "Your text here"
    ]]

    _________________________________________________________________

    And, once again don't forget to remove the qoutes.

    There you go; you have created your note you may not think it now but these can be very useful when you go to script. If you can't remember what the script does then what is the point of it right?

  2. #2
    Elite drone Trollblod's Avatar
    Reputation
    442
    Join Date
    May 2009
    Location
    REBORN!
    Posts
    1,707
    Thanks (Given)
    2
    Thanks (Received)
    5
    CoreCoins
    127
    Trade Feedback
    1 (100%)
    Pretty sure this belong to the Programming -> misc section. Misc - MMOwned - World of Warcraft Exploits, Hacks, Bots and Guides


  3. #3
    Master Sergeant brayden's Avatar
    Reputation
    11
    Join Date
    Apr 2008
    Location
    Maybe behind you....
    Posts
    99
    Thanks (Given)
    0
    Thanks (Received)
    0
    CoreCoins
    0
    Trade Feedback
    0 (0%)
    Quote Originally Posted by Vinland View Post
    Pretty sure this belong to the Programming -> misc section. Misc - MMOwned - World of Warcraft Exploits, Hacks, Bots and Guides
    It is a guide for writing notes to yourself in LUA scripts... which is emulation.

    It is not an exploit, hack, bot, or guide so I do not understand why you think it would belong in that section.

  4. #4
    Contributor Sounddead's Avatar
    Reputation
    160
    Join Date
    Sep 2007
    Location
    Canada
    Posts
    1,126
    Thanks (Given)
    0
    Thanks (Received)
    0
    CoreCoins
    1
    Trade Feedback
    0 (0%)
    Vinland is right, because its really not about emulation. Lua is used as a programming language a lot more places than in WoW Emu, and learning how to write a comment really is only related to the language.

    I live in a shoe

  5. #5
    ★ Elder ★ CoreCoins User Ground Zero's Avatar
    Reputation
    1132
    Join Date
    Aug 2008
    Location
    Great Britain
    Posts
    3,505
    Thanks (Given)
    0
    Thanks (Received)
    0
    CoreCoins
    37559
    Trade Feedback
    0 (0%)
    Quote Originally Posted by brayden View Post
    It is a guide for writing notes to yourself in LUA scripts... which is emulation.

    It is not an exploit, hack, bot, or guide so I do not understand why you think it would belong in that section.

    And Exploits, Hacks, bots and Guides is the subtitle of our Forum if you havn't noticed, thats why its in the name.

  6. #6
    Panda of Worlds The Idiot

    CoreCoins User Confucius's Avatar
    Reputation
    1220
    Join Date
    Oct 2007
    Location
    Panda Land
    Posts
    2,454
    Thanks (Given)
    202
    Thanks (Received)
    194
    CoreCoins
    31653
    Trade Feedback
    5 (100%)
    err you missed one that although it's the same as -- it's useful to use to show the output of something, that is
    -->
    for example:
    i = 1224
    print(i) --> 1224

    As you can see that clearly shows what the output will be

    Edit: Just in case you don't see the use in this, this could be helpful in helping people who don't know Lua understand your script or when in writing a guide for example it is helpful when explaining how you can assign a value to any variable with the '=' sign.

    Code:
    print(MyVariable) --> nil (this variable doesn't exist yet, hehehe)
    
    MyVariable = 5 -- we add a value to it here
    
    print(MyVariable) --> 5 (because we gave it that value above...)
    
    MyVariable = "Hello MMOwned!"
    
    print(MyVariable) --> Hello MMOwned! (Variable's values can change ;)
    Last edited by Confucius; 01-12-2010 at 07:05 PM.

  7. #7
    Master Sergeant Mildan's Avatar
    Reputation
    10
    Join Date
    Feb 2009
    Posts
    80
    Thanks (Given)
    0
    Thanks (Received)
    0
    CoreCoins
    0
    Trade Feedback
    0 (0%)
    To be honost it doesnt matter if you delete the quotes or not, everything after the -- is ignored in the script. So when you read the LUA file afterwards, it really doesnt matter if you have quotes in the text or not.

 

 
All times are GMT -5. The time now is 10:36 PM. Powered by vBulletin® Version 4.2.2
Copyright © 2016 vBulletin Solutions, Inc. All rights reserved. Digital Point modules: Sphinx-based search