-
Posts
334 -
Joined
-
Last visited
Everything posted by Jokeℝ1472771893
-
Pleas help i can't start Map
-
LOL Nice that it was me
-
if getTeamName(getPlayerTeam(player)) == "Armed Force" then where i need to add this line?
-
local maxBarriers = 4 local barriers = {} function createBarrier(player) if isObjectInACLGroup ("user."..getAccountName(getPlayerAccount(player)), aclGetGroup("Armed Force")) then if not barriers[player] then barriers[player] = {} end if #barriers[player] >= maxBarriers then destroyElement(barriers[player][1]) table.remove(barriers[player],1) end local x,y,z = getElementPosition(player) local xR,yR,zR = getElementRotation(player) local obj = createObject(3091,x,y,z,xR,yR,zR) table.insert(barriers[player], obj) end addCommandHandler("ab",createBarrier) this?
-
local maxBarriers = 4 local barriers = {} function createBarrier(player) if isObjectInACLGroup ("user."..getAccountName(getPlayerAccount(player)), aclGetGroup("Armed Force")) then if not barriers[player] then barriers[player] = {} end if #barriers[player] >= maxBarriers then destroyElement(barriers[player][1]) table.remove(barriers[player],1) end local x,y,z = getElementPosition(player) local xR,yR,zR = getElementRotation(player) local obj = createObject(3091,x,y,z,xR,yR,zR) table.insert(barriers[player], obj) end addCommandHandler("ab",createBarrier) Like this?
-
thnx its WORK
-
Nonononono not team but ACL group
-
How to make for Armed Force group only ?
-
what about Team?
-
function LSPDCuff (attacker, attackerweapon, bodypart, loss) if (attackerweapon == 3) and (loss > 2 and getPlayerWantedLevel(player) == 2 ) then setElementPosition (source,227.10449221875, 111.24414062, 999.015625, true) takePlayerMoney (source, 100) givePlayerMoney (attacker, 1000) end end addEventHandler ("onPlayerDamage", getRootElement(), LSPDCuff) Like this?
-
you can make a table, like -- to add barriers = {} barriers[player] = {} obj = createObject() table.insert(barriers[player],obj) -- to check number of objects a player created #barriers[player] -- to remove table.remove -- remove from table destroyElement -- destroy the object http://lua-users.org/wiki/TablesTutorial http://lua-users.org/wiki/TableLibraryTutorial but i can't do it its dont work anymore
-
i try now thnx
-
function LSPDCuff (attacker, attackerweapon, bodypart, loss) if (attackerweapon == 3) and (loss > 2 ) then setElementPosition (source,227.10449221875, 111.24414062, 999.015625, true) takePlayerMoney (source, 100) givePlayerMoney (attacker, 1000) end end addEventHandler ("onPlayerDamage", getRootElement(), LSPDCuff local players = getElementsByType ( "player" ) for theKey,thePlayer in ipairs(players) do local level = getPlayerWantedLevel ( thePlayer ) if ( level > 0 ) then outputChatBox ( getPlayerName ( thePlayer ) .. " Has a wanted level of " .. level .. " stars!" ) end end function outputWantedLevel () local wantedLvl = getPlayerWantedLevel ( ) if wantedLvl == 0 then outputChatBox ( "You clean", 0, 255, 0) else outputChatBox ( "You have "..wantedLvl.." wanted stars!", 255, 0, 0) end end addCommandHandler ( "wanted", outputWantedLevel ) Like this?
-
function LSPDCuff (attacker, attackerweapon, bodypart, loss) if (attackerweapon == 3) and (loss > 2 ) then setElementPosition (source,227.10449221875, 111.24414062, 999.015625, true) takePlayerMoney (source, 100) givePlayerMoney (attacker, 1000) end end addEventHandler ("onPlayerDamage", getRootElement(), LSPDCuff How to make this when player have wanted level then Police can Jail?
-
thnx
-
Yeh its work thnx you all
-
where i add that? setElementHealth ( attacker, getElementHealth ( attacker ) - 10 )
-
yeh thnx i dont die but player who shot me dont loose health too what can i do?
-
how to make it only take 4 bariers after 5 / 1st barier destroy
-
what is wrong?
-
But how to make it Limeted?
-
<meta> <info author="Guso" type="play" name="Gu" description="My first MTA server" /> <script src="staff.lua" /> <script src="team.lua" /> </meta>
-
Nothing