600er Posted March 18, 2012 Share Posted March 18, 2012 Hello guys. I need you help on a script i was doing. So.. i put this script server and client side (not at one time) but it didn't work. /debugscript 3 isn't showing some problems. Here is it: myMarker = createMarker ( 165.39999389648, 1973.5999755859, 23.60000038147, cylinder, 1.2, 0, 255, 0, 250, root ) myBlip = createBlipAttachedTo(myMarker, 56, 2, 0, 0, 0, 255, 0, 300, root ) createBlip ( -1315 , 2519 , 87 , 62 ) myTeam = createTeam ( Team1, 170, 255, 0 ) function MarkerHit( hitElement, matchingDimension ) if myMarker then setPlayerTeam ( source, Team1 ) setPlayerSkin ( thePlayer, 50 ) outputChatBox( elementType.." Good job. You entered the marker.", getRootElement(), 0, 255, 0 ) outputChatBox( "Now GTFO before you get banned.", getRootElement(), 0, 255, 0 ) end end addEventHandler( "onMarkerHit", myMarker, MarkerHit ) Can you help me to fix it pls? Thanks Link to comment
Aibo Posted March 18, 2012 Share Posted March 18, 2012 its another frankenstein script. meaning you just sticked some parts together, tried it on the server, on the client, and of course it doesnt work anywhere, because you have absolutely no idea what you're doing. main problems here are: the lack of quotes and inconsistent variable names. Link to comment
BinSlayer1 Posted March 18, 2012 Share Posted March 18, 2012 It's server-only due to the event you're using. -Instead of if myMarker type if getElementType(hitElement) == 'player' -@setPlayerTeam use hitElement instead of source -@setPlayerSkin use setElementModel(hitElement, 50) -@outputChatBox use getPlayerName(hitElement) instead of elementType Link to comment
Aibo Posted March 18, 2012 Share Posted March 18, 2012 also "Team1" should be in quotes, it's a team name string "cylinder" should be in quotes, it's marker type string setPlayerTeam should use myTeam element and not "Team1" name Link to comment
Sparrow Posted March 18, 2012 Share Posted March 18, 2012 you use: hitElement and matchingDimension and you use source, thePlayer, elementType after that to set player team, skin and on outputChatBox also, it's "cylinder" or 'cylinder' not cylinder another thing, all players will get the 2 messages. Link to comment
mjau Posted March 18, 2012 Share Posted March 18, 2012 600er dont be afraid to contact me on skype as u did before... i will help u do wahtever u are trying to... 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