-
Posts
300 -
Joined
-
Last visited
Everything posted by -Doc-
-
Post this code here DayZ\init\players\login_init.lua
-
Your meta file probably has no problem, do you checked if file exists?
-
Everything its default, just installed mta with default acl..and not edited anything
-
Hi, i got a problem with my admin panel, when im muting someone it wont unmute after the time, for example i muted me 1 sec it wont unmute me and in my local server(testing) is sais this.And to my hosted server it happens too.
-
1 more question. I have the killmessages and i dont know what to edit to show correct image, when im killing someone with hydra it outputs weapon choosen from f1, and the victim its in a vehicle and i shoot him it shows he killed himself or blown image. Script:
-
Now i have another question, when im killing a team member i should not get xp by im getting heres the script addEventHandler( 'onPlayerWasted', root, function ( ammo, killer, killerweapon, bodypart ) if getPlayerTeam(killer) == getPlayerTeam(killer) then return true end if ( killer ) and ( killer ~= source ) then if bodypart == 9 then givePlayerExp( killer, math.random ( 300,500 ) ); else givePlayerExp( killer, math.random ( 100,300 ) ); end end end );
-
I added this and still nothing. function onLogout (_,account) savePlayerExp( source ) setElementData(source, "player.level", 1) setElementData(source, "player.experience", 0) setElementData(source,"Rankicon","private") end addEventHandler ("onPlayerLogout", root, onLogout) I want to show by a video but youtube wont load.
-
Still nothing. function savePlayerExp( player ) if ( player and isElement( player ) and getElementType( player ) == 'player' ) and ( getPlayerAccount( player ) and not isGuestAccount( getPlayerAccount( player ) ) ) then setAccountData ( getPlayerAccount( player ), "level", getElementData( player, 'player.level' ) ); setAccountData ( getPlayerAccount( player ), "experience", getElementData( player, 'player.experience' ) ); setAccountData ( getPlayerAccount( player ), "rank", getElementData( player, 'Rankicon' ) ); end end function loadPlayerExp( player ) if ( player and isElement( player ) and getElementType( player ) == 'player' ) then setElementData( player, 'player.level', getAccountData( getPlayerAccount( player ), "level") or 1 ); setElementData( player, 'player.experience', getAccountData( getPlayerAccount( player ), "experience") or 0 ); setElementData( player, 'Rankicon', getAccountData( getPlayerAccount( player ), "rank") or 0 ); end end addEventHandler ( 'onPlayerQuit', root, function( ) savePlayerExp( source ); end ); addEventHandler ( 'onPlayerLogin', root, function( ) loadPlayerExp( source ); end ) function onLogout (_,account) setElementData(source, "player.level", 1) setElementData(source, "player.experience", 0) setElementData(source,"Rankicon","private") savePlayerExp( source ) end addEventHandler ("onPlayerLogout", root, onLogout)
-
Hey, i have a problem with my experience and level saver. It saves only when i quit, but when i do /logout all my killing xp disappears and it returns to last xp i had when i logged in function onLogin (_,account) setElementData(source, "player.level", getAccountData(account, "level") or 1) setElementData(source, "player.experience", getAccountData(account, "experience") or 0) end addEventHandler ("onPlayerLogin", root, onLogin) function onLogout (_,account) setElementData(source, "player.level", 1) setElementData(source, "player.experience", 0) setElementData(source,"Rankicon","private") end addEventHandler ("onPlayerLogout", root, onLogout) function saveData(thePlayer, theAccount) local theAccount = getPlayerAccount(source) if (theAccount and not isGuestAccount(theAccount)) then setAccountData (theAccount, "level", getElementData(thePlayer, "player.level")) setAccountData (theAccount, "experience", getElementData(thePlayer, "player.experience")) end end addEventHandler ("onPlayerQuit", root, function () saveData(source, getPlayerAccount(source)) end) addEventHandler ("onPlayerLogout", root, function () saveData(source, getPlayerAccount(source)) end)
-
https://community.multitheftauto.com/index.php?p=resources&s=download&resource=419&selectincludes=1
-
stopSound https://forum.multitheftauto.com/viewtopic.php?t=91915&sid=4f76aad0ef50de4aa7f367856f437fc0 if sound and isElement(sound) then stopSound(sound) end
-
He can't make a simple outputChatBox but at more complicated scripts..Better unistall mta and leave this game
-
It's writing *fix* not ''fixe''
-
And please dont try to copy again my tags in global chat.He wants this
-
getPlayerNametagColor https://wiki.multitheftauto.com/wiki/Scripting_Introduction https://wiki.multitheftauto.com/wiki/GetPlayerNametagColor