of     1   

UPumpkin
#185617043Saturday, March 19, 2016 2:53 AM GMT

How would I make it so if they have a certain leader stat for example. Class > 199. They'd start with a sword. And if they ever went under they'd lose the sword. But anything over class 200 they would keep it.
Unintelligent_Anon
#185619268Saturday, March 19, 2016 3:34 AM GMT

Hello, UPumpkin. Certainly, you will need an algorithm that can adequately access stored information about a given Player upon event-signalling. Afterwards, it is a matter of utilizing a conditional "if" statement to compare the quantities. I have devised a custom-notation example to attempt to help you(Note that this is quite different from the syntax used in Lua, as it is only an example expression): Sword = Object_Space["Sword"]; sub Check_Class(Player){ if(Player["Class"] >= 199){ Sword.Location = Player["Item_Storage"]; elseif(Player["Class"] < 199 & Player["Item_Storage"][Sword.Name] !== nil){ Player["Item_Storage"][Sword.Name] = nil; } } } Event_Space.Event:connect(Check_Class); Although the above is somewhat different from a typical Lua example, it seems sufficient to explain the process. A function known as "Check_Class" is created, with a parameter referring to the actual Player being modified(This assumes that the event signalling the function's execution will provide a reference to the Player object). Presumably, our Player object is a data structure containing a key known as "Class." The "Class" key allows is refer to the numerical quantity that we would like to compare to the maximum quantity, 199. Our specified "elseif" condition ensures that if the Class quantity is lesser than 199 whenever the event signals our function's execution, that the sword is properly removed. The "["Item_Storage"][Sword.Name] !== nil" segment ensures that an actual Sword object exists within the specified location. Regarding a concrete "Lua" example, these links may help you: http://wiki.roblox.com/index.php?title=Function http://wiki.roblox.com/index.php?title=Table http://wiki.roblox.com/index.php?title=Conditional_statement Although it is somewhat different from what you may have expected, I am hoping that this suggestion is useful for what you intend to accomplish. Goodbye.
unroot
#185619502Saturday, March 19, 2016 3:38 AM GMT

You're making your posts way too long for something so simple. #code print("yolo" .. string.rep("o", math.huge))
Unintelligent_Anon
#185619703Saturday, March 19, 2016 3:41 AM GMT

"You're making your posts way too long for something so simple" I suppose that this is an accurate statement. Extending the concept slightly was actually somewhat amusing.
UPumpkin
#185927005Thursday, March 24, 2016 12:43 AM GMT

Bumpppppppp
InfiniteYield
#185931438Thursday, March 24, 2016 1:45 AM GMT

if some.path < 200 then something = something.path:findFirstChild("somethinghere") something:Destroy() elseif some.path > 200 nil end end end i might of added too many ends sweg
UPumpkin
#186285605Tuesday, March 29, 2016 12:54 AM GMT

BUMPPPPPPP
DrSaint
#186285711Tuesday, March 29, 2016 12:55 AM GMT

Mygod Anon, calm down.

    of     1