SHARE
TWEET

Untitled

a guest Oct 20th, 2019 89 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. local isloot = false
  2. local choice_loot = {function(player,choice)
  3.   local user_id = vRP.getUserId({player})
  4.   if user_id ~= nil then
  5.               if isloot == false then
  6.                 isloot = true
  7.     vRPclient.getNearestPlayer(player,{10},function(nplayer)
  8.       local nuser_id = vRP.getUserId({nplayer})
  9.       if nuser_id ~= nil then
  10.         vRPclient.isInComa(nplayer,{}, function(in_coma)
  11.           if in_coma then
  12.             local revive_seq = {
  13.               {"amb@medic@standing@kneel@enter","enter",1},
  14.               {"amb@medic@standing@kneel@idle_a","idle_a",1},
  15.               {"amb@medic@standing@kneel@exit","exit",1}
  16.             }
  17.             vRPclient.playAnim(player,{false,revive_seq,false})
  18.             SetTimeout(15000, function()
  19.               local ndata = vRP.getUserDataTable({nuser_id})
  20.               if ndata ~= nil then
  21.                 if ndata.inventory ~= nil then
  22.                   vRP.clearInventory({nuser_id})
  23.                   for k,v in pairs(ndata.inventory) do
  24.                     vRP.giveInventoryItem({user_id,k,v.amount,true})
  25.                   end
  26.                 end
  27.               end
  28.               local nmoney = vRP.getMoney({nuser_id})
  29.               if vRP.tryPayment({nuser_id,nmoney}) then
  30.                 vRP.giveMoney({user_id,nmoney})
  31.               end
  32.             end)
  33.             vRPclient.stopAnim(player,{false})
  34.                 vRP.giveInventoryItem({user_id,"قلب",1})
  35.                 vRP.giveInventoryItem({user_id,"يد",1})
  36.                 vRP.giveInventoryItem({user_id,"راس",1})
  37.           else
  38.             vRPclient.notify(player,{lang.emergency.menu.revive.not_in_coma()})
  39.           end
  40.         end)
  41.       else
  42.         vRPclient.notify(player,{lang.common.no_player_near()})
  43.       end
  44.     end)
  45.                 SetTimeout(180000,function()
  46.                     isloot = false
  47.                 end)
  48.     else
  49.                 vRPclient.notify(player,{"~o~You can't spam loot, wait 3 min"})
  50.   end
  51.   end
  52. end,"Loot nearby corpse"}
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
Not a member of Pastebin yet?
Sign Up, it unlocks many cool features!
 
Top