Jump to content

Castillo

Retired Staff
  • Posts

    21,935
  • Joined

  • Last visited

  • Days Won

    6

Everything posted by Castillo

  1. Castillo

    MySQL

    Well, it means that the MySQL handler is invalid.
  2. You must make a table to store all vehicles. local vehMarker = createMarker ( 312, 1824, 18, "cylinder", 1.5, 0, 0, 255, 150 ) local vehicles = { } function spawnVehicleServer ( thePlayer ) if ( isElement ( vehicles [ thePlayer ] ) ) then destroyElement ( vehicles [ thePlayer ] ) end local x, y, z = getElementPosition ( thePlayer ) vehicles [ thePlayer ] = createVehicle ( 525, x + 5, y, z ) if ( vehicles [ thePlayer ] ) then warpPedIntoVehicle ( thePlayer, vehicles [ thePlayer ] ) outputChatBox ( "Fahrzeug erfolgreich gespawnt", thePlayer, 0, 153, 0, true ) else outputChatBox ( "Fahrzeugspawn fehlgeschlagen, kontaktiere den Scripter/Hoster!", thePlayer, 190, 160, 50 ) end end addEventHandler ( "onMarkerHit", vehMarker, spawnVehicleServer )
  3. local vehMarker = createMarker ( 312, 1824, 18, "cylinder", 1.5, 0, 0, 255, 150 ) function spawnVehicleServer ( thePlayer ) local x, y, z = getElementPosition ( thePlayer ) local myVeh = createVehicle ( 525, x + 5, y, z ) if ( myVeh ) then warpPedIntoVehicle ( thePlayer, myVeh ) outputChatBox ( "Fahrzeug erfolgreich gespawnt", thePlayer, 0, 153, 0, true ) else outputChatBox ( "Fahrzeugspawn fehlgeschlagen, kontaktiere den Scripter/Hoster!", thePlayer, 190, 160, 50 ) end end addEventHandler ( "onMarkerHit", vehMarker, spawnVehicleServer ) That'll spawn the vehicle when a player hits the marker.
  4. Can you post your complete script?
  5. local vehMarker = createMarker ( 312, 1824, 18, "cylinder", 1.5, 0, 0, 255, 150 ) addEventHandler ( "onMarkerHit", vehMarker, openVehicleSpawnServer ) function spawnVehicleServer ( ) local x,y,z = getElementPosition(source) local myVeh = createVehicle(525,x+5,y,z) if myVeh then warpPedIntoVehicle(source,myVeh) outputChatBox("Fahrzeug erfolgreich gespawnt",source,0,153,0,true) else outputChatBox("Fahrzeugspawn fehlgeschlagen, kontaktiere den Scripter/Hoster!",source,190,160,050) end end addEvent ("SpawnVehicleServer",true) addEventHandler ("SpawnVehicleServer",root,spawnVehicleServer) P.S: You have the function: "openVehicleSpawnServer", right?
  6. Well, you are attaching the element: "vehMark" to the "onMarkerHit" event, but your element is "vehMarker".
  7. local vehMarker = createMarker( 312, 1824, 18, "Cylinder", 1.5, 0, 0, 255, 150) addEventHandler ( "onMarkerHit", vehMark, openVehicleSpawnServer ) function spawnVehicleServer ( ) local x,y,z = getElementPosition(source) local myVeh = createVehicle(525,x+5,y,z) if myVeh then warpPedIntoVehicle(source,myVeh) outputChatBox("Fahrzeug erfolgreich gespawnt",source,0,153,0,true) else outputChatBox("Fahrzeugspawn fehlgeschlagen, kontaktiere den Scripter/Hoster!",source,190,160,050) end end addEvent ("SpawnVehicleServer",true) addEventHandler ("SpawnVehicleServer",root,spawnVehicleServer) You forgot to create the function: function spawnVehicleServer ( )
  8. You don't have "thePlayer" defined anywhere.
  9. He has it on meta, not the file is not on the resource.
  10. That means you got missing "skin1.txd" file.
  11. Castillo

    Admin Panel Problem

    That means that your "acl.xml" is messed up.
  12. local skins = {{fileName="skin1", skinID=9}} function load() for index, skin in pairs(skins) do engineImportTXD(engineLoadTXD ( skin.fileName ..".txd" ), tonumber(skin.skinID)) engineReplaceModel(engineLoadDFF ( skin.fileName ..".dff", 0 ), tonumber(skin.skinID)) end end addEventHandler("onClientResourceStart",resourceRoot, function () local version = getVersion() if string.find(version.mta, "1.1.1") then setTimer ( load, 1000, 1) end end) You had missing '}' at this line: local skins = {{fileName="skin1", skinID=9}}
  13. You must use the function: isObjectInACLGroup with the event: onPlayerLogin.
  14. I'm not here to make things for you, I'm here to help you fix your problems.
  15. Next time upload it to some other site, that one requests for register. @Back on topic: You can use the function: getTeamFromName to get a team from it's name, and this function: setPlayerTeam to set a player team.
  16. Post your script here.
  17. function addPickup ( thePlayer, command, ... ) outputChatBox ( table.concat ( { ... }, " " ) ) end addCommandHandler ( "makeclue", addPickup )
  18. I really didn't understand you anything.
  19. Castillo

    Como puedo

    Podes usar: dxDrawImage o guiCreateStaticImage
  20. Because the "zombieProof" element data must be used on the radar areas, not on the colshapes.
  21. addCommandHandler -- Para crear el comando. setElementPosition -- Para "teletransportarlo". giveWeapon -- Para dar el arma.
  22. If you use: getRootElement ( ) instead of resourceRoot it'll execute the function every time a resource starts, not just the one that has the script.
×
×
  • Create New...