Jump to content

Attach object to a plane


crazzy_boyy

Recommended Posts

crazzy_boyy

My code is crashing my game can anyone tell me how to fix it ?

 

 

 

// This file was decompiled using sascm.ini published by Seemann (http://sannybuilder.com/files/SASCM.rar) on 13.10.2007{$VERSION 3.1.0027}{$CLEO .cs}//-------------MAIN---------------thread 'GRFV':GRFV_11wait 0ifModel.Load(#Hydra)Model.Load(18631):GRFV_21wait 0if and Model.Available(#HYDRA) Model.Available(18631)else_jump @GRFV_210@ = Car.Create(#HYDRA, 0, 0, 0)Car.Angle(0@) = 90.01@ = Object.Create(18631, 0, 0, 0)0681: attach_object 1@ to_car 0@ with_offset 1.3 0.0 0.8 rotation 180.0 180.0 0.0jump @GRFV_11end_thread

 

Link to comment
Share on other sites

 

wait 0ifModel.Load(#Hydra)Model.Load(18631)

 

 

You don't need the wait 0, or the if, because you're not checking anything, you're just loading models.

 

 

:GRFV_21wait 0if andModel.Available(#HYDRA)Model.Available(18631)else_jump @GRFV_21

 

 

You could just use 038B in place of this, but it's not required.

 

 

Model.Load(18631)

 

 

18631 isn't an object, so you can't load it. You'll have to use a valid ID.

 

 

0@ = Car.Create(#HYDRA, 0, 0, 0)1@ = Object.Create(18631, 0, 0, 0)

 

 

You need to use floats these, so instead of 0 it would be 0.0.

 

 

end_thread

 

 

Don't use this in CLEO scripts, use 0A93 instead.

 

Here is a working version. Press Backspace to spawn the Hydra in front of the player.

 

 

// This file was decompiled using sascm.ini published by Seemann (http://sannybuilder.com/files/SASCM.rar) on 13.10.2007{$VERSION 3.1.0027}{$CLEO .cs}//-------------MAIN---------------thread 'GRFV' :GRFV_11wait 0 if and  Player.Defined($PLAYER_CHAR)0AB0:   key_pressed 8 else_jump @GRFV_11 04C4: store_coords_to 2@ 3@ 4@ from_actor $PLAYER_ACTOR with_offset 0.0 5.0 0.0 Model.Load(#HYDRA)Model.Load(3065)038B: load_requested_models wait 100 0@ = Car.Create(#HYDRA, 2@, 3@, 4@)Car.Angle(0@) = 90.01@ = Object.Create(3065, 2@, 3@, 4@)0681: attach_object 1@ to_car 0@ with_offset 1.3 0.0 0.8 rotation 180.0 180.0 0.0 Model.Destroy(#HYDRA)Model.Destroy(863)jump @GRFV_11

 

user posted image
Link to comment
Share on other sites

crazzy_boyy
wait 0ifModel.Load(#Hydra)Model.Load(18631)

 

 

You don't need the wait 0, or the if, because you're not checking anything, you're just loading models.

 

 

:GRFV_21wait 0if andModel.Available(#HYDRA)Model.Available(18631)else_jump @GRFV_21

 

 

You could just use 038B in place of this, but it's not required.

 

 

Model.Load(18631)

 

 

18631 isn't an object, so you can't load it. You'll have to use a valid ID.

 

 

0@ = Car.Create(#HYDRA, 0, 0, 0)1@ = Object.Create(18631, 0, 0, 0)

 

 

You need to use floats these, so instead of 0 it would be 0.0.

 

 

end_thread

 

 

Don't use this in CLEO scripts, use 0A93 instead.

 

Here is a working version. Press Backspace to spawn the Hydra in front of the player.

 

 

// This file was decompiled using sascm.ini published by Seemann (http://sannybuilder.com/files/SASCM.rar) on 13.10.2007{$VERSION 3.1.0027}{$CLEO .cs}//-------------MAIN---------------thread 'GRFV' :GRFV_11wait 0 if and  Player.Defined($PLAYER_CHAR)0AB0:   key_pressed 8 else_jump @GRFV_11 04C4: store_coords_to 2@ 3@ 4@ from_actor $PLAYER_ACTOR with_offset 0.0 5.0 0.0 Model.Load(#HYDRA)Model.Load(3065)038B: load_requested_models wait 100 0@ = Car.Create(#HYDRA, 2@, 3@, 4@)Car.Angle(0@) = 90.01@ = Object.Create(3065, 2@, 3@, 4@)0681: attach_object 1@ to_car 0@ with_offset 1.3 0.0 0.8 rotation 180.0 180.0 0.0 Model.Destroy(#HYDRA)Model.Destroy(863)jump @GRFV_11

 

Thanks dude you saved me, but the object is there i added it with Map Editor

Link to comment
Share on other sites

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
  • 1 User Currently Viewing
    0 members, 0 Anonymous, 1 Guest

×
×
  • Create New...

Important Information

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