
mremin
Members-
Posts
46 -
Joined
-
Last visited
Everything posted by mremin
-
elseif (string.find(message,"!stats")) and not (string.find(message," !stats")) then local playerCash = loadPlayerData (source,"cash") local playerPoints = loadPlayerData (source,"points") local playerRank = loadPlayerData (source,"Rank") setTimer(outputChatBox,50,1,getPlayerName (source) .. " #ffd700has " .. tostring(playerCash) .. "$ and " .. tostring(playerPoints) .. " points! He is Rank " .. tostring(playerRank) .. "!",getRootElement(),255,0,0,true) function checkWinAndIfWinGiveWinCash (totalAmmo,killer,killerWeapon,bodypart,stealth) local rank = getAliveCount() if (rank == 1) then local allAlivePlayers = getAlivePlayers() local player = allAlivePlayers[1] local playerCount = getPlayerCount() local cashToWin = playerCount *53 local pointsToWin = playerCount *13 savePlayerData (player,"points",loadPlayerData(player,"points") + pointsToWin) savePlayerData (player,"cash",loadPlayerData(player,"cash") +cashToWin) outputChatBox (getPlayerName(player) .." #FF0000is first! He wins " .. tostring(pointsToWin) .." points and " .. tostring(cashToWin) .."$!" ,getRootElement(),255,0,0,true) end function getPlayerRank (thePlayer) local Points = loadPlayerData (source,"points") if (getPlayerData(getLocalPlayer(), "points") <= 0 ) then setPlayerData(getLocalPlayer(), "Rank") "Newbie" elseif (getPlayerData(getLocalPlayer(), "points") <= 100 ) then setPlayerData(getLocalPlayer(), "Rank") "Guest" elseif (getPlayerData(getLocalPlayer(), "points") <=250 ) then setPlayerData(getLocalPlayer(), "Rank") "Player" elseif (getPlayerData(getLocalPlayer(), "Points") <= 500 ) then setPlayerData(getLocalPlayer(), "Rank") "Known" elseif (getPlayerData(getLocalPlayer(), "Points") <= 1000 ) then setPlayerData(getLocalPlayer(), "Rank") "Server friend" elseif (getPlayerData(getLocalPlayer(), "Points") <= 2500 ) then setPlayerData(getLocalPlayer(), "Rank") "V.I.P" elseif (getPlayerData(getLocalPlayer(), "Points") <= 5000 ) then setPlayerData(getLocalPlayer(), "Rank") "Faumos" elseif (getPlayerData(getLocalPlayer(), "Points") <= 10000 ) then setPlayerData(getLocalPlayer(), "Rank") "Pro" elseif (getPlayerData(getLocalPlayer(), "Points") <= 50000 ) then setPlayerData(getLocalPlayer(), "Rank") "Crazy" elseif (getPlayerData(getLocalPlayer(), "Points") <= 1000000 ) then setPlayerData(getLocalPlayer(), "Rank") "Insane" savePlayerData (getLocalPlayer(),"rank",Player(getLocalPlayer(),"Rank")) end end working but only he is Rank 0!! why?????? will be mad help me pls
-
i know but my english bad ... come my server and look me
-
addEventHandler ("onPlayerChat",getRootElement(), function(message,type) if (string.find(message,"!points")) and not (string.find(message," !points")) then local playerPoints = loadPlayerData (source,"points") setTimer(outputChatBox,50,1,getPlayerName (source) .. " #FF0000has " .. tostring(playerPoints) .. " points!",getRootElement(),255,0,0,true) elseif (string.find(message,"!cash")) and not (string.find(message," !cash")) then local playerCash = loadPlayerData (source,"cash") setTimer(outputChatBox,50,1,getPlayerName (source) .. " #FF0000has " .. tostring(playerCash) .. "$!",getRootElement(),255,0,0,true) how can i make !cash [name] or /cash [name]???
-
opens, but does not function. i know cash system https://community.multitheftauto.com/index.php?p= ... ils&id=819 it script work but dont have level
-
not work.I dont have luck.
-
understand but i have sleep :/I'm looking for a day .See ur site. https://community.multitheftauto.com/ind ... ils&id=819
-
yes,do u know exo clan server? this server have level system . https://community.multitheftauto.com/ind ... ils&id=819
-
i dont say because exp_system for any gamemode.
-
what that knowlage
-
for race server??? exp_system said any gamemode
-
'''onElementDataChange that means when you do like: setElementData(playerElement,"exp",10) will raise your level to 1''' what is this??
-
yes where is setElementData(playerElement,"exp",10) (((((((((((((((((((((((888
-
pff my english bad this post sender castillo.but did not help me https://community.multitheftauto.com/index.php?p= ... ls&id=1253
-
Well, someone was asking for a experience/level system in mta forums so i didn't had anything to do and made it (i hope this is what they mean ) script works like this: the script works onElementDataChange that means when you do like: setElementData(playerElement,"exp",10) will raise your level to 1, the script checks for a data in a sql database that is created when resource starts and when a player logins the data will be set to 0 if he doesn't had any data yet. then the script finds that data and compares it. P.S: i'm bad in explaining Would you make i could not
-
Did you read the real link?I do not understand what to do
-
not changed but Add anything he says. I could not do it
-
local rootElement = getRootElement() levels = {} levels[0] = {"Test 0", "10"} levels[1] = {"Test 1", "20"} levels[2] = {"Test 2", "100"} levels[3] = {"Test 3", "150"} levels[4] = {"Test 4", "200"} function ResourceStart () executeSQLCreateTable("levels", "accountname STRING, level INT") end addEventHandler("onResourceStart", getResourceRootElement(getThisResource()), ResourceStart) function addPlayer() local account = getPlayerAccount(source) local playername = getPlayerName(source) CheckPlayer = executeSQLSelect ( "levels", "accountname", "accountname = '" .. getAccountName(account) .. "'" ) if ( type( CheckPlayer ) == "table" and #CheckPlayer == 0 ) or not CheckPlayer then executeSQLInsert ( "levels", "'".. getAccountName(account) .."','0'" ) end end addEventHandler("onPlayerLogin",rootElement,addPlayer) addEventHandler( "onElementDataChange", rootElement, function () if getElementType(source) == "player" then local acc = getPlayerAccount(source) local accountname = getAccountName(acc) local playername = getPlayerName(source) local data = getElementData(source,"exp") local sqldata = executeSQLSelect ( "levels", "level","accountname = '" .. accountname .. "'") lvl = sqldata[1]["level"] if tostring(data) == tostring(levels[lvl][2]) then outputChatBox("*Level system: congratulations ".. playername .." you're now a ".. levels[lvl][1] .."!",getRootElement(),0,255,0) local textDis = textCreateDisplay () local item = textCreateTextItem( "LEVEL UP! YOU'RE NOW LEVEL ".. tostring(sqldata[1]["level"]), 0.5, 0.4, 2, 0, 255, 0, 255, 4, "center", "center" ) textDisplayAddText ( textDis, item ) textDisplayAddObserver ( textDis, source ) setTimer ( textDestroyTextItem, 5000, 1, item ) setTimer ( textDestroyDisplay, 5000, 1, textDis ) sql = tonumber(sqldata[1]["level"]) + 1 executeSQLUpdate("levels", "level = '".. sql .."'", "accountname = '".. accountname .."'") end end end) -24. Error in row-I could not, please help me https://community.multitheftauto.com/index.php?p= ... 253&vote=5 <-------the real link here
-
Why was closed maps and modes area???I can not find any script.i need race start pack full version.who have this script?? help me