sckatchof Posted January 26, 2012 Share Posted January 26, 2012 hello all i need help in this script : isPlayerInTeam' local LSPEle = createMarker(1568.6572265625, -1689.9814453125, 7, "arrow", 1.5, 0, 255, 0, 255) local LSPREle = createMarker(1572.6884765625, -1675.5966796875, 29.09545249939, "arrow", 1.5, 0, 255, 0, 255) addEventHandler("onMarkerHit", LSPEle, function(hitElement, dim) if getElementType(hitElement) == "player" then if isPlayerInTeam(hitElement, "Police") then fadeCamera(hitElement, false) setTimer(setElementPosition, 1000, 1, hitElement, 1574.8115234375, -1675.4208984375, 28.39545249939) setTimer(setPedRotation, 1000, 1, hitElement, 270) setTimer(fadeCamera, 1000, 1, hitElement, true) playSoundFrontEnd(hitElement, 1) end end end ) addEventHandler("onMarkerHit", LSPREle, function(hitElement, dim) if getElementType(hitElement) == "player" then if isPlayerInTeam(hitElement, "Police") then fadeCamera(hitElement, false) setTimer(setElementPosition, 1000, 1, hitElement, 1568.447265625, -1692.6533203125, 5.890625) setTimer(setPedRotation, 1000, 1, hitElement, 175) setTimer(fadeCamera, 1000, 1, hitElement, true) playSoundFrontEnd(hitElement, 1) end end end ) Link to comment
BriGhtx3 Posted January 26, 2012 Share Posted January 26, 2012 replace the line if isPlayerInTeam(hitElement, "Police") then with if getPlayerTeam(hitElement) == "Police" then Link to comment
sckatchof Posted January 26, 2012 Author Share Posted January 26, 2012 replace the line if isPlayerInTeam(hitElement, "Police") then with if getPlayerTeam(hitElement) == "Police" then thank you Link to comment
Orange Posted January 26, 2012 Share Posted January 26, 2012 if getTeamName(getPlayerTeam(hitElement)) == "Police" then 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