Alazam Posted February 14, 2014 Share Posted February 14, 2014 Hello i create marker for when a player go in the marker they are teleported to a interor here the script groovemarker = createMarker ( 2495.3999,-1690.80005,13.8, "cylinder", 1, 57, 178, 20, 255 ) ballasmarker = createMarker ( 2230.8000488281,-1408,23, "cylinder", 1, 125, 24, 132, 255 ) vagosmarker = createMarker ( 1857.0999755859,-2035.8000488281,12.5, "cylinder", 1, 166, 166, 26, 255 ) copsmarker = createMarker ( 1554.5,-1675.59998,15.2, "cylinder", 1, 35, 58, 178, 255 ) groovemarkerreturn = createMarker ( 2468.3999023438,-1698.3000488281,1012.5, "cylinder", 1, 57, 178, 20, 255 ) ballasmarkerreturn = createMarker ( 1531.4000244141,-7.1999998092651,1000.9000244141, "cylinder", 1, 125, 24, 132, 255 ) vagosmarkerreturn = createMarker ( 2352.6000976563,-1180.8000488281,1027, "cylinder", 1, 166, 166, 26, 255 ) copsmarkerreturn = createMarker ( 246.39999389648,107.59999847412,1002.200012207, "cylinder", 1, 57, 178, 20, 255 ) setElementInterior(groovemarkerreturn, 2) setElementInterior(ballasmarkerreturn, 3) setElementInterior(vagosmarkerreturn, 5) setElementInterior(copsmarkerreturn, 10) function groovemarkertp( hitElement, matchingDimension ) setElementInterior ( hitElement, 2, 2464.2110 , -1697.9520 , 1013.5080 ) end addEventHandler( "onMarkerHit", groovemarker, groovemarkertp ) function ballasmarkertp( hitElement, matchingDimension ) setElementInterior ( hitElement, 3, 1527.38 , -11.02 , 1002.10 ) end addEventHandler( "onMarkerHit", ballasmarker, ballasmarkertp ) function vagosmarkertp( hitElement, matchingDimension ) setElementInterior ( hitElement, 5, 2351.1540 , -1180.5770 , 1027.9770 ) end addEventHandler( "onMarkerHit", vagosmarker, vagosmarkertp ) function copsmarkertp( hitElement, matchingDimension ) setElementInterior ( hitElement, 10, 246.4410 , 112.1640 , 1003.2190 ) end addEventHandler( "onMarkerHit", copsmarker, copsmarkertp ) function groovemarkerreturntp( hitElement, matchingDimension ) setElementInterior ( hitElement, 0, 2495.2705 , -1688.55468 , 13.879 ) end addEventHandler( "onMarkerHit", groovemarkerreturn, groovemarkerreturntp ) Only the groove teleport work but i cant come to normal world after i have enter please help thank Link to comment
Moderators Citizen Posted February 14, 2014 Moderators Share Posted February 14, 2014 Of course, you didn't even finish your code ... Am I right if I say that you didn't made this code yourself ?? Add this code at the end of "your" code: function ballasmarkerreturntp( hitElement, matchingDimension ) setElementInterior(hitElement, 0, 2230.8000488281, -1408, 23) end addEventHandler( "onMarkerHit", ballasmarkerreturn, ballasmarkerreturntp) function vagosmarkerreturntp( hitElement, matchingDimension ) setElementInterior(hitElement, 0, 1857.0999755859, -2035.8000488281, 12.5) end addEventHandler( "onMarkerHit", vagosmarkerreturn, vagosmarkerreturntp ) function copsmarkerreturntp( hitElement, matchingDimension ) setElementInterior(hitElement, 0, 1554.5, -1675.59998, 15.2) end addEventHandler( "onMarkerHit", copsmarkerreturn, copsmarkerreturntp ) Link to comment
Alazam Posted February 14, 2014 Author Share Posted February 14, 2014 thank but the script is 100 % me i dont finish the script because i have think that because the teleport dont work its because of another problem Link to comment
Moderators Citizen Posted February 15, 2014 Moderators Share Posted February 15, 2014 Alright, then you don't really understand what tou were actually doing or something. So is it working after adding the missing code I gave you ? Link to comment
Alazam Posted February 16, 2014 Author Share Posted February 16, 2014 I understand but same when i have add your code its not working only the pickup appear but when i go in iam not teleported except for groove street Link to comment
Moderators Citizen Posted February 16, 2014 Moderators Share Posted February 16, 2014 Any error in the console ? Did you restarted the resource for modifications taking effects ? Link to comment
Alazam Posted February 16, 2014 Author Share Posted February 16, 2014 I have no error and yes i have restart Link to comment
Anubhav Posted February 24, 2014 Share Posted February 24, 2014 Try removing matchingDimension from functions. Link to comment
Alazam Posted February 26, 2014 Author Share Posted February 26, 2014 its change nothing Link to comment
Karuzo Posted February 26, 2014 Share Posted February 26, 2014 You put it as serverside in your meta? Link to comment
Alazam Posted February 26, 2014 Author Share Posted February 26, 2014 yes off course its in my main script file Link to comment
WhoAmI Posted February 26, 2014 Share Posted February 26, 2014 Maybe use setElementPosition instead of interior. Link to comment
pa3ck Posted February 26, 2014 Share Posted February 26, 2014 setElementInterior is fine, post your meta.xml Link to comment
Alazam Posted February 28, 2014 Author Share Posted February 28, 2014 My full server side script teamgroove = createTeam ( "Groove", 26, 124, 15 ) teamballas = createTeam ( "Ballas", 69, 21, 132 ) teamvagos = createTeam ( "Vagos", 172, 153, 28 ) teamcops = createTeam ( "Cops", 20, 63, 208 ) groovemarker = createMarker ( 2495.3999,-1690.80005,13.8, "cylinder", 1, 57, 178, 20, 255 ) --ballasmarker = createMarker ( 2230.8000488281,-1408,23, "cylinder", 1, 125, 24, 132, 255 ) --vagosmarker = createMarker ( 1857.0999755859,-2035.8000488281,12.5, "cylinder", 1, 166, 166, 26, 255 ) --copsmarker = createMarker ( 1554.5,-1675.59998,15.2, "cylinder", 1, 35, 58, 178, 255 ) groovemarkerreturn = createMarker ( 2468.3999023438,-1698.3000488281,1012.5, "cylinder", 1, 57, 178, 20, 255 ) --ballasmarkerreturn = createMarker ( 1531.4000244141,-7.1999998092651,1000.9000244141, "cylinder", 1, 125, 24, 132, 255 ) --vagosmarkerreturn = createMarker ( 2352.6000976563,-1180.8000488281,1027, "cylinder", 1, 166, 166, 26, 255 ) --copsmarkerreturn = createMarker ( 246.39999389648,107.59999847412,1002.200012207, "cylinder", 1, 57, 178, 20, 255 ) setElementInterior(groovemarkerreturn, 2) --setElementInterior(ballasmarkerreturn, 3) --setElementInterior(vagosmarkerreturn, 5) --setElementInterior(copsmarkerreturn, 10) function groovemarkertp( hitElement, matchingDimension ) setElementInterior ( hitElement, 2, 2464.2110 , -1697.9520 , 1013.5080 ) end addEventHandler( "onMarkerHit", groovemarker, groovemarkertp ) --function ballasmarkertp( hitElement, matchingDimension ) --setElementInterior ( hitElement, 3, 1527.38 , -11.02 , 1002.10 ) --end --addEventHandler( "onMarkerHit", ballasmarker, ballasmarkertp ) --function vagosmarkertp( hitElement, matchingDimension ) --setElementInterior ( hitElement, 5, 2351.1540 , -1180.5770 , 1027.9770 ) --end --addEventHandler( "onMarkerHit", vagosmarker, vagosmarkertp ) --function copsmarkertp( hitElement, matchingDimension ) --setElementInterior ( hitElement, 10, 246.4410 , 112.1640 , 1003.2190 ) --nd --addEventHandler( "onMarkerHit", copsmarker, copsmarkertp ) function groovemarkerreturntp( hitElement, matchingDimension ) setElementInterior ( hitElement, 0, 2495.3999,-1690.80005,13.8 ) end addEventHandler( "onMarkerHit", groovemarkerreturn, groovemarkerreturntp ) --function ballasmarkerreturntp( hitElement, matchingDimension ) -- setElementInterior(hitElement, 0, 2230.8000488281, -1408, 23) --end --addEventHandler( "onMarkerHit", ballasmarkerreturn, ballasmarkerreturntp) --function vagosmarkerreturntp( hitElement, matchingDimension ) -- setElementInterior(hitElement, 0, 1857.0999755859, -2035.8000488281, 12.5) --end --addEventHandler( "onMarkerHit", vagosmarkerreturn, vagosmarkerreturntp ) --function copsmarkerreturntp( hitElement, matchingDimension ) -- setElementInterior(hitElement, 0, 1554.5, -1675.59998, 15.2) --end function groovespawn() spawnPlayer(client, 2495, -1686, 13) fadeCamera(client, true) setCameraTarget(client, client) outputChatBox("You are a groove", client) giveWeapon ( source, 1, 1 ) giveWeapon ( source, 28, 500 ) giveWeapon ( source, 25, 500 ) setElementModel( source, 106 ) setPlayerTeam( client, teamgroove) end function ballasspawn() spawnPlayer(client, 2247, -1456, 24) fadeCamera(client, true) setCameraTarget(client, client) outputChatBox("You are a ballas", client) giveWeapon ( source, 1, 1 ) giveWeapon ( source, 32, 500 ) giveWeapon ( source, 30, 500 ) setElementModel( source, 104 ) setPlayerTeam( client, teamballas) end function vagosspawn() spawnPlayer(client, 1883, -2001, 13) fadeCamera(client, true) setCameraTarget(client, client) outputChatBox("You are a vagos", client) giveWeapon ( source, 1, 1 ) giveWeapon ( source, 29, 500 ) giveWeapon ( source, 33, 500 ) setElementModel( source, 109 ) setPlayerTeam( client, teamvagos) end function copsspawn() spawnPlayer(client, 1575, -1634, 13) fadeCamera(client, true) setCameraTarget(client, client) outputChatBox("You are a cops", client) giveWeapon ( source, 31, 500 ) giveWeapon ( source, 22, 500 ) giveWeapon ( source, 17, 3 ) setElementModel( source, 267 ) setPlayerTeam( client, teamcops) end addEvent("grooveevent",true) addEvent("ballasevent",true) addEvent("vagosevent",true) addEvent("copsevent",true) addEventHandler("grooveevent",root,groovespawn) addEventHandler("ballasevent",root,ballasspawn) addEventHandler("vagosevent",root,vagosspawn) addEventHandler("copsevent",root,copsspawn) and meta <meta> <info author="Alazam" type="gamemode" name="Gangdm" description="Gang death match" /> <script src="client.lua" type="client" /> <script src="server.lua" type="server" /> <include resource="gangmap" /> <include resource="reload" /> <include resource="superman" /> <include resource="realdriveby" /> <include resource="headshot" /> </meta> Link to comment
Moderators Citizen Posted February 28, 2014 Moderators Share Posted February 28, 2014 Ok, and what's the problem you want us to fix ? Link to comment
Alazam Posted March 5, 2014 Author Share Posted March 5, 2014 when i enter inthe marker i enter in the interior but i cant exit when i enter the marker for exit 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