12jango Posted August 30, 2009 Share Posted August 30, 2009 0713: actor [email protected] driveby_actor -1 car -1 point 952.92 -1102.99 22.85 radius 100.0 4 1 firing_rate 90 I search for the opcode, but only this that I found. I wanna make an actor drive a bike and doing drive by, please help me. Link to comment Share on other sites More sharing options...
d0mm2k8 Posted August 30, 2009 Share Posted August 30, 2009 If the actor is driving the bike then he can't do a drive by. Try spawn another on the back of the bike and use that opcode like this: 0713: actor [email protected] driveby_actor [email protected] car -1 point 0.0 0.0 0.0 radius 100.0 4 1 firing_rate 90 Actor [email protected] is the guy on the back of the bike and actor [email protected] is the guy he's aiming at. BTW, don't forget to give him a weapon first Link to comment Share on other sites More sharing options...
gtasearcher Posted August 30, 2009 Share Posted August 30, 2009 AFAIK, anyone in a car can perform a drive-by. Give them a weapon [preferaply Micro SMG, you can find weapon models and groups in SB Help > GTA SA > Weapon IDS] and put them carry the group of that weapon. 01B2: give_actor $PLAYER_ACTOR weapon 28 ammo 6001B9: set_actor $PLAYER_ACTOR armed_weapon_to 5 Then make sure they're in a car and put the drive by opcode 0713: actor $PLAYER_ACTOR driveby_actor -1 car -1 point 952.92 -1102.99 22.85 radius 100.0 4 1 firing_rate 90 BE CAREFUL! Make sure that if you set them to drive-by an actor, they won't DB a car or a point, and so on... For player you can also use 0501: set_player $PLAYER_CHAR driveby_mode 0 But if you don't want him to exit the car use 07CC: set_player $PLAYER_CHAR button_15 {enter/exit} 0 Link to comment Share on other sites More sharing options...
ZAZ Posted August 30, 2009 Share Posted August 30, 2009 If the actor is driving the bike then he can't do a drive by. Yes he can Actor [email protected] is the guy on the back of the bike and actor [email protected] is the guy he's aiming at. 0713: actor [email protected] driveby_actor [email protected] car -1 point 0.0 0.0 0.0 radius 100.0 4 1 firing_rate 90 therefor the actor [email protected] must exist if actor [email protected] should attack the player then init $PLAYER_ACTOR instead of [email protected] -1 as entry for the target actor should normally let attack to everyone but it seems that he do nothing then BTW, don't forget to give him a weapon first thats very important CLEO MODS CLEO Script Tutorial Link to comment Share on other sites More sharing options...
12jango Posted August 30, 2009 Author Share Posted August 30, 2009 thread 'drive-by':MODELModel.Load(#MALE01)Model.Load(#ALPHA)Model.Load(#MICRO_UZI)038B: load_requested_models :MODEL_LOADif or not Model.Available(#MALE01) not Model.Available(#ALPHA) not Model.Available(#MICRO_UZI)jf @MODEL_SPAWNjump @MODEL_LOAD:[email protected] = Car.Create(#ALPHA, 2411.9377, -1858.5471, 1.4141)Car.Angle([email protected]) = 89.6142Car.Health([email protected]) = [email protected] = Actor.Create(CivMale, #MALE01, 2411.5884, -1861.7018, 1.4141)Actor.Angle([email protected]) = 6.8934Actor.Health([email protected]) = 250001B2: give_actor [email protected] weapon 28 ammo 60 // Load the weapon model before using this 01B9: set_actor [email protected] armed_weapon_to 5Actor.InCar([email protected], [email protected])0713: actor [email protected] driveby_actor $PLAYER_ACTOR car -1 point 0.0 0.0 0.0 radius 100.0 4 1 firing_rate 90 05E2: AS_actor [email protected] kill_actor $PLAYER_ACTOR 0249: release_model #MALE010249: release_model #ALPHA0249: release_model #MICRO_UZIend_thread This is my try, but the actor didn't drive the car and do drive by, only attack the player with uzi... Link to comment Share on other sites More sharing options...
gtasearcher Posted August 30, 2009 Share Posted August 30, 2009 Don't use 05E2: AS_actor [email protected] kill_actor $PLAYER_ACTOR Link to comment Share on other sites More sharing options...
12jango Posted August 30, 2009 Author Share Posted August 30, 2009 Nah, still not working! If you don't mind would you please make a simple example for it? Link to comment Share on other sites More sharing options...
ZAZ Posted August 30, 2009 Share Posted August 30, 2009 Nah, still not working! If you don't mind would you please make a simple example for it? Go into red marker in Grovestreet {$CLEO .cs}:Driveby_103A4: name_thread 'Driveby':Driveby_20001: wait 0 msif0256: player $PLAYER_CHAR defined004D: jump_if_false @Driveby_2if00FF: actor $PLAYER_ACTOR 1 (in-sphere)near_point_on_foot 2491.5 -1667.5 13.35 radius 1.0 1.0 1.0004D: jump_if_false @Driveby_20247: request_model #NRG5000247: request_model #fam10247: request_model #fam20247: request_model #MP5LNG:Driveby_30001: wait 0 msif and0248: model #NRG500 available0248: model #fam1 available0248: model #fam2 available0248: model #MP5LNG available004D: jump_if_false @Driveby_300A5: [email protected] = create_car #NRG500 at 2487.5 -1660.5 13.350175: set_car [email protected] z_angle_to 90.00129: [email protected] = create_actor 7 #fam1 in_car [email protected] driverseat01C8: [email protected] = create_actor 7 #fam2 in_car [email protected] passenger_seat 00223: set_actor [email protected] health_to 5000 0223: set_actor [email protected] health_to 5000 01B2: give_actor [email protected] weapon 29 ammo 6000 // Load the weapon model before using this 01B2: give_actor [email protected] weapon 29 ammo 6000 // Load the weapon model before using this0713: actor [email protected] driveby_actor $PLAYER_ACTOR car -1 point 0.0 0.0 0.0 radius 5000.0 4 1 firing_rate 1000713: actor [email protected] driveby_actor $PLAYER_ACTOR car -1 point 0.0 0.0 0.0 radius 5000.0 4 1 firing_rate 1000249: release_model #NRG5000249: release_model #fam10249: release_model #fam20249: release_model #MP5LNG00AD: set_car [email protected] max_speed_to 10.000AE: unknown_set_car [email protected] to_ignore_traffic_lights 200AF: set_car [email protected] driver_behaviour_to 1:Driveby_130001: wait 0 msif0256: player $PLAYER_CHAR defined004D: jump_if_false @Driveby_13if or0119: car [email protected] wrecked01F4: car [email protected] flipped8202: not actor $PLAYER_ACTOR near_car [email protected] radius 500.0 500.0 flag 0 004D: jump_if_false @Driveby_1301C3: remove_references_to_car [email protected] // Like turning a car into any random car01C2: remove_references_to_actor [email protected] // Like turning an actor into a random pedestrian01C2: remove_references_to_actor [email protected] // Like turning an actor into a random pedestrian0002: jump @Driveby_2 CLEO MODS CLEO Script Tutorial Link to comment Share on other sites More sharing options...
d0mm2k8 Posted August 30, 2009 Share Posted August 30, 2009 I didn't know that the driver could drive-by When I tried it, my code must of been f*cked Also, it doesn't seem you're actually 'telling' the driver to drive anywhere. Is that the problem? Link to comment Share on other sites More sharing options...
12jango Posted August 31, 2009 Author Share Posted August 31, 2009 Thanks for your script, dude! But, I need those actors to follow me wherever I go. Link to comment Share on other sites More sharing options...
TheSiggi Posted August 31, 2009 Share Posted August 31, 2009 07F8: car [email protected] follow_car [email protected] radius 27.0 ??? do you meam that? Link to comment Share on other sites More sharing options...
noalcohol Posted September 1, 2009 Share Posted September 1, 2009 (edited) Maybe 12jango want the actors will always follow player to drive by the player. Edited September 1, 2009 by noalcohol Link to comment Share on other sites More sharing options...
12jango Posted September 1, 2009 Author Share Posted September 1, 2009 (edited) That's right! I tried to make the same code as Zaz's, but it's looks like the actors only drive one the road (I want them to drive by the player ignore the road). Thanks! Edited September 1, 2009 by 12jango Link to comment Share on other sites More sharing options...
TheSiggi Posted September 1, 2009 Share Posted September 1, 2009 actor will follow CJ on foot: 07A3: AS_actor $10516([email protected],8i) run_to_and_follow_actor $PLAYER_ACTOR wait_radius_between 5.0 and 10.0 or I think you have to store players car to [email protected] then using I think this opcode: 06E1: AS_actor [email protected] using_car [email protected] target_car [email protected] with_order 29 max_speed 30.0 traffic_flag 2 so there you go but: I'm not sure with the parameters of that code 06E1: AS_actor [email protected] using_car [email protected] target_car [email protected] with_order 29 max_speed 80.0 traffic_flag 2 // 03C0: [email protected] = actor $PLAYER_ACTOR car Link to comment Share on other sites More sharing options...
12jango Posted September 1, 2009 Author Share Posted September 1, 2009 (edited) Well, I have no idea what are order 29 & traffic_flag 2 means... Anyone can help me with this? Edited September 1, 2009 by 12jango Link to comment Share on other sites More sharing options...
TheSiggi Posted September 1, 2009 Share Posted September 1, 2009 I think 15 instead of 29 is aggrassive or something like that...jut test it ingame Link to comment Share on other sites More sharing options...
ZAZ Posted September 1, 2009 Share Posted September 1, 2009 That's right! I tried to make the same code as Zaz's, but it's looks like the actors only drive one the road (I want them to drive by the player ignore the road). Thanks! read Car Drive Tutorial CLEO MODS CLEO Script Tutorial Link to comment Share on other sites More sharing options...
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now