0 Üye ve 1 Ziyaretçi konuyu incelemekte.
engineLoadIFP ("Fortnite pt1.ifp", "Fortnite_1") engineLoadIFP ("Fortnite pt2.ifp", "Fortnite_2") engineLoadIFP ("Fortnite pt3.ifp", "Fortnite_3")Bailes = { {"Fortnite_1","baile 1",nil,2000}, {"Fortnite_1","baile 2","OrangeJustice",14000}, {"Fortnite_1","baile 3","StarPower",9000}, {"Fortnite_1","baile 4","Eagle",6000}, {"Fortnite_1","baile 5","Electro",14000}, {"Fortnite_1","baile 6","Infinity",14000}, {"Fortnite_2","baile 7","DanceMoves",6700}, {"Fortnite_2","baile 8",nil,7000}, {"Fortnite_3","baile 9","Hype",14000}, {"Fortnite_3","baile 10","Floss",14000}, {"Fortnite_3","baile 11","Lerdo",14000}, {"Fortnite_3","baile 12","BestMate",14000}, {"Fortnite_3","baile 13","Groove",14000}, } local Sonidos = {}local Fornite = 0function setPedFortniteAnimation (ped,animation,repetir,mover,interrumpible) if ( getTickCount ( ) - Fornite >= 15000 ) then if (type(animation) ~= "string" or type(repetir) ~= "boolean" or type(mover) ~= "boolean" or type(interrumpible) ~= "boolean") then return false end if isElement(ped) and isPedOnGround(ped) then if (isPedDoingTask(ped,"TASK_SIMPLE_PLAYER_ON_FOOT")) then for index, dance in pairs(Bailes) do if dance[2] == animation then setPedAnimation(ped, dance[1], dance[2], dance[4], true, false, false) if dance[3] then if isElement(Sonidos[ped]) then stopSound(Sonidos[ped]) end if dance[2] == "baile 7" then baileN = math.random(1,2) else baileN = "" end Sonidos[ped] = playSound3D( "Fortnite/"..dance[3]..""..baileN..".ogg", getElementPosition(ped)) setSoundMaxDistance(Sonidos[ped],30) setSoundVolume(Sonidos[ped],1) setTimer(function() if Sonidos[ped] then stopSound(Sonidos[ped]) end end,dance[4]+300,1) Fornite = getTickCount ( ) end setTimer(setPedAnimation,dance[4],1,ped,false) end end end end --if animation == "None" then if Sonidos[ped] then stopSound(Sonidos[ped]) triggerServerEvent('PlayerSyncAnimation2',ped,ped) end end endendaddEvent("setPedFortniteAnimation",true)addEventHandler("setPedFortniteAnimation",getRootElement(),setPedFortniteAnimation)
function setPedFortniteAnimation (ped,animation,tiempo,repetir,mover,interrumpible) if (type(animation) ~= "string" or type(repetir) ~= "boolean" or type(mover) ~= "boolean" or type(interrumpible) ~= "boolean") then return false end if isElement(ped) then if getElementData(ped,"haceAnimacion") == false then triggerClientEvent( getRootElement(),"setPedFortniteAnimation",getRootElement(), ped,animation,repetir,mover,interrumpible ) end endendfunction PlayerSyncAnimation2( Jugador , ArbolAnim , Animacion , Time) if isElement(Jugador) then setPedAnimation( Jugador, false) endendaddEvent("PlayerSyncAnimation2", true)addEventHandler("PlayerSyncAnimation2", getRootElement(), PlayerSyncAnimation2)function Fornite( player , cmd , baile ) if tonumber(baile) and tonumber(baile) >= 1 and tonumber(baile) <= 13 then if getElementData(player,"haceAnimacion") == false then if not isPedInVehicle(player) then setPedFortniteAnimation(player,"baile "..baile ,7000,true,false,false,false) end end else outputChatBox ( "Command /baile [1-13]" , player, 239,123,0,true ) endendaddCommandHandler("baile",Fornite)