• 21 Avril 2019, 15:01:56


Auteur Sujet: Tutorial 8a: Ion Cannon  (Lu 6155 fois)

0 Membres et 1 Invité sur ce sujet

Hors ligne spykerc8

  • *
  • 'The GTAOnline.fr GodFather'
  • Messages: 3821
    • Voir le profil
    • http://www.gtaonline.fr
Tutorial 8a: Ion Cannon
« le: 30 Mars 2007, 19:16:55 »
[yt=425,350]xD4pHYISHRM[/yt]

Lien du script : http://mtasa.com/scripts/script8a.ion.lua
Vidéo HD :

Définir les variables et préparer le script.

Code: Lua
  1. root = getRootElement ()
  2. players = {}
  3.  
  4. outputChatBox ( "Ion cannon by Ransom" )
  5. ion_rotx = 0
  6. ion_loops = 0
  7. ion_explosionTimer = 0
  8. ion_cannonActivated = false
  9. ion_cancelActivation = false
  10. ion_beamSize = 5
  11. ion_beamFlareSize = 5
  12. players = getElementsByType ( "player" )
  13.  

Donne accès à tous les joueurs sur le serveur.

Code: Lua
  1. addEventHandler ( "onResourceStart", root, "ResourceStartIonCannon" )
  2. function ResourceStartIonCannon ( name, root )
  3. if name ~= getThisResource() then return end
  4.         for k,v in players do
  5.         -- for all players in the "players" array
  6.         bindKey ( v, "f", "down", "placeIonCannonBeacon" )
  7.         -- bind the key f for triggering the ion cannon
  8.         end
  9. end
  10.  
  11. addEventHandler ( "onPlayerJoin", root, "ionPlayerJoin" )
  12. function ionPlayerJoin ()
  13.         bindKey ( source, "f", "down", "placeIonCannonBeacon" )
  14.         --if a player joins after the resource loaded, bind their f key to trigger the ion cannon also
  15. end

Partie du script pour utiliser le canon quand la touche 'f' est utilisée, affiche le curseur de la sourie.

Code: Lua
  1. function placeIonCannonBeacon ( player, key, state )
  2.         if ( ion_cannonActivated == false ) and ( ion_cancelActivation == false ) and ( nuke_cancelActivation == false )
  3.         and ( nuke_cannonActivated == false ) then
  4.     --These conditions prevent triggering the same weapon twice or triggering the other weapon at the same time.
  5.         --Both weapons cannot be triggered because explosions are stretched to the limit, explosions would be random
  6.         defineLaunchType = key
  7.         --This is used later on the onPlayerClick function to tell it what weapon to launch
  8.         showCursor ( player, true )
  9.         ion_cancelActivation = true
  10.         else
  11.                 if ion_cancelActivation == true then
  12.                 showCursor ( player, false )
  13.                 end
  14.                 --Prevents cursor from getting messed up if cursor is show for f or g and the opposite key is hit
  15.         ion_cancelActivation = false
  16.         --ion_cancelactivation is true when the cursor is showing. This is necessary along with asking if the actual
  17.         --weapon is active to prevent problems with the cursor and weapon activation between both weapons and themselves
  18.                       if ion_cannonActivated == true then
  19.             outputChatBox ( "Ion cannon has already been activated", activator )
  20.             else
  21.             outputChatBox ( "Cannot activate ion cannon and nuke at the same time", activator )
  22.             end
  23.             --This statement says that if the ion cannon is already in use, display a meassage about it being in
  24.                         --use on f press. Else, if the above conditions were not satisifed and the nuke is not active, it meant
  25.                         --the ion cannon was active. Therefore, display the other message that both weapons cannot be used at
  26.                         --the same time.
  27.         end
  28. end


Quand le joueur click avec la souris

