-
Posts
843 -
Joined
-
Last visited
-
Days Won
1
Everything posted by Bilal135
-
Blast section is for typing baladaondpajpdajpdajsapdjpdajpsdjpsapjdsapjdpajdpodjapjdas. So do it. Q. Who are you?
-
I learned scripting just by looking at examples, and a little scripting introduction. Never read any lua language tutorials.
-
Good job, but why don't you upload it to community?
-
See, he ain't beginner, to be exact, he ain't any scripter at all. That code is stolen from Grafuroam client files. No help for that.
-
"Jai Mata De" What does it mean? Does it mean "our hindu mom cow" ?
-
A. Life is life. Q. What is life?
-
If you want male walking styles and girl walking styles, then this should work. (Untested) maleskins = {put male skins here separated by comma} girlskins = {put girl skins here separated by comma} malewalkingstyle = writehere girlwalkingstyle = writehere function onChangeSkin() local skin = getElementModel(source) if skin == maleskins then setPedWalkingStyle(source, malewalkingstyle) elseif skin == girlskins then setPedWalkingStyle(source, girlwalkingstyle) end end addEventHandler("onElementModelChange", root, onChangeSkin) If you want walking style for every skin, then keep repeating elsief for all skins. (Untested) function onChangeSkin() local skin = getElementModel(source) if skin == skinid then setPedWalkingStyle(source, walkingstyleid) elseif skin == skinid then setPedWalkingStyle(source, walkingstyleid) end end addEventHandler("onElementModelChange", root, onChangeSkin)
-
That doesn't work Enargy...
-
Works, but how do I prevent spam of this command? For example, this command can be only used 1 time per minute. This will help to prevent abuse.
-
You meant something like this? It still doesn't work! function dxDraw() dxDrawText("You are now AFK!\nType /afk to come back!", 432, 266, 1015, 331, tocolor(255, 255, 255, 255), 2.00, "bankgothic", "left", "top", false, false, false, false, false) end function setPlayerAFK() local wanted = getPlayerWantedLevel(localPlayer) if getElementData(localPlayer,"afk") == true then then return outputChatBox("You are already AFK!", 255, 0, 0) end if isPedInVehicle(localPlayer) or wanted > 1 then return outputChatBox("Unable to go AFK!", 255, 0, 0) end if getElementData(localPlayer,"afk") == true then setElementFrozen(localPlayer, false) setElementData(localPlayer, "afk", false) setElementAlpha(localPlayer, 255) removeEventHandler("onClientRender", root, dxDraw) fadeCamera(true) else setElementFrozen(localPlayer, true) setElementData(localPlayer, "invincible", true) setElementAlpha(localPlayer, 100) fadeCamera(false) addEventHandler("onClientRender", root, dxDraw) setElementData(localPlayer, "afk", true) end end addCommandHandler("afk", setPlayerAFK)
-
Now it works but when I type /afk to get back, it says "You are already AFK".
-
This doesn't work, gives a strange error in debug. Here's the code: function dxDraw() dxDrawText("You are now AFK!", 432, 266, 1015, 331, tocolor(255, 255, 255, 255), 2.00, "bankgothic", "left", "top", false, false, false, false, false) dxDrawText("Type /afk to come back!", 568, 321, 836, 341, tocolor(255, 255, 255, 255), 0.70, "bankgothic", "left", "top", false, false, false, false, false) end function setPlayerAFK() local wanted = getPlayerWantedLevel(localPlayer) if getElementData(localPlayer, "afk", true) then return outputChatBox("You are already AFK!", 255, 0, 0) end if isPedInVehicle(localPlayer) or wanted > 1 then return outputChatBox("Unable to go AFK!", 255, 0, 0) end setElementFrozen(localPlayer, true) setElementData(localPlayer, "invincible", true) setElementAlpha(localPlayer, 100) fadeCamera(false) addEventHandler("onClientRender", root, dxDraw) setElementData(localPlayer, "afk", true) else setElementFrozen(localPlayer, false) setElementData(localPlayer, "back", true) setElementAlpha(localPlayer, 255) removeEventHandler("onClientRender", root, dxDraw) fadeCamera(true) end addCommandHandler("afk", setPlayerAFK)
-
Anyways, it wasn't working, so most probably reason for that we were unable to get player's team properly. This is how it has to be done, to get player's team. This was my 8th experiment. local team = getPlayerTeam(source) local warriors = getTeamFromName("Warriors") if (team == warriors) then --bla bla--
-
They run SOME? RPP > 95% community. Some default freeroam servers got 30+ players.....
-
It still doesn't set the skin, no errors in debug.
-
Senseless Qualification Levels LOZ
-
@WhoAmI, here's my server side: --Place Events addEvent("pershingsquarespawn", true) addEvent("IGS", true) function onLogin() player = source triggerClientEvent(player, "onClientPlayerLogin", player) end addEventHandler("onPlayerLogin", root, onLogin) addEventHandler("pershingsquarespawn", root, function() spawnPlayer(source, 1473.6114501953, -1714.1791992188, 14.046875) fadeCamera(source, true) setCameraTarget(source, source) end ) addEventHandler("IGS", root, function() spawnPlayer(source, 1927.0316162109, -1764.384765625, 13.539072036743) fadeCamera(source, true) setCameraTarget(source, source) end )
-
I triggered those two events server side to spawn the player. +You missed an 'end' on line 46. Still doesn't work. EDIT: Looks like WhoAmI posted, let me try what you have said as well.
-
Keep calm and love Pakistan....