Jump to content

My Mass Car spawning CLEO not working


Recommended Posts

Anurag_Anmol

 

{$CLEO .cs}:MassSpawner_103A4: name_thread 'MassSpawner':MassSpawner_2 // Checks if key is pressed to start the script0001: wait  0 ms00D6: if // if00E1:  key_pressed 0 49 // Number key 1 pressed (not on numpad)004D: jump_if_false @MassSpawner_2 // If not, go back to MassSpawner_20247: request_model #INFERNUS // If yes, load the car files0002: jump @MassSpawner_3:MassSpawner_30001: wait  0 ms00D6: if // if0248:  model #INFERNUS available // car files are loaded004D: jump_if_false @MassSpawner_3 // If not go back to MassSpawner_304C4: create_coordinate 11@ 12@ 13@ from_actor $PLAYER_ACTOR offset 0.0 10.0 0.0 // Make local variables to place car at.00A5: 1@ = create_car #INFERNUS at 11@ 12@ 13@ // Make car0175: set_car 1@ z_angle_to 90.0 // Set car direction0001: wait 250 ms // Wait so it doesn't spam, 4 cars a second.00D6: if // if00E1:  key_pressed 0 50 // Number 2 key pressed (not on numpad)004D: jump_if_false @MassSpawner_3 // if not, go back to MassSpawner_30002: jump @MassSpawner_2 // if yes, go back to MassSpawner_2

 

 

Well it doesn't spawn anything, I made it myself, lol copied most of the code from a CLEO tutorial xD Help pl0x smile.gif

Edited by Anurag_Anmol
Link to comment
https://gtaforums.com/topic/457299-my-mass-car-spawning-cleo-not-working/
Share on other sites

00D6: if // if00E1:  key_pressed 0 49 // Number key 1 pressed (not on numpad) // bingo!004D: jump_if_false @MassSpawner_2 // If not, go back to MassSpawner_2

 

 

00E1:   player 0 pressed_key 19 

 

 

just works for controlls :

This opcode checks if a key assigned to a function in the game is pressed. The GXT file can help display the keys being pressed. Use opcode 0AB0 to get a specific key on a keyboard.

http://www.gtamodding.com/index.php?title=00E1

 

so for checking if a not controll button is pressed use, as said in the article about 00E:, 0AB0:

 

 

 

{$CLEO .cs}//-------------MAIN---------------0000: NOP 03A4: name_thread 'MassSpawner' :MassSpawner_210001: wait 0 ms 00D6: if 0AB0:   key_pressed 49 004D: jump_if_false @MassSpawner_21 0247: load_model #INFERNUS :MassSpawner_450001: wait 0 ms 00D6: if 0248:   model #INFERNUS available 004D: jump_if_false @MassSpawner_45 04C4: store_coords_to 1@ 2@ 3@ from_actor $PLAYER_ACTOR with_offset 0.0 3.0 0.1 02CE: 3@ = ground_z_at 1@ 2@ 3@ 0172: 4@ = actor $PLAYER_ACTOR Z_angle 000B: 4@ += 270.0 00A5: 0@ = create_car #INFERNUS at 1@ 2@ 3@ 0175: set_car 0@ Z_angle_to 4@ 0249: release_model #INFERNUS 01C3: remove_references_to_car 0@ // Like turning a car into any random car 00D6: if 0AB0:   key_pressed 50 004D: jump_if_false @MassSpawner_45 0002: jump @MassSpawner_21 

 

 

this is your script, but if you just want to spawn an infernus to use it I'd recomend:

 

 

{$CLEO .cs}//-------------MAIN---------------0000: NOP 03A4: name_thread 'MassSpawner' :MassSpawner_210001: wait 0 ms 00D6: if 0AB0:   key_pressed 49 004D: jump_if_false @MassSpawner_21 0247: load_model #INFERNUS :MassSpawner_450001: wait 0 ms 00D6: if 0248:   model #INFERNUS available 004D: jump_if_false @MassSpawner_45 04C4: store_coords_to 1@ 2@ 3@ from_actor $PLAYER_ACTOR with_offset 0.0 3.0 0.1 02CE: 3@ = ground_z_at 1@ 2@ 3@ 0172: 4@ = actor $PLAYER_ACTOR Z_angle 000B: 4@ += 270.0 00A5: 0@ = create_car #INFERNUS at 1@ 2@ 3@ 0175: set_car 0@ Z_angle_to 4@ 0249: release_model #INFERNUS 01C3: remove_references_to_car 0@ // Like turning a car into any random car 0001: wait 20000002: jump @MassSpawner_21 

 

 

 

