golanu21 Posted March 27, 2013 Posted March 27, 2013 how i make that ? : when a person (player1) has ben killed by a attaker (player2) attaker to recive WantedLevel math.random (3,5)
codeluaeveryday Posted March 27, 2013 Posted March 27, 2013 addEventHandler('onPlayerWasted', getRootElement(), function(totalAmmo, killer, killerWeapon, bodypart) if killer and killer ~= source then stars = math.random(3, 5) setPlayerWantedLevel(killer, stars) outputChatBox('You have killed '..getPlayerName(source):gsub('#%x%x%x%x%x%x', '')..', you will now get '.. tostring(stars)..' stars!', killer, 200, 155, 0) end end )
golanu21 Posted March 27, 2013 Author Posted March 27, 2013 addEventHandler('onPlayerWasted', getRootElement(), function(totalAmmo, killer, killerWeapon, bodypart) if killer and killer ~= source then stars = math.random(3, 5) setPlayerWantedLevel(killer, stars) outputChatBox('You have killed '..getPlayerName(source):gsub('#%x%x%x%x%x%x', '')..', you will now get '.. tostring(stars)..' stars!', killer, 200, 155, 0) end end ) thanx man ...
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