Roblox Central

Would you like to react to this message? Create an account in a few clicks or log in to continue.
Roblox Central

Discussion for all things Roblox. (roblox.com)

Welcome to the new forum! Any suggestions you have are greatly appreciated.
WARNING: Before referring anyone to this website, Please read this topic

3 posters

    EquipItem()

    iMathRandom
    iMathRandom
    Mod


    Posts : 66
    Join date : 2009-06-21
    Location : Ohio

    EquipItem() Empty EquipItem()

    Post by iMathRandom Sun Oct 11, 2009 2:35 pm

    I was going through xLEG0x's RPG and seen him using this function. Is that really a function?
    avatar
    Jfeather
    Admin


    Posts : 232
    Join date : 2009-06-18
    Location : This Forum. Duh.

    EquipItem() Empty Re: EquipItem()

    Post by Jfeather Sun Oct 11, 2009 6:53 pm

    If he has earlier in the script the code

    Code:


    fuction EquipItem()

    --Codehere--

    end



    Then yes, it could be Wink
    Earth
    Earth
    Admin


    Posts : 402
    Join date : 2009-06-18
    Location : According to my IP address: Topeka, Kansas.

    EquipItem() Empty Re: EquipItem()

    Post by Earth Sun Oct 11, 2009 7:10 pm

    Its probably an _G function Wink
    iMathRandom
    iMathRandom
    Mod


    Posts : 66
    Join date : 2009-06-21
    Location : Ohio

    EquipItem() Empty Re: EquipItem()

    Post by iMathRandom Mon Oct 12, 2009 2:49 pm

    Found it;


    _G.equipItem = function(hn)
    local p = hn.Parent.Parent
    local v = hn.Parent.Hand.Value
    local a = hn
    if v then a = p["Right Arm"] else a = p["Left Arm"] end
    local w = Instance.new("Weld")
    if v then w.Name = "rightgrip" else w.Name = "leftgrip" end
    w.Parent, w.Part0 = a, a
    w.C0 = CFrame.new(0, -1, 0)
    w.Part1 = hn
    return w
    end
    Earth
    Earth
    Admin


    Posts : 402
    Join date : 2009-06-18
    Location : According to my IP address: Topeka, Kansas.

    EquipItem() Empty Re: EquipItem()

    Post by Earth Mon Oct 12, 2009 2:58 pm

    Yup. _G is finicky though.

    Sponsored content


    EquipItem() Empty Re: EquipItem()

    Post by Sponsored content


      Current date/time is Thu May 09, 2024 6:54 am