Jump to content

Dark Dragon

Members
  • Posts

    1,619
  • Joined

  • Last visited

Everything posted by Dark Dragon

  1. well it's meant to be a competitive pvp gamemode. if you want to change this behaviour i'd say you need to change this within its code
  2. maybe something else is wrong. is your race version up to date?
  3. this is older than the internet itself.
  4. https://community.multitheftauto.com/index.html?p ... ails&id=27 https://community.multitheftauto.com/index.html?p ... ils&id=682 there might be more
  5. why did you change the game and http port to 22126?
  6. it could be a server problem. do others experience the same issue?
  7. are you sure attaching is the thing you want? the use sounds more like you want to freeze the player.
  8. about how many objects are we talking? it should only cause problems if more than 250 objects have to be displayed at once
  9. oh yes, there's an 'end' missing after line 28, also note that the player has to be in a team already if you want them to spawn in the predetermined area for the Mercenaries and the Police
  10. it means it's availability is unlimited. "it will respawn instantly"
  11. Dark Dragon

    help

    try this local theFinishMarker local theFinishBlip local theTruckVehicle local theTruckTrailer function truckerJob ( theTruck ) theTruckVehicle = theTruck theTruckTrailer = source theTruckTrailerID = getElementModel (source) local theDriver = getVehicleOccupant ( theTruck, 0 ) if ( theDriver ) and ( theTruckTrailerID == 450 ) then outputChatBox ("Bring the trailer to the flag.", theDriver, 255, 0, 0, false) theFinishMarker = createMarker ( -771.58, -119.03, 63.34, "cylinder", 16, 0, 255, 0, 90, theDriver ) theFinishBlip = createBlip ( -771.58, -119.03, 63.34, 53, 2, 255, 0, 0, 255, 0, 99999.0, theDriver ) end addEventHandler ("onMarkerHit", theFinishMarker, truckerJobMarkerHit) end -- end the function her function truckerJobMarkerHit ( hitPlayer, matchingDimension ) givePlayerMoney ( hitPlayer, 150 ) destroyElement ( theFinishMarker ) destroyElement ( theFinishBlip ) respawnVehicle ( theTruckTrailer ) outputChatBox ( "Mission Passed, you earn $150", hitPlayer, 255, 0, 0, false ) end -- here is where you ended the first function, but that's probably not what you want addEventHandler("onTrailerAttach", getRootElement(), truckerJob) function truckerJobFailed ( theTruck ) removeEventHandler ("onMarkerHit", theFinishMarker, truckerJobMarkerHit) local theDriver = getVehicleOccupant ( theTruck, 0 ) respawnVehicle ( theTruckTrailer ) destroyElement ( theFinishMarker ) destroyElement ( theFinishBlip ) outputChatBox ( "Mission Failed!", theDriver, 255, 0, 0, false ) end addEventHandler("onTrailerDetach", getRootElement(), truckerJobFailed)
  12. addEventHandler("onResourceStart", resourceRoot, function() for i,player in ipairs(getElementsByType("player")) do spawn(player) end end ) function spawn(player) -- not sure where you want to get source, key, and TeamName from, you use spawn(player), therefore the first argument will be the only valid one, as you don't use any of those anyways i'd just remove them local playerTeam = getPlayerTeam ( player ) -- player instead of source here if ( getTeamName(playerTeam) == "Mercenaries" ) then -- remember that a team element is not the same as the teams name spawnPlayer ( player, 2824.647+math.random(-0,5), -2438.673+math.random(-0,5), 13, 90, 179 ) giveWeapon(player,23,51) fadeCamera(player, true) setCameraTarget(player, player) else spawnPlayer ( player, 1000+math.random(-0,5), 1000+math.random(-0,5), 13, 90, 177 ) fadeCamera(player, true) setCameraTarget(player, player) end end addEventHandler("onPlayerJoin", root, function() spawn(source) end ) addEventHandler("onPlayerWasted", root, function() setTimer(spawn, 5000, 1, source) end )
  13. Dark Dragon

    time

    milliseconds / 1000 = seconds (1 second has 1000 milliseconds) milliseconds /60000 = minutes (1 minute has 60 seconds) etc.
  14. you can trigger a server event in the client-side onClientResourceStart event, as it's fired when the client finished downloading and started the resource. implementing shoutcasts will be possible in version 1.1, as it uses a more powerful sound library called BASS. being able to transfer files with script functions is something to discuss about.
  15. Dark Dragon

    help

    you messed up with ending the functions. your first function has to end in line 27 not 36 then you use some global variables where local variables would be enough, for example theTruckVehicle which you don't use anywhere. next i saved you some work by putting the event handler for the marker hit within your first function and i also attached the event to your finishing marker only to save you the "if source == theFinishMarker" oh and you forgot to remove the BB code from the script when you put it into the [lua] tags function truckerJob ( theTruck ) theTruckVehicle = theTruck theTruckTrailer = source theTruckTrailerID = getElementModel (source) local theDriver = getVehicleOccupant ( theTruck, 0 ) if ( theDriver ) and ( theTruckTrailerID == 584 ) then outputChatBox ("Bring the trailer to the flag.", theDriver, 0, 255, 111, false) theFinishMarker = createMarker ( -1605.90, -2713.98, 46.53, "cylinder", 16, 0, 255, 0, 90, theDriver ) theFinishBlip = createBlip ( -1605.90, -2713.98, 46.53, 53, 2, 255, 0, 0, 255, 0, 99999.0, theDriver ) end if ( theDriver ) and ( theTruckTrailerID == 435 ) then outputChatBox ("Bring the trailer to the flag.", theDriver, 255, 0, 0, false) theFinishMarker = createMarker ( -480.59, -514.02, 23.51, "cylinder", 16, 0, 255, 0, 90, theDriver ) theFinishBlip = createBlip ( -480.59, -514.02, 23.51, 53, 2, 255, 0, 0, 255, 0, 99999.0, theDriver ) end if ( theDriver ) and ( theTruckTrailerID == 450 ) then outputChatBox ("Bring the trailer to the flag.", theDriver, 255, 0, 0, false) theFinishMarker = createMarker ( -771.58, -119.03, 63.34, "cylinder", 16, 0, 255, 0, 90, theDriver ) theFinishBlip = createBlip ( -771.58, -119.03, 63.34, 53, 2, 255, 0, 0, 255, 0, 99999.0, theDriver ) end if ( theDriver ) and ( theTruckTrailerID == 591 ) then outputChatBox ("Bring the trailer to the flag.", theDriver, 255, 0, 0, false) theFinishMarker = createMarker ( 344.08, 873.30, 18.40, "cylinder", 16, 0, 255, 0, 90, theDriver ) theFinishBlip = createBlip ( 344.08, 873.30, 18.40, 53, 2, 255, 0, 0, 255, 0, 99999.0, theDriver ) end addEventHandler ("onMarkerHit", theFinishMarker, truckerJobMarkerHit) -- attaching the event to our finish marker only instead of all elements end -- end the function here function truckerJobMarkerHit ( hitPlayer, matchingDimension ) givePlayerMoney ( hitPlayer, 150 ) destroyElement ( theFinishMarker ) destroyElement ( theFinishBlip ) respawnVehicle ( theTruckTrailer ) outputChatBox ( "Mission Passed, you earn $150", hitPlayer, 255, 0, 0, false ) end -- here is where you ended the first function, but that's probably not what you want addEventHandler("onTrailerAttach", getRootElement(), truckerJob) function truckerJobFailed ( theTruck ) removeEventHandler ("onMarkerHit", theFinishMarker, truckerJobMarkerHit) local theDriver = getVehicleOccupant ( theTruck, 0 ) respawnVehicle ( theTruckTrailer ) destroyElement ( theFinishMarker ) destroyElement ( theFinishBlip ) outputChatBox ( "Mission Failed!", theDriver, 255, 0, 0, false ) end addEventHandler("onTrailerDetach", getRootElement(), truckerJobFailed) the rest looks good
  16. Sorry we do not support this way to obtain scripts. Closed
  17. 011010010010000001110010011001010110000101101100011011000111100100100000011001000 110111101101110001001110111010000100000011001110110010101110100001000000111011101 101000011110010010000001110000011001010110111101110000011011000110010100100000011 010110110010101100101011100000010000001110000011011110111001101110100011010010110 111001100111001000000110100101101110001000000111010001101000011010010111001100100 000011100110111010001110101011100000110100101100100001000000111010001101111011100 000110100101100011001011100010000001101001001000000110110101100101011000010110111 000100000011010010010000001100100011010010110010001101110001001110111010000100000 011001010110111001100011011011110110010001100101001000000110000101101110011110010 010000001101111011001100010000001110100011010000110010100100000011011010110010101 110011011100110110000101100111011001010111001100100000011110010110111101110101001 000000111001101100101011011100111010000100000011000010110111001100100001000000111 010001101000011010010111001100100000011010010111001100100000011101000110100001100 101001000000110011001101001011100100111001101110100001000000110000101101110011001 000010000001101100011000010111001101110100001000000111010001101001011011010110010 100100000011010010010000001110111011010010110110001101100001000000111010101110011 011001010010000001110100011010010110110101100101001000000111010001101111001000000 110010101101110011000110110111101100100011001010010000001110100011010000110100101 110011001000000110100101101110011101000110111100100000011000100110100101101110011 000010111001001111001001011100010000001100111011011110110111101100100001000000110 010001100001011110010010000001110011011010010111001000101110
  18. are you searching for a specific wall or roof? try the editors object browser, it includes categories and a search feature, it should be able to help you out.
  19. I updated the link for those who care. Thanks for your interest.
  20. Why would you want that? There is an entire column for the map in the server browser.
  21. I think it's still unclear what you're asking for. Where do you want the map name to be displayed? Should it be displayed all the time?
  22. basically all you need is inserting players into a table and in the end of a map select a random one. local playertable = {} function playLottery(player) takePlayerMoney(player,100) table.insert(playertable,player) end addCommandHandler("lottery",playLottery) function chooseWinner() local winner = playertable[math.random(1,#playertable)] givePlayerMoney(winner,1000) playertable = {} end of course you have to call that second function at some point
  23. you need to use the access control list. you can learn more about it here: https://wiki.multitheftauto.com/wiki/ACL basically all you need to do is check if the account someone is logged on is in the admin acl group. example #2 here shows you some acl usage: https://wiki.multitheftauto.com/wiki/AclGetGroup
  24. Dark Dragon

    Server Help ?

    you need to forward port 22126 in order to get the server in the internet tab of the server browser. once you've done that all you need to do is turn on your server and keep it running for a few hours.
  25. a server can't modify them, you probably just found a server allowing modified files. you can get the original data files here: https://community.multitheftauto.com/data.zip just unzip them in Rockstar Games\Grand Theft Auto San Andreas\data overwriting the existing files. Edit: corrected link
×
×
  • Create New...