bandi94 Posted June 26, 2011 Share Posted June 26, 2011 hello have sombody a total win script i mean when somebody get the hunter the win +1 and whit datasave or account data save ( when player left game the wins get saved and when the player login again the point load and ...) thx Link to comment
Castillo Posted June 26, 2011 Share Posted June 26, 2011 function vehicleDetector(pickupID, pickupType, vehicleModel) if pickupType == "vehiclechange" and vehicleModel == 425 then increaseAccountData(source) outputChatBox("*HUNTER ALERT: "..getPlayerName(source).." has found the Hunter!",getRootElement(),25,125,225, true) end end addEventHandler("onPlayerPickUpRacePickup",getRootElement(),vehicleDetector) function increaseAccountData(player) if not player then return end local account = getPlayerAccount(player) if not account or isGuestAccount(account) then return end local accountData = getAccountData(account,"hunterPoints") if not accountData then setAccountData(account,"hunterPoints",1) else setAccountData(account,"hunterPoints",tonumber(accountData)+1) end end I think it should work (not tested). Link to comment
bandi94 Posted June 26, 2011 Author Share Posted June 26, 2011 ok i will test it and can you ad to show points in tab menu ? or i will try to make it but i am a noob in scripting Link to comment
Castillo Posted June 26, 2011 Share Posted June 26, 2011 Well, I think I already gave you the most part, now you should try doing the rest, right? Link to comment
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now