lua scripts, end or end; ? menu

User Tag List

Results 1 to 2 of 2
  1. #1
    dklfcheat's Avatar Member
    Reputation
    1
    Join Date
    Sep 2016
    Posts
    18
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    lua scripts, end or end; ?

    when using scripts like:

    /run if IsUsableSpell("Blood strike") and IsSpellInRange("blood strike", "target")==1 then CastSpellByName("Blood strike") end
    /run if IsUsableSpell("Blood strike") and IsSpellInRange("blood strike", "target")==1 then CastSpellByName("Blood strike") end

    are we supposed to actually put ; at the end except for the last one or what, whats the logic or explanation behind this, im just looking to make my scripts better

    /run if IsUsableSpell("Blood strike") and IsSpellInRange("blood strike", "target")==1 then CastSpellByName("Blood strike") end;
    /run if IsUsableSpell("Blood strike") and IsSpellInRange("blood strike", "target")==1 then CastSpellByName("Blood strike") end

    i also seen scripts end with more than one "end" like:

    /run if IsUsableSpell("Blood strike") and IsSpellInRange("blood strike", "target")==1 then CastSpellByName("Blood strike") end end

    lua scripts, end or end; ?
  2. #2
    Hazzbazzy's Avatar wannabe hackerlol Authenticator enabled
    Reputation
    1335
    Join Date
    Aug 2011
    Posts
    1,206
    Thanks G/R
    243/484
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    You use the semi colon to highlight that you're doing more than one thing in a single line

    See Lua 5.2 Reference Manual

    Section - 3.3.1 – Blocks
    "HOLY TIME MACHINE BATMAN! it's 1973!"
    https://youtube.com/Hazzbazzy

Similar Threads

  1. [Guide] Lua Scripting Guide is here [Updating]
    By Illidan1 in forum WoW EMU Guides & Tutorials
    Replies: 93
    Last Post: 11-04-2008, 06:56 PM
  2. [HELP] Ending a lua script
    By Ezikielth in forum World of Warcraft Emulator Servers
    Replies: 1
    Last Post: 07-28-2008, 11:01 AM
  3. Lua Scripts!
    By danis in forum World of Warcraft Emulator Servers
    Replies: 3
    Last Post: 12-15-2007, 03:16 PM
  4. How To LUA Script
    By Skuxta in forum WoW EMU Guides & Tutorials
    Replies: 1
    Last Post: 12-13-2007, 04:24 AM
  5. New LUA Scripts
    By 777devil777 in forum World of Warcraft Emulator Servers
    Replies: 8
    Last Post: 11-26-2007, 05:58 PM
All times are GMT -5. The time now is 04:27 PM. Powered by vBulletin® Version 4.2.3
Copyright © 2024 vBulletin Solutions, Inc. All rights reserved. User Alert System provided by Advanced User Tagging (Pro) - vBulletin Mods & Addons Copyright © 2024 DragonByte Technologies Ltd.
Digital Point modules: Sphinx-based search