Jump to content

xeon17

Members
  • Posts

    1,903
  • Joined

  • Last visited

  • Days Won

    1

Everything posted by xeon17

  1. Post the superman resource then we can help you.
  2. xeon17

    Question

    Wow TAPL this is perfect ! thank you so much my Bases system is finished now see the script i put your name in authors , your help was verry usefull ----------------------------------------------------- -- script Bases system MTA:SA Gang War -- @author EufraT & TAPL -- @update 28/1/2014 ----------------------------------------------------- radararea2 = createRadarArea( 110.91990, 1800.89435, 200, 145, 255, 255, 255, 225 ) createBlip(279.40317, 1831.25439, 7.72656,62) marker2 = createMarker(298.98865, 1815.90613, 3.71094,"cylinder",2,0,0,255,255) Maverick = createVehicle ( 487, 251.64256286621,1920.413574218817,640630722046 ) addCommandHandler ( "comprar51", function ( player ) local money = getPlayerMoney ( player ) local playerTeam = getPlayerTeam ( player ) local r, g, b = getTeamColor ( playerTeam ) local teamMates = getPlayersInTeam ( playerTeam ) if(isElementWithinMarker(player,marker2)) and ( money > 1000000 ) then takePlayerMoney ( player, 1000000 ) setRadarAreaColor ( radararea2, r, g, b, 155 ) outputChatBox ( "#FFF000 [bASE] #FF0000You buyed this base.", player, 0, 0, 0, true ) for _, v in ipairs(teamMates) do outputChatBox ( "#FFF000 [bASE] #FF0000 Sua gang comprou a base #00FF00 Area 51!", v, 0, 0, 0, true ) end else outputChatBox ( "#FFF000 [bASE] #FF0000You don't have money or you are out of checkpoint", player, 0, 0, 0, true ) end end) addEventHandler("onMarkerHit", marker2, function (player) outputChatBox ( "#FFF000 [bASE] #FF0000 Para comprar a base digita #00FF00 /comprar51 (1000000$)", player, 0, 0, 0, true) end ) function Vender ( player ) if(isElementWithinMarker(player,marker2)) then local playerTeam = getPlayerTeam ( player ) if ( playerTeam ) then givePlayerMoney ( player, 1000000 ) setRadarAreaColor ( radararea2, 255, 255, 255, 155 ) outputChatBox ( "#FFF000 [bASE] #FF0000 Sua gang vendeu a base #00ff00 Area 51!", player, 0, 0, 0, true ) end end end addCommandHandler ( "vender", Vender ) function Car_Color ( player ) if(isElementWithinMarker(player,marker2)) then local playerTeam = getPlayerTeam ( player ) if ( playerTeam ) then local r, g, b = getTeamColor ( playerTeam ) setVehicleColor( Maverick, r, g, b ) end end end addCommandHandler ( "comprar51", Car_Color ) radararea2 = createRadarArea(110.91990, 1800.89435, 200, 145, 255, 255, 255, 225) function Area_51_Base_Spawn() local playerTeam = getPlayerTeam(source) if (playerTeam) then local r, g, b = getTeamColor(playerTeam) local aR, aG, aB = getRadarAreaColor(radararea2) if (r == aR) and (g == aG) and (b == aB) then setElementPosition(source, 298.98865, 1815.90613, 3.71094) end end end addEventHandler("onPlayerSpawn", getRootElement(), Area_51_Base_Spawn)
  3. xeon17

    Question

    I'm not so good scripter i make to much mistakes. :D radararea2 = createRadarArea( 110.91990, 1800.89435, 200, 145, 255, 255, 255, 225 ) function Area_51_Base_Spawn ( source ) local playerTeam = getPlayerTeam ( source ) if ( playerTeam ) then local r, g, b = getTeamColor ( playerTeam ) local color = getRadarAreaColor ( radararea2) if ( color = r,g,b ) then setElementPosition ( source, 298.98865, 1815.90613, 3.71094 ) end end addEventHandler ( "onPlayerSpawn", getRootElement(), Area_51_Base_Spawn ) Can this script do , when a player die this script get his team and his team color and the radararea2 color , and if his team and radararea2 have same color then he spawn in the area 51. (radararea2) base
  4. xeon17

    Question

    Is this possible i wanna so much crate a spawn system for my Bases but i no have idea how radararea2 = createRadarArea( 110.91990, 1800.89435, 200, 145, 255, 255, 255, 225 ) function Area_51_Base_Spawn ( player ) local playerTeam = getPlayerTeam ( player ) if ( playerTeam ) then local r, g, b = getTeamColor ( playerTeam ) local color = getRadarAreaColor ( radararea2) if ( color = r,g,b ) then setElementPosition ( player, 298.98865, 1815.90613, 3.71094 ) end end addEventHandler ( "onPlayerSpawn", player, Area_51_Base_Spawn ) [
  5. xeon17

    Bug

    Perfect *-* thank you
  6. xeon17

    Bug

    But now i no get the message outputChatBox ( "#FFF000 [bASE] #FF0000 Sua gang comprou a base #00FF00 Area 51!", player, 0, 0, 0, true ) when player buy the base
  7. xeon17

    Bug

    I got a problem with the script , Player can buy base withour the money or when he isnt on marker and he get the message [bASE] Area 51 seu gang comprou base (the message should be when player buy base ) and i get message you arent on checkpoint.. so i tryed to change and the frist function is is element with marker but then i got bug . please help script is verry bugged now radararea2 = createRadarArea( 110.91990, 1800.89435, 200, 145, 255, 255, 255, 225 ) createBlip(279.40317, 1831.25439, 7.72656,62) marker2 = createMarker(298.98865, 1815.90613, 3.71094,"cylinder",2,0,0,255,255) Maverick = createVehicle ( 487, 251.64256286621,1920.413574218817,640630722046 ) addCommandHandler ( "comprar51", function ( player ) if(isElementWithinMarker(player,marker2)) then local money = getPlayerMoney ( player ) if ( money >= 1000000 ) then takePlayerMoney ( player, 1000000 ) else outputChatBox ( "#FFF000 [bASE] #FF0000 Voce não possui dinheiro suficiente para comprar a Base", player, 0, 0, 0, true ) local playerTeam = getPlayerTeam ( player ) if ( playerTeam ) then local r, g, b = getTeamColor ( playerTeam ) else outputChatBox ( "#FFF000 [bASE] #FF0000 Você não esta em uma checkpoint", player, 0, 0, 0, true ) setRadarAreaColor ( radararea2, r, g, b, 155 ) local color = getTeamColor ( playerTeam ) outputChatBox ( "#FFF000 [bASE] #FF0000 Sua gang comprou a base #00FF00 Area 51!", player, 0, 0, 0, true ) end end end ) addEventHandler("onMarkerHit", marker2, function (player) outputChatBox ( "#FFF000 [bASE] #FF0000 Para comprar a base digita #00FF00 /comprar51 (1000000$)", player, 0, 0, 0, true) end ) function Vender ( player ) if(isElementWithinMarker(player,marker2)) then local playerTeam = getPlayerTeam ( player ) if ( playerTeam ) then givePlayerMoney ( player, 1000000 ) setRadarAreaColor ( radararea2, 255, 255, 255, 155 ) outputChatBox ( "#FFF000 [bASE] #FF0000 Sua gang vendeu a base #00ff00 Area 51!", player, 0, 0, 0, true ) end end end addCommandHandler ( "vender", Vender ) function Car_Color ( player ) if(isElementWithinMarker(player,marker2)) then local playerTeam = getPlayerTeam ( player ) if ( playerTeam ) then local r, g, b = getTeamColor ( playerTeam ) setVehicleColor( Maverick, r, g, b ) end end end addCommandHandler ( "comprar51", Car_Color ) [2014-01-27 20:47:44] SCRIPT ERROR: Bases\Area51.lua:28: unexpected symbol near ')' [2014-01-27 20:47:44] ERROR: Loading script failed: Bases\Area51.lua:28: unexpected symbol near ')'
  8. xeon17

    Bug

    I tryed it alerdy and has again bug .. radararea2 = createRadarArea( 110.91990, 1800.89435, 200, 145, 255, 255, 255, 225 ) createBlip(279.40317, 1831.25439, 7.72656,62) marker2 = createMarker(298.98865, 1815.90613, 3.71094,"cylinder",2,0,0,255,255) Maverick = createVehicle ( 487, 251.64256286621,1920.413574218817,640630722046 ) addCommandHandler ( "comprar51", function ( player ) local playerTeam = getPlayerTeam ( player ) if ( playerTeam ) then local r, g, b = getTeamColor ( playerTeam ) if(isElementWithinMarker(player,marker2)) then local money = getPlayerMoney ( player ) if ( money >= 1000000 ) then takePlayerMoney ( player, 1000000 ) else outputChatBox ( "#FFF000 [bASE] #FF0000 Voce não possui dinheiro suficiente para comprar a Base", player, 0, 0, 0, true ) end else outputChatBox ( "#FFF000 [bASE] #FF0000 Você não esta em uma checkpoint", player, 0, 0, 0, true ) setRadarAreaColor ( radararea2, r, g, b, 155 ) local color = getTeamColor ( playerTeam ) outputChatBox ( "#FFF000 [bASE] #FF0000 Sua gang comprou a base #00FF00 Area 51!", player, 0, 0, 0, true ) end end end end ) addEventHandler("onMarkerHit", marker2, function (player) outputChatBox ( "#FFF000 [bASE] #FF0000 Para comprar a base digita #00FF00 /comprar51 (1000000$)", player, 0, 0, 0, true) end ) function Vender ( player ) if(isElementWithinMarker(player,marker2)) then local playerTeam = getPlayerTeam ( player ) if ( playerTeam ) then givePlayerMoney ( player, 1000000 ) setRadarAreaColor ( radararea2, 255, 255, 255, 155 ) outputChatBox ( "#FFF000 [bASE] #FF0000 Sua gang vendeu a base #00ff00 Area 51!", player, 0, 0, 0, true ) end end end addCommandHandler ( "vender", Vender ) function Car_Color ( player ) if(isElementWithinMarker(player,marker2)) then local playerTeam = getPlayerTeam ( player ) if ( playerTeam ) then local r, g, b = getTeamColor ( playerTeam ) setVehicleColor( Maverick, r, g, b ) end end end addCommandHandler ( "comprar51", Car_Color ) This is the full script , [2014-01-27 20:23:08] SCRIPT ERROR: Bases\Area51.lua:29: ')' expected (to close '(' at line 9) near 'end' [2014-01-27 20:23:08] ERROR: Loading script failed: Bases\Area51.lua:29: ')' expected (to close '(' at line 9) near 'end'
  9. xeon17

    Bug

    I changed something, can someone tell is is the ''else outchatbox correct becouse is my frist time i use this function . the changed code : radararea2 = createRadarArea( 110.91990, 1800.89435, 200, 145, 255, 255, 255, 225 ) createBlip(279.40317, 1831.25439, 7.72656,62) marker2 = createMarker(298.98865, 1815.90613, 3.71094,"cylinder",2,0,0,255,255) Maverick = createVehicle ( 487, 251.64256286621,1920.413574218817,640630722046 ) addCommandHandler ( "comprar51", function ( player ) local playerTeam = getPlayerTeam ( player ) if ( playerTeam ) then local r, g, b = getTeamColor ( playerTeam ) if(isElementWithinMarker(player,marker2)) then local money = getPlayerMoney ( player ) if ( money >= 1000000 ) then takePlayerMoney ( player, 1000000 ) else outputChatBox ( "#FFF000 [bASE] #FF0000 Voce não possui dinheiro suficiente para comprar a Base", player, 0, 0, 0, true ) end else outputChatBox ( "#FFF000 [bASE] #FF0000 Você não esta em uma checkpoint", player, 0, 0, 0, true ) setRadarAreaColor ( radararea2, r, g, b, 155 ) local color = getTeamColor ( playerTeam ) outputChatBox ( "#FFF000 [bASE] #FF0000 Sua gang comprou a base #00FF00 Area 51!", player, 0, 0, 0, true ) end end end ) end end [2014-01-27 18:49:23] SCRIPT ERROR: Bases\Area51.lua:30: '' expected near 'end' [2014-01-27 18:49:23] ERROR: Loading script failed: Bases\Area51.lua:30: '' expected near 'end'
  10. xeon17

    Bug

    radararea2 = createRadarArea( 110.91990, 1800.89435, 200, 145, 255, 255, 255, 225 ) createBlip(279.40317, 1831.25439, 7.72656,62) marker2 = createMarker(298.98865, 1815.90613, 3.71094,"cylinder",2,0,0,255,255) Maverick = createVehicle ( 487, 251.64256286621,1920.413574218817,640630722046 ) addCommandHandler ( "comprar51", function ( player ) local playerTeam = getPlayerTeam ( player ) if ( playerTeam ) then local r, g, b = getTeamColor ( playerTeam ) if(isElementWithinMarker(player,marker2)) then local money = getPlayerMoney ( player ) if ( money >= 1000000 ) then takePlayerMoney ( player, 1000000 ) else end outputChatBox ( "#FFF000 [bASE] #FF0000 Voce não possui dinheiro suficiente para comprar a Base", player, 0, 0, 0, true ) else outputChatBox ( "#FFF000 [bASE] #FF0000 Você não esta em uma checkpoint", player, 0, 0, 0, true ) setRadarAreaColor ( radararea2, r, g, b, 155 ) local color = getTeamColor ( playerTeam ) outputChatBox ( "#FFF000 [bASE] #FF0000 Sua gang comprou a base #00FF00 Area 51!", player, 0, 0, 0, true ) end end end end ) [2014-01-27 18:33:28] SCRIPT ERROR: Bases\Area51.lua:29: ')' expected (to close '(' at line 9) near 'end' [2014-01-27 18:33:28] ERROR: Loading script failed: Bases\Area51.lua:29: ')' expected (to close '(' at line 9) near 'end'
  11. xeon17

    Question

    always i make a mistake with source or player hahahha thanks TAPL
  12. xeon17

    Question

    House = createPickup (2087.9260253906, 1448.8768310547, 9.8203125, 4, 1273 ) addEventHandler("onPlayerPickupHit", House, function (thePlayer) outputChatBox ( "#00FFFF [PROP] Para comprar a propriedade digita #00FF00 /prop1 (10000$)", thePlayer, 255, 255, 255, true) function Buy ( thePlayer ) local money = getPlayerMoney(thePlayer) if (money >= 10000) then takePlayerMoney(thePlayer, 10000) outputChatBox ( "#00FFFF [PROP] Voce comprou a propridade", thePlayer, 255, 255, 255, true) else outputChatBox ( "#00FFFF [PROP] Voce não possui dinheiro suficiente para comprar a propriedade", thePlayer, 255, 255, 255, true) end else outputChatBox("#00FFFF [PROP] Você não esta em uma propriedade", thePlayer, 255, 255, 255, true) end end addCommandHandler("prop1", buyProp) is the onPlayerPickupHit correct ?
  13. xeon17

    Question

    I got +1 question , is there a function like isElementwithPickup something like is ElementwithinMarker , i created before a script busniess with markers , i seen on 1 server it work with pickups. but how
  14. xeon17

    Bug :O

    Thanks you , it works !
  15. xeon17

    Bug :O

    i got a bug in my script , help idk how to fix it radararea2 = createRadarArea( 110.91990, 1800.89435, 200, 145, 255, 255, 255, 225 ) createBlip(279.40317, 1831.25439, 7.72656,62) marker2 = createMarker(298.98865, 1815.90613, 3.71094,"cylinder",2,0,0,255,255) Maverick = createVehicle ( 487, 251.64256286621,1920.413574218817,640630722046 ) addCommandHandler ( "comprar51", function ( player ) local playerTeam = getPlayerTeam ( player ) if ( playerTeam ) then local r, g, b = getTeamColor ( playerTeam ) if(isElementWithinMarker(player,marker2)) then setRadarAreaColor ( radararea2, r, g, b, 155 ) local money = getPlayerMoney ( player ) if ( money >= 1000000 ) then takePlayerMoney ( player, 1000000 ) local color = getTeamColor ( playerTeam ) outputChatBox ( "#FFF000 [bASE] #FF0000 Sua gang comprou a base #00FF00 Area 51!", player, 0, 0, 0, true ) end end end end ) addEventHandler("onMarkerHit", marker2, function (player) outputChatBox ( "#FFF000 [bASE] #FF0000 Para comprar a base digita #00FF00 /comprar51 (1000000$)", player, 0, 0, 0, true) end ) function Vender ( player ) if(isElementWithinMarker(player,marker2)) then local playerTeam = getPlayerTeam ( player ) if ( playerTeam ) then givePlayerMoney ( player, 1000000 ) setRadarAreaColor ( radararea2, 255, 255, 255, 155 ) outputChatBox ( "#FFF000 [bASE] #FF0000 Sua gang vendeu a base #00ff00 Area 51!", player, 0, 0, 0, true ) end end end addCommandHandler ( "vender", Vender ) function Car Color ( player ) if(isElementWithinMarker(player,marker2)) then local playerTeam = getPlayerTeam ( player ) if ( playerTeam ) then local r, g, b = getTeamColor ( playerTeam ) setVehicleColor( Maverick, r, g, b ) end end end addCommandHandler ( "comprar51", Car Color ) Bug : [2014-01-27 15:17:02] SCRIPT ERROR: Bases\Area51.lua:44: '(' expected near 'Color' [2014-01-27 15:17:02] ERROR: Loading script failed: Bases\Area51.lua:44: '(' expected near 'Color'
  16. xeon17

    Question

    Thank you guys going to crate a nice script
  17. xeon17

    Question

    I have a question is there a function onPickuphit ? like onMarkerhit or a event handler.
  18. xeon17

    Health Radar

    He ask where he can download the resource , no to make one ?
  19. xeon17

    Help ME!

    Set off the PlayerColors resource.
  20. xeon17

    Question

    function Check ( source ) local playerTeam = getPlayerTeam ( source ) if ( playerTeam ) then outputChatBox ( "#F4A460[GANG]#F08080 Bem vido a gang " .. getTeamName ( "PlayerTeam" ).." ! ", source, 255, 255, 255, true ) end end addEventHandler ( "onPlayerLogin", root, Check ) no work
  21. xeon17

    Problem

    function Check ( player ) local playerTeam = getPlayerTeam ( player ) if ( playerTeam ) then outputChatBox ( "#F4A460[GANG]#F08080 Bem vido a gang " .. getTeamFromName ( PlayerTeam ).." ! ", player, 255, 255, 255, true ) end end addEventHandler ( "onPlayerLogin", root, Check ) Nothing happens
  22. xeon17

    Question

    I know calm , i not started working yet i thank later i got a problem with my other script what i crated before 2 minutes , when player join server if he have team it should give him outchatbox '-' but nothing happen function Check ( player ) local playerTeam = getPlayerTeam ( player ) if ( playerTeam ) then outputChatBox ( "#F4A460[GANG]#F08080 Bem vido a gang " .. getTeamFromName ( PlayerTeam ).." ! ", player, 255, 255, 255, true ) end end addEventHandler ( "onPlayerLogin", root, Check ) i Tryed OnPlayerLogin too , idk what wrong , help TAPL
  23. xeon17

    Question

    Ahh Sorry , there was writed an author i copyed only the script. local gate = createObject(id, x, y, z, rx, ry, rz) local marker = createMarker(x, y, z, "cylinder", 2, 0, 200, 255) function openGate (hitPlayer, matchingDimension) moveObject(gate, x, y, z) end addEventHandler("onClientMarkerHit", marker, openGate) function closeGate(leavingPlayer, matchingDimension) moveObject(gate, x, y, z) end addEventHandler("onClientMarkerLeave", marker, closeGate) Now i get this bugs , wtf [2014-01-25 12:47:50] Resource 'Gate' changed, reloading and starting [2014-01-25 12:47:50] Starting Gate [2014-01-25 12:47:50] WARNING: Gate\Garagem.lua:1: Bad argument @ 'createObject' [Expected number at argument 1, got nil] [2014-01-25 12:47:50] WARNING: Gate\Garagem.lua:2: Bad argument @ 'createMarker' [2014-01-25 12:47:50] WARNING: Gate\Garagem.lua:6: Bad argument @ 'addEventHandler' [Expected element at argument 2, got boolean] [2014-01-25 12:47:50] WARNING: Gate\Garagem.lua:11: Bad argument @ 'addEventHandler' [Expected element at argument 2, got boolean] [2014-01-25 12:47:50] Gate restarted successfully
  24. xeon17

    Question

    [2014-01-25 12:35:28] SCRIPT ERROR: Gate\Garagem.lua:17: unfinished long comment near ''
×
×
  • Create New...