Thivenin Posted August 3, 2013 Share Posted August 3, 2013 hai all, I again need help, this time is for a blip, I really don't know what to add here is the script of the marker : LMNBfirstMarker = createMarker ( -35, 14, 121.5, "arrow", 1.5, 250, 0, 250, 255 ) setElementInterior ( LMNBfirstMarker, 900 ) function LMNBfirstTP ( markerHit, matchingDimension ) if ( markerHit == LMNBfirstMarker ) then hitplayer = source setElementInterior ( 903, 423, 247, 40 ) end end addEventHandler ( "onPlayerMarkerHit", getRootElement(), LMNBfirstTP ) so I wanna remove the blip of the player who is hiting this marker, help me pls, I really don't know what to do, I'm a beginner in scripting ^^ Link to comment
Tete omar Posted August 3, 2013 Share Posted August 3, 2013 Do you mean you want to remove the attached blip to the player who hit LMNBfirstMarker? Link to comment
Thivenin Posted August 3, 2013 Author Share Posted August 3, 2013 Do you mean you want to remove the attached blip to the player who hit LMNBfirstMarker? yh the blip on the minimap and the nickname his health Link to comment
Tete omar Posted August 3, 2013 Share Posted August 3, 2013 Use: getAttachedElements destroyElement setPlayerNametagShowing I think you want to hide the player completely. Link to comment
denny199 Posted August 3, 2013 Share Posted August 3, 2013 (edited) This should do it, also what are you tryng to do with "setElementInterior ( 903, 423, 247, 40 )" LMNBfirstMarker = createMarker ( -35, 14, 121.5, "arrow", 1.5, 250, 0, 250, 255 ) setElementInterior ( LMNBfirstMarker, 900 ) function LMNBfirstTP ( hitElement, matchingDimension ) -- the function if ( getElementType(hitElement) == "player" ) then -- if the hitted elemnt is a player setPlayerNametagShowing ( hitElement, false ) -- hide the nametag setElementInterior (hitElement, 903, 423, 247, 40 ) -- plox, your interior added for ElementKey, ElementValue in ipairs ( getAttachedElements (hitElement) ) do -- loop trough the attachElements which are attached on the player if ( getElementType ( ElementValue ) == "blip" ) then -- if it found a blip element then destroyElement ( ElementValue ) -- destroy the element end end end end addEventHandler ( "onMarkerHit", LMNBfirstMarker, LMNBfirstTP ) --changed from ""onPlayerMarkerHit", getRootElement()" to "onMarkerHit, LMNBfirstMarker", because it will trigger for all markers when you will use root, and the onPlayerMarkerHit is an old event Edited August 4, 2013 by Guest Link to comment
Thivenin Posted August 3, 2013 Author Share Posted August 3, 2013 ty ) with setElementInterior ( 903, 423, 247, 40 ) I just forgot "source" for TP the player there edit : I added setElementInterior ( source, 903, 423, 247, 40 ) but it's not TPing + it's hiding the marker when I take it and it's destroying my blip and show off my tag that is working, ty Link to comment
denny199 Posted August 4, 2013 Share Posted August 4, 2013 use : "setElementInterior ( hitElement, 903, 423, 247, 40 )" Edited my previous post. 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