Code: Lua
  1. addEventHandler ( "onPlayerClick", root, "playerClick" )
  2. function playerClick ( button, state, clickedElement, x, y, z )
  3.         if defineLaunchType == "f" then
  4.         --If the player clicked, we check if the key is equal to f or g. This will dictate which onPlayerClick function
  5.         --commences between the ion cannon and nuke scripts
  6.         ion_cancelActivation = false
  7.         --Since the weapon is now in use, you have no chance to abort by pressing the key again, therefore this is false
  8.         defineLaunchType = nil
  9.     --This must be reset to nil so it will not fire the ion cannon next time on click if g was pressed instead of f
  10.         --(which triggers nuke)
  11.         ion_beaconx = x
  12.         ion_beacony = y
  13.         ion_beaconz = z
  14.         --Set the ion cannon beacon (detonation spot) coordinates to the spot the mouse cursor clicked on the game map
  15.         local playerz, playerz, playerz = getElementPosition ( source )
  16.     --For the above line, getElementPosition outputs 3 varibles, but I only want z so I overwrote 1 varible called
  17.         --playerz as the function went through and assigned the XYZ values to varible x, varible y, and varible z
  18.         --respectively.
  19.                         if ( button == "left" ) and ( state == "down" ) and ( ion_cannonActivated == false ) then
  20.             --When the left mouse button is pressed down (not when released), if ion cannon is not active then
  21.                         ion_cannonActivated = true
  22.             --Set this varible to true, which will be used to avoid double launches & double weapon usage
  23.                         showCursor ( source, false )
  24.             --Weapon beacon was chosen and the launch is initiating to that point. Hide cursor.
  25.                         ionBeam = createMarker ( ion_beaconx, ion_beacony, ion_beaconz, "checkpoint", 5, 255, 255, 255, 255 )
  26.                         ionBeam2 = createMarker ( ion_beaconx, ion_beacony, ion_beaconz, "checkpoint", 5, 255, 255, 255, 255 )
  27.                         ionBeam3 = createMarker ( ion_beaconx, ion_beacony, ion_beaconz, "checkpoint", 5, 255, 255, 255, 255 )
  28.                         ionSecondaryBeam = createMarker ( ion_beaconx, ion_beacony, ion_beaconz, "checkpoint", 5, 255, 255,
  29.                         255, 255 )
  30.                         ionSecondaryBeam2 = createMarker ( ion_beaconx, ion_beacony, ion_beaconz, "checkpoint", 5, 255, 255,
  31.                         255, 255 )
  32.                         ionSecondaryBeam3 = createMarker ( ion_beaconx, ion_beacony, ion_beaconz, "checkpoint", 5, 255, 255,
  33.                         255, 255 )
  34.                         ionBeamFlare = createMarker ( ion_beaconx, ion_beacony, ion_beaconz, "corona", 5, 255, 255, 255, 255 )
  35.                         --create six markers at the beacon point. The marker checkpoint will extend into the sky, but will end
  36.                         --at the given z. 6 markers are used to ensure the beam looks full as I rapidly delete and recreate the
  37.                         --markers in the next functions.
  38.                         setTimer ( "ionExplosion", 50, 1 )    
  39.                         setTimer ( "ionShot", 100, 20 )
  40.                         setTimer ( "ionShot2", 150, 20 )
  41.                         --Trigger the functions that will create the ion cannon shot and explosion imitation. 50ms 1 time, 100ms
  42.                         --20 times, and 150ms 20 times respectively.
  43.                         else
  44.                         ion_activator = getPlayerFromNick ( source )
  45.                         showCursor ( source, false )
  46.                         --Makes sure the cursor will not show again for detonation unless the ion cannon is not active.
  47.                         --Activator is used to display output messages in the other functions that activations/launches
  48.                         --arent possible.
  49.                         end
  50.         end
  51. end
  52.  

Crée l'illusion visuelle d'un faisceau lumineux venant du ciel.

Code: Lua
  1. function ionShot ()
  2.         ion_beamSize = ion_beamSize + 1
  3.         setMarkerSize ( ionBeam, ion_beamSize )
  4.         setMarkerSize ( ionBeam2, ion_beamSize )
  5.         setMarkerSize ( ionBeam3, ion_beamSize )
  6.         if ( ion_beamSize == 6 ) then
  7.         setTimer ( "ionShotFlare", 3, 150 )
  8.         end
  9.         --The first 3 markers making the ion beam are gradually increased at +10 in 1 second. When the function has
  10.         --looped 6 times (6/10 of a second), the flare (again, its a corona marker but I call it a flare) grow
  11.         --function is triggered.
  12. end
  13.  
  14. function ionShot2 ()
  15.         setMarkerSize ( ionSecondaryBeam, ion_beamSize )
  16.         setMarkerSize ( ionSecondaryBeam2, ion_beamSize )
  17.         setMarkerSize ( ionSecondaryBeam3, ion_beamSize )
  18.         --These beams increase at a different rate, since beamSize is changing more rapidly in the ionShot function.
  19.         --They stay a little smaller than the main 3 markers and assist the "grow" look while keeping the beam visible
  20.         --while the markers change size.
  21. end
  22.  
  23. function ionShotFlare ()
  24.         ion_beamFlareSize = ion_beamFlareSize + 1
  25.     setMarkerSize ( ionBeamFlare, ion_beamFlareSize )
  26.     --Every 3ms for 150 loops, the flare size increases. This makes a large glow that appears to be caused by the
  27.         --beam's light
  28. end
  29.  
  30. function ionExplosion ()
  31.         if ion_explosionTimer == 0 then
  32.         --We set this value when the script started. I do so I can keep looping through this function without
  33.         --resetting it.
  34.         setTimer ( "ionExplosion", 170, 18 )
  35.         --Trigger this function to initiate 18 times in 170ms intervals.
  36.         ion_explosionTimer = 1
  37.         --Set the explosion timer flag to 1 so it is not done again with the looping (could have been true/false)
  38.         else
  39.         r = ion_beamSize --min/max blast radius: 1.5-28
  40.         --r will serve as our explosion radius. For the ion cannon, the explosions coming from the ion cannon
  41.         --will gradually increase distance from the center point in a circular motion, since I defined r as
  42.         --ion_beamSize, which is gradully increasing in size in the ionShot function at the same time.
  43.         angleup = randInt(0, 35999)/100
  44.         --Choose a random angle. A value between 0 and 35999 is divided by 100 because we want
  45.         --to have 2 random decimal places for as well, rather than just a whole integer.
  46.         explosionxcoord = r*math.cos(angleup) + ion_beaconx
  47.         explosionycoord = r*math.sin(angleup) + ion_beacony
  48.         --The x and y coordinates of the explosion will occur at a max radius of r away from the nuke beacon,
  49.         --in a circular shape. This is a fundamental, simple circle geometry formula.
  50.         createExplosion ( explosionxcoord, explosionycoord, ion_beaconz, 7 )
  51.         --An explosion of type 7 is created, which is the tied as the largest with some others it is
  52.         --an aircraft explosion.
  53.         ion_loops = ion_loops + 1
  54.                         if ion_loops == 16 then
  55.                         --on the 16th loop of this function
  56.                     ion_beamFlareSize = 200
  57.                         --This triggers the flare to grow +50 immediately right as the beam is ending to create a little
  58.                         --larger flash, just for effect as the beam is done
  59.                         setTimer ( "ionFlareFade", 5, 200 )
  60.                         --The flarefade function is set to occur 200 times at 5ms to set the flare size to 0 quickly, as
  61.                         --the beam has disappeared
  62.                         elseif ion_loops == 18 then
  63.                         --on the 18th loop of this function
  64.                         ion_explosionTimer = 0
  65.                         --Set the explosion timer to 0 for the next ion cannon launch, since this is the last loop
  66.                         ion_loops = 0
  67.                         --Set to 0 to trigger these events directly above on next ion cannon launch as well
  68.                     ion_beamSize = 5
  69.                     --Set to 0 to trigger the functions properly on the next ion cannon launch
  70.                 destroyElement ( ionBeam )
  71.                 destroyElement ( ionSecondaryBeam )
  72.                 destroyElement ( ionBeam2 )
  73.                 destroyElement ( ionSecondaryBeam2 )
  74.                 destroyElement ( ionBeam3 )
  75.                 destroyElement ( ionSecondaryBeam3 )
  76.                 --Destroy all the created checkpoint marker elements that made the beam
  77.                         end
  78.         end
  79. end
  80.  
  81. function ionFlareFade ()  
  82.             setMarkerSize ( ionBeamFlare, ion_beamFlareSize )
  83.         ion_beamFlareSize = ion_beamFlareSize - 1
  84.                 if ion_beamFlareSize == 0 then
  85.                         destroyElement ( ionBeamFlare )
  86.                         ion_cannonActivated = false
  87.                         ion_beamFlareSize = 5
  88.                 end
  89. --Each time the function loops, the flare gets -1 smaller. When it has a size of 0 and becomes invisible, it needs
  90. --to be deleted for the next ion cannon launch. No elements should stay created as they will pile up and eventually
  91. --crash you or the server. Finally, ion_cannonActivated is false, meaning the ion cannon is inactive and another
  92. --weapon use can be performed.
  93. end
  94.  
  95.  