Edited by The_Siggi
Anurag_Anmol

Thanks a lot! But how do I make it spawn on each other, and not replace the other one? So I can build my own car tower tounge.gif Well maybe I could.. wait I know! Thanks! biggrin.gif

 

Edit : Yay I now making vehicle towers biggrin.gif

Edited by Anurag_Anmol

 

{$CLEO .cs}//-------------MAIN---------------0000: NOP 03A4: name_thread 'MassSpawner' :MassSpawner_210001: wait 0 ms 00D6: if 0AB0:   key_pressed 49 004D: jump_if_false @MassSpawner_21 03E5: show_text_box 'CHEAT1'  // Cheat activated0247: load_model #INFERNUS 0007: 8@ = 2.0 :MassSpawner_660001: wait 0 ms 00D6: if 0248:   model #INFERNUS available 004D: jump_if_false @MassSpawner_66 04C4: store_coords_to 1@ 2@ 3@ from_actor $PLAYER_ACTOR with_offset 0.0 3.0 0.0 005B: 3@ += 8@ // (float) 0172: 4@ = actor $PLAYER_ACTOR Z_angle 000B: 4@ += 270.0 00A5: 0@ = create_car #INFERNUS at 1@ 2@ 3@ 0175: set_car 0@ Z_angle_to 4@ 0249: release_model #INFERNUS 01C3: remove_references_to_car 0@ // Like turning a car into any random car 0001: wait 200 ms 000B: 8@ += 2.0 00D6: if 0AB0:   key_pressed 50 004D: jump_if_false @MassSpawner_66 03E5: show_text_box 'CHEAT8'  // Cheat deactivated0002: jump @MassSpawner_21

 

 

but it won't work as you might hope confused.gif the cars will collidile and just create a massive mess of cars on the ground tounge2.gif

 

but you might like this:

 

press numpad 9 on street

 

 

{$VERSION 3.1.0027}{$CLEO .cs}//-------------MAIN---------------0000: NOP 03A4: name_thread 'PRAIN' :PRAIN_130001: wait 20 ms 00D6: if 0256:   player $PLAYER_CHAR defined 004D: jump_if_false @PRAIN_227 00D6: if 03EE:   player $PLAYER_CHAR controllable 004D: jump_if_false @PRAIN_227 00D6: if and80DF:   not actor $PLAYER_ACTOR driving 84AD:   not actor $PLAYER_ACTOR in_water 8818:   not actor $PLAYER_ACTOR in_air 89E7:   not player $PLAYER_CHAR not_frozen 004D: jump_if_false @PRAIN_227 00D6: if 0AB0:   key_pressed 105 004D: jump_if_false @PRAIN_227 0247: load_model #INFERNUS :PRAIN_1008248:   not model #INFERNUS available 004D: jump_if_false @PRAIN_123 0001: wait 0 ms 0002: jump @PRAIN_100 :PRAIN_12304C4: store_coords_to 1@ 2@ 3@ from_actor $PLAYER_ACTOR with_offset 0.0 10.0 50.0 0001: wait 200 ms 0006: 31@ = 0 :PRAIN_1640001: wait 200 ms 00A5: 4@ = create_car #INFERNUS at 1@ 2@ 3@ 0001: wait 200 ms 01C3: remove_references_to_car 4@ // Like turning a car into any random car 000A: 31@ += 1 0019:   31@ > 40 004D: jump_if_false @PRAIN_164 0249: release_model #INFERNUS 0001: wait 2000 ms :PRAIN_2270002: jump @PRAIN_13 

 

 

 

Edited by The_Siggi

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 account

Sign in

Already have an account? Sign in here.

Sign In Now
  • 0 User Currently Viewing
    0 members, 0 Anonymous, 0 Guests

×
×
  • Create New...

Important Information

By using GTAForums.com, you agree to our Terms of Use and Privacy Policy.