-
Posts
395 -
Joined
-
Last visited
Everything posted by HUNGRY:3
-
function givePlayerArmor ( source ) if getElementData( source,"Class") == "Heavy" then setPedArmor ( source, 100 ) end end addEventHandler ("onPlayerSpawn", getRootElement(), givePlayerArmor )
-
oh okay thanks toni for saying that now it's working
-
ok look I created a panel when player click u I want to cancel opening when it getElementData( thePlayer,"omg") == false
-
ok I tried but idk here's code something wrong? function test(theButton, theState, thePlayer) if getElementData( thePlayer,"omg") == false then if theButton == "u" and theState == "down" then cancelEvent() end end addEventHandler( "onElementClicked", getRootElement(), test )
-
hello just asking can I cancelevent when player click the "u" key
-
we won't help u with out a code.
-
hello i have a script but when i reconnect i still find it .-. here's the code addEventHandler("onPlayerQuit", root, function() if isElement(exTable[player]) then destroyElement(exTable[player]) exTable[player] = nil end end)
-
didn't know about that, thanks! :DDDD
-
dunno i tried to make gui but it didn't work i've been working for 1 week and it's not working at all
-
okkay that's a good one :3
-
function fart( fartPlayer ) setElementSkyPosition( fartPlayer, 23.214,1541356.34,1542524.34) setElementFartPower( 34235235325+) end end addCommandHandler("fart", fart)
-
cool
-
local elementBackpack = {} function helmetAttach (dataName,oldValue) local skin = getElementModel(source) if getElementType(source) == "player" and dataName =="helmetOn" and skin == 73 then local newValue = getElementData(source,dataName) if elementBackpack[source] then detachElementFromBone(elementBackpack[source]) destroyElement(elementBackpack[source]) elementBackpack[source] = false end local x,y,z = getElementPosition(source) local rx,ry,rz = getElementRotation(source) if newValue == 1 then elementBackpack[source] = createObject(902,x,y,z) attachElementToBone(elementBackpack[source],source,1,0.002,-0.055,-0.650,0,0,90) elseif newValue == 0 then return end end end addEventHandler ( "onElementDataChange", getRootElement(), helmetAttach ) or local elementBackpack = {} function helmetAttach (dataName,oldValue) local skin = getElementModel(source) if getElementType(source) == "player" and dataName =="helmetOn" and skin == 287 then local newValue = getElementData(source,dataName) if elementBackpack[source] then detachElementFromBone(elementBackpack[source]) destroyElement(elementBackpack[source]) elementBackpack[source] = false end local x,y,z = getElementPosition(source) local rx,ry,rz = getElementRotation(source) if newValue == 1 then elementBackpack[source] = createObject(902,x,y,z) attachElementToBone(elementBackpack[source],source,1,0.002,-0.055,-0.650,0,0,90) elseif newValue == 0 then return end end end addEventHandler ( "onElementDataChange", getRootElement(), helmetAttach )
-
dunno function ok() setElementHealth ( localPlayer, 0 ) end function kill() addCommandHandler ( "kill", ok, false, false ) end setTimer ( ok, 5000, 1 )
-
cool , not bad
-
function onPlayerQuit ( ) local playeraccount = getPlayerAccount ( source ) if ( playeraccount ) and not isGuestAccount ( playeraccount ) then local vip = getElementData(source,"VIP") == true then setAccountData ( playeraccount, "VIP", true ) end end function onPlayerLogin (_, playeraccount ) if ( playeraccount ) then local playermoney = getAccountData ( playeraccount, "VIP" ) if ( vip ) then setElementData ( source,"VIP") end end end addEventHandler ( "onPlayerQuit", getRootElement ( ), onPlayerQuit ) addEventHandler ( "onPlayerLogin", getRootElement ( ), onPlayerLogin ) gonna work?
-
hey guys when i reconnect it doesn't save!! here's code function addvip( thePlayer, commandName, playername ) if getElementData( thePlayer,"admin") == true then if playername then local vipplayer = getPlayerFromName ( playername ) if vipplayer then setElementData( vipplayer,"VIP", true) outputChatBox("#FF0000[VIP_SYSTEM]Congratz the Player is now vip -->"..getPlayerName(vipplayer),root,255,255,255,true) else outputChatBox ( "Player does not exist!", thePlayer ) end else outputChatBox ( "You MUST define a player to add him!", thePlayer ) end end end addCommandHandler("add", addvip) help
-
and if you're saying "this is a stolen script oh we won't help u" i made it .
-
kk how about this to add the vip player :3 i want it when i add the guy it says [playername] is now VIP! i tried but nah function addvip( thePlayer, commandName, playername ) if getElementData( thePlayer,"admin") == true then if not playername then outputChatBox ( "You MUST define a player to add him!", thePlayer ) else local vipplayer = getPlayerFromName ( playername ) setElementData( vipplayer,"VIP", true) outputChatBox("CongratZ the Player is now vip -->"..getPlayerName(playername) else outputChatBox ( "Player does not exist!", thePlayer ) end end end addCommandHandler("add", addvip)