CODE COMPLET :

Code: Lua
  1. --=====================================================================================================================
  2. --Start defining varibles, including a players array. I defined players array in both scripts incase they are seperated
  3. --=====================================================================================================================
  4. root = getRootElement ()
  5. players = {}
  6.  
  7. outputChatBox ( "Ion cannon by Ransom" )
  8. ion_rotx = 0
  9. ion_loops = 0
  10. ion_explosionTimer = 0
  11. ion_cannonActivated = false
  12. ion_cancelActivation = false
  13. ion_beamSize = 5
  14. ion_beamFlareSize = 5
  15. players = getElementsByType ( "player" )
  16.  
  17. --==============================================================================================================
  18. --Give all players on the server access to the weapons
  19. --==============================================================================================================
  20. addEventHandler ( "onResourceStart", root, "ResourceStartIonCannon" )
  21. function ResourceStartIonCannon ( name, root )
  22. if name ~= getThisResource() then return end
  23.         for k,v in players do
  24.         -- for all players in the "players" array
  25.         bindKey ( v, "f", "down", "placeIonCannonBeacon" )
  26.         -- bind the key f for triggering the ion cannon
  27.         end
  28. end
  29.  
  30. addEventHandler ( "onPlayerJoin", root, "ionPlayerJoin" )
  31. function ionPlayerJoin ()
  32.         bindKey ( source, "f", "down", "placeIonCannonBeacon" )
  33.         --if a player joins after the resource loaded, bind their f key to trigger the ion cannon also
  34. end
  35.  
  36. --==========================================================================================================================
  37. --When the ion cannon key (f) is pressed, show the mouse cursor that will allow the triggering of the onPlayerClick function
  38. --==========================================================================================================================
  39. function placeIonCannonBeacon ( player, key, state )
  40.         if ( ion_cannonActivated == false ) and ( ion_cancelActivation == false ) and ( nuke_cancelActivation == false ) and ( nuke_cannonActivated == false ) then
  41.     --These conditions prevent triggering the same weapon twice or triggering the other weapon at the same time.
  42.         --Both weapons cannot be triggered because explosions are stretched to the limit, explosions would be random
  43.         defineLaunchType = key
  44.         --This is used later on the onPlayerClick function to tell it what weapon to launch
  45.         showCursor ( player, true )
  46.         ion_cancelActivation = true
  47.         else
  48.                 if ion_cancelActivation == true then
  49.                 showCursor ( player, false )
  50.                 end
  51.                 --Prevents cursor from getting messed up if cursor is show for f or g and the opposite key is hit
  52.         ion_cancelActivation = false
  53.         --ion_cancelactivation is true when the cursor is showing. This is necessary along with asking if the actual
  54.         --weapon is active to prevent problems with the cursor and weapon activation between both weapons and themselves.
  55.                         if ion_cannonActivated == true then
  56.                 outputChatBox ( "Ion cannon has already been activated", activator )
  57.                 else
  58.                 outputChatBox ( "Cannot activate ion cannon and nuke at the same time", activator )
  59.                 end
  60.                 --This statement says that if the ion cannon is already in use, display a meassage about it being in use on f press.
  61.                 --Else, if the above conditions were not satisifed and the nuke is not active, it meant the ion cannon was
  62.                 --active. Therefore, display the other message that both weapons cannot be used at the same time.
  63.         end
  64. end
  65.  
  66. --=========================================================================================================================
  67. --When the player clicks the mouse cursor, decide if the ion cannon is supposed to be launched and if so, set up the launch
  68. --=========================================================================================================================
  69. addEventHandler ( "onPlayerClick", root, "playerClick" )
  70. function playerClick ( button, state, clickedElement, x, y, z )
  71.         if defineLaunchType == "f" then
  72.         --If the player clicked, we check if the key is equal to f or g. This will dictate which onPlayerClick function
  73.         --commences between the ion cannon and nuke scripts
  74.         ion_cancelActivation = false
  75.         --Since the weapon is now in use, you have no chance to abort by pressing the key again, therefore this is false
  76.         defineLaunchType = nil
  77.     --This must be reset to nil so it will not fire the ion cannon next time on click if g was pressed instead of f (which triggers nuke)
  78.         ion_beaconx = x
  79.         ion_beacony = y
  80.         ion_beaconz = z
  81.         --Set the ion cannon beacon (detonation spot) coordinates to the spot the mouse cursor clicked on the game map
  82.         local playerz, playerz, playerz = getElementPosition ( source )
  83.     --For the above line, getElementPosition outputs 3 varibles, but I only want z so I overwrote 1 varible called
  84.         --playerz as the function went through and assigned the XYZ values to varible x, varible y, and varible z respectively.
  85.                         if ( button == "left" ) and ( state == "down" ) and ( ion_cannonActivated == false ) then
  86.             --When the left mouse button is pressed down (not when released), if ion cannon is not active then
  87.                         ion_cannonActivated = true
  88.             --Set this varible to true, which will be used to avoid double launches & double weapon usage
  89.                         showCursor ( source, false )
  90.             --Weapon beacon was chosen and the launch is initiating to that point. Hide cursor.
  91.                         ionBeam = createMarker ( ion_beaconx, ion_beacony, ion_beaconz, "checkpoint", 5, 255, 255, 255, 255 )
  92.                         ionBeam2 = createMarker ( ion_beaconx, ion_beacony, ion_beaconz, "checkpoint", 5, 255, 255, 255, 255 )
  93.                         ionBeam3 = createMarker ( ion_beaconx, ion_beacony, ion_beaconz, "checkpoint", 5, 255, 255, 255, 255 )
  94.                         ionSecondaryBeam = createMarker ( ion_beaconx, ion_beacony, ion_beaconz, "checkpoint", 5, 255, 255, 255, 255 )
  95.                         ionSecondaryBeam2 = createMarker ( ion_beaconx, ion_beacony, ion_beaconz, "checkpoint", 5, 255, 255, 255, 255 )
  96.                         ionSecondaryBeam3 = createMarker ( ion_beaconx, ion_beacony, ion_beaconz, "checkpoint", 5, 255, 255, 255, 255 )
  97.                         ionBeamFlare = createMarker ( ion_beaconx, ion_beacony, ion_beaconz, "corona", 5, 255, 255, 255, 255 )  
  98.                         --create six markers at the beacon point. The marker checkpoint will extend into the sky, but will end at
  99.                         --the given z. 6 markers are used to ensure the beam looks full as I rapidly delete and recreate the markers
  100.                         --in the next functions.
  101.                         setTimer ( "ionExplosion", 50, 1 )     
  102.                         setTimer ( "ionShot", 100, 20 )
  103.                         setTimer ( "ionShot2", 150, 20 )
  104.                         --Trigger the functions that will create the ion cannon shot and explosion imitation. 50ms 1 time, 100ms
  105.                         --20 times, and 150ms 20 times respectively.
  106.                         else
  107.                         ion_activator = getPlayerFromNick ( source )
  108.                         showCursor ( source, false )
  109.                         --Makes sure the cursor will not show again for detonation unless the ion cannon is not active. Activator
  110.                         --is used to display output messages in the other functions that activations/launches arent possible.
  111.                         end
  112.         end
  113. end
  114.  
  115. --=============================================================================================================================
  116. --Create the illusion of a beam coming from space and gradually increasing in size (beam strike power)
  117. --=============================================================================================================================
  118. function ionShot ()
  119.         ion_beamSize = ion_beamSize + 1
  120.         setMarkerSize ( ionBeam, ion_beamSize )
  121.         setMarkerSize ( ionBeam2, ion_beamSize )
  122.         setMarkerSize ( ionBeam3, ion_beamSize )
  123.         if ( ion_beamSize == 6 ) then  
  124.         setTimer ( "ionShotFlare", 3, 150 )
  125.         end
  126.         --The first 3 markers making the ion beam are gradually increased at +10 in 1 second. When the function has looped
  127.         --6 times (6/10 of a second), the flare (again, its a corona marker but I call it a flare) grow function is triggered.
  128. end
  129.  
  130. function ionShot2 ()
  131.         setMarkerSize ( ionSecondaryBeam, ion_beamSize )
  132.         setMarkerSize ( ionSecondaryBeam2, ion_beamSize )
  133.         setMarkerSize ( ionSecondaryBeam3, ion_beamSize )
  134.         --These beams increase at a different rate, since beamSize is changing more rapidly in the ionShot function. They stay
  135.         --a little smaller than the main 3 markers and assist the "grow" look while keeping the beam visible while the markers
  136.         --change size.
  137. end
  138.  
  139. function ionShotFlare ()
  140.         ion_beamFlareSize = ion_beamFlareSize + 1
  141.     setMarkerSize ( ionBeamFlare, ion_beamFlareSize )
  142.     --Every 3ms for 150 loops, the flare size increases. This makes a large glow that appears to be caused by the beam's light
  143. end
  144.  
  145. function ionExplosion ()
  146.         if ion_explosionTimer == 0 then
  147.         --We set this value when the script started. I do so I can keep looping through this function without
  148.         --resetting it.
  149.         setTimer ( "ionExplosion", 170, 18 )
  150.         --Trigger this function to initiate 18 times in 170ms intervals.
  151.         ion_explosionTimer = 1
  152.         --Set the explosion timer flag to 1 so it is not done again with the looping (could have been true/false)
  153.         else
  154.         r = ion_beamSize --min/max blast radius: 1.5-28
  155.         --r will serve as our explosion radius. For the ion cannon, the explosions coming from the ion cannon
  156.         --will gradually increase distance from the center point in a circular motion, since I defined r as
  157.         --ion_beamSize, which is gradully increasing in size in the ionShot function at the same time.
  158.         angleup = randInt(0, 35999)/100
  159.         --Choose a random angle. A value between 0 and 35999 is divided by 100 because we want
  160.         --to have 2 random decimal places for as well, rather than just a whole integer.
  161.         explosionxcoord = r*math.cos(angleup) + ion_beaconx
  162.         explosionycoord = r*math.sin(angleup) + ion_beacony
  163.         --The x and y coordinates of the explosion will occur at a max radius of r away from the nuke beacon,
  164.         --in a circular shape. This is a fundamental, simple circle geometry formula.
  165.         createExplosion ( explosionxcoord, explosionycoord, ion_beaconz, 7 )
  166.         --An explosion of type 7 is created, which is the tied as the largest with some others it is
  167.         --an aircraft explosion.
  168.         ion_loops = ion_loops + 1
  169.                         if ion_loops == 16 then
  170.                         --on the 16th loop of this function
  171.                         ion_beamFlareSize = 200
  172.                         --This triggers the flare to grow +50 immediately right as the beam is ending to create a little
  173.                         --larger flash, just for effect as the beam is done
  174.                         setTimer ( "ionFlareFade", 5, 200 )
  175.                         --The flarefade function is set to occur 200 times at 5ms to set the flare size to 0 quickly, as
  176.                         --the beam has disappeared
  177.                         elseif ion_loops == 18 then
  178.                         --on the 18th loop of this function
  179.                         ion_explosionTimer = 0
  180.                         --Set the explosion timer to 0 for the next ion cannon launch, since this is the last loop
  181.                         ion_loops = 0
  182.                         --Set to 0 to trigger these events directly above on next ion cannon launch as well
  183.                     ion_beamSize = 5
  184.                     --Set to 0 to trigger the functions properly on the next ion cannon launch
  185.                 destroyElement ( ionBeam )
  186.                 destroyElement ( ionSecondaryBeam )
  187.                 destroyElement ( ionBeam2 )
  188.                 destroyElement ( ionSecondaryBeam2 )
  189.                 destroyElement ( ionBeam3 )
  190.                 destroyElement ( ionSecondaryBeam3 )
  191.                 --Destroy all the created checkpoint marker elements that made the beam
  192.                         end
  193.         end
  194. end
  195.  
  196. function ionFlareFade ()  
  197.             setMarkerSize ( ionBeamFlare, ion_beamFlareSize )
  198.         ion_beamFlareSize = ion_beamFlareSize - 1
  199.                 if ion_beamFlareSize == 0 then
  200.                         destroyElement ( ionBeamFlare )
  201.                         ion_cannonActivated = false
  202.                         ion_beamFlareSize = 5
  203.                 end
  204. --Each time the function loops, the flare gets -1 smaller. When it has a size of 0 and becomes invisible, it needs
  205. --to be deleted for the next ion cannon launch. No elements should stay created as they will pile up and eventually
  206. --crash you or the server. Finally, ion_cannonActivated is false, meaning the ion cannon is inactive and another
  207. --weapon use can be performed.
  208. end
  209.  
  210.  
« Modifié: 30 Mars 2007, 19:28:09 par spykerc8 »


~ Leader honoraire de la FsK Team ~ -
~ Membre honoraire de la PCP Team ~

Co-fondateur de GTAO - Retraité de la communauté

"Nous ne sommes rien, soyons tout !"


Hors ligne Labiloute

  • XSA
  • *
  • Tueur en série
  • Messages: 207
    • Voir le profil
    • GTA-Stunt.com
Re : Tutorial 8a: Ion Cannon
« Réponse #1 le: 30 Mars 2007, 20:29:45 »
OMG Hiroshima :ninja


Hors ligne Aless

  • *
  • Bandit
  • Messages: 331
    • Voir le profil
Re : Tutorial 8a: Ion Cannon
« Réponse #2 le: 23 Mai 2007, 00:35:17 »
Excellent! Dommage que l'on puissa pas faire ça sous SA-MP ! :(

EDIT: Ce script fonctionnera pour toutes les endroits de San Andreas ou seulement "le coin perdu dans la forêt"?
« Modifié: 23 Mai 2007, 00:46:46 par Aless(01) »
My Dedicated Server:

Intel Core2Quad Q6600- 2.4GHz - LGA775 - 1066MHz FSB - 2x4 MB L2/L3
2x2GB - DDR2 - 667MHz - Corsair Value - 3.2 Go utilisable sur 32 bits
80GB 16MB Buffer SATA-2 7200 TPM + 1 TB 32 MB Buffer SATA-2 5400 TPM EcoGreen
OS: Ubuntu Linux Hardy Heron 8.04.3

Info serveur: http://www.aless-server.ch/psi/