Advertisement
Guest User

Untitled

a guest
Jun 25th, 2017
64
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 1.19 KB | None | 0 0
  1. function showBeacon ( thePlayer, commandName )
  2.         if exports.players:isLoggedIn( thePlayer ) then
  3.                 local pdMember = getElementsByType("player")
  4.                     for k, v in ipairs ( pdMember ) do
  5.                         local inPD, factionID, factionName, factionTag = exports.factions:isPlayerInFactionType( pdMember, 1 )
  6.                     --if inPD and factionTag then
  7.                         outputchatbox(tostring(inPD) ..", "tostring(factionID), v)
  8.                      --else
  9.                             --  outputChatBox(tostring(inPD) .."Error"tostring(factionID), v, 255, 0, 0)
  10.                     --[[    if not backupBeacon then
  11.                                 local playerx, playery, playerz = getElementPosition( thePlayer )
  12.                                 backupBlip = createBlip( playerx, playery, playerz, 0, 3, 255, 0, 0, 255, 0 , 99999.0, pdMember)
  13.                                 outputChatBox("A unit is in need of assistance, respond ASAP!", pdMember, 255, 150, 0)
  14.                                 attachElements ( backupBlip, thePlayer)
  15.                                 backupBeacon = true
  16.                             else
  17.                                 destroyElement( backupBlip )
  18.                                 backupBeacon = false
  19.                                 outputChatBox("The unit no longer requires assistance.", pdMember, 255, 150, 0)
  20.  
  21.                         end]]
  22.                         end
  23.                 end
  24.         end
  25. end
  26. addCommandHandler("backup", showBeacon)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement