Quantcast

Jump to content

» «
Photo

GTA SA Car as boat how i can make this? My script dont work :(

9 replies to this topic
MrGTAmodsgerman
  • MrGTAmodsgerman

    Rat

  • Members
  • Joined: 02 Jan 2012

#1

Posted 19 January 2014 - 12:31 PM Edited by MrGTAmodsgerman, 19 January 2014 - 12:32 PM.

I wanna make a script that makes the rhino swimming in a water like a boat. I know this is workable, i see in the night ride mod that.
How i can make this like in the night rider mod?
I wanna make this but all cars can swim and it doesnt looks like the night rider mod :(

My script:

// 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---------------
03A4: name_thread 'RHINOWATER'

:RHINOWATER_19
0001: wait 0 ms
00D6: if  
0AB0:   key_pressed 221  
00D6: if
0256:   player $PLAYER_CHAR defined
then
    if
        Actor.DrivingVehicleType($PLAYER_ACTOR, #rhino)
004D: jump_if_false @RHINOWATER_19
00D6: if and
00DF:   actor $PLAYER_ACTOR driving
84A9:   not actor $PLAYER_ACTOR driving_heli
84AB:   not actor $PLAYER_ACTOR driving_plane
84C8:   not actor $PLAYER_ACTOR driving_flying_vehicle
89AE:   not actor $PLAYER_ACTOR driving_train
004D: jump_if_false @RHINOWATER_19
03C0: 10@ = actor $PLAYER_ACTOR car
004D: jump_if_false @RHINOWATER_19
03E5: show_text_box 'Aktivadet'
0A8C: write_memory 9867602 size 4 value 1 virtual_protect 0
0001: wait 1000 ms
0002: jump @RHINOWATER_75
end

:RHINOWATER_75
0001: wait 0 ms
00D6: if
0AB0:   key_pressed 221
004D: jump_if_false @RHINOWATER_75
03E5: show_text_box 'Deaktivadet'
0A8C: write_memory 9867602 size 4 value 0 virtual_protect 0
0001: wait 1000 ms
0002: jump @RHINOWATER_19

How i can make the script like in the Nightrider mod?

please help ! :(


ZAZ
  • ZAZ

    Kernlochbohrer

  • Members
  • Joined: 10 Jan 2005
  • European-Union

#2

Posted 19 January 2014 - 02:52 PM

basicly the script works but it's a little bit messed up because of missing or wrong placed els_jumps
also use other keys instead the exotic ] (key 221 = ])

this is what you need

{$CLEO .cs}
thread 'RNWATER'

:RHINOWATER_19
wait 0
if
0256:   player $PLAYER_CHAR defined
jf @RHINOWATER_19
if  and
0AB0:   key_pressed 8// key = backspace
00DD:   actor $PLAYER_ACTOR driving_car_with_model #RHINO
jf @RHINOWATER_19
 
03C0: 10@ = actor $PLAYER_ACTOR car
03E5: show_text_box 'fem_on'
0A8C: write_memory 9867602 size 4 value 1 virtual_protect 0
0001: wait 3000 ms
 

:RHINOWATER_75
wait 0
if  or
0AB0:   key_pressed 8// key = backspace
80DF: not  actor $PLAYER_ACTOR driving
jf @RHINOWATER_75
03E5: show_text_box 'fem_off'
0A8C: write_memory 9867602 size 4 value 0 virtual_protect 0
wait 1000
jump @RHINOWATER_19

btw. you can't insert a text like 'Aktivadet' because it needs to insert a gxt string which is limited to 7 charackter


MrGTAmodsgerman
  • MrGTAmodsgerman

    Rat

  • Members
  • Joined: 02 Jan 2012

#3

Posted 19 January 2014 - 03:59 PM

basicly the script works but it's a little bit messed up because of missing or wrong placed els_jumps
also use other keys instead the exotic ] (key 221 = ])

this is what you need

{$CLEO .cs}
thread 'RNWATER'

:RHINOWATER_19
wait 0
if
0256:   player $PLAYER_CHAR defined
jf @RHINOWATER_19
if  and
0AB0:   key_pressed 8// key = backspace
00DD:   actor $PLAYER_ACTOR driving_car_with_model #RHINO
jf @RHINOWATER_19
 
03C0: 10@ = actor $PLAYER_ACTOR car
03E5: show_text_box 'fem_on'
0A8C: write_memory 9867602 size 4 value 1 virtual_protect 0
0001: wait 3000 ms
 

:RHINOWATER_75
wait 0
if  or
0AB0:   key_pressed 8// key = backspace
80DF: not  actor $PLAYER_ACTOR driving
jf @RHINOWATER_75
03E5: show_text_box 'fem_off'
0A8C: write_memory 9867602 size 4 value 0 virtual_protect 0
wait 1000
jump @RHINOWATER_19

btw. you can't insert a text like 'Aktivadet' because it needs to insert a gxt string which is limited to 7 charackter

THANKS :D it works but how i can set the Rhino a little bit under water like the night rider script?
like this video:

this vehicle isnt on water this vehicle is in water like a boat ;)


ZAZ
  • ZAZ

    Kernlochbohrer

  • Members
  • Joined: 10 Jan 2005
  • European-Union

#4

Posted 20 January 2014 - 05:16 PM

seems not possible with cheat adress
try this script:

{$CLEO .cs}
:AmphibienRhino
03A4: name_thread 'AMPHIBI'
wait 1000
00A1: put_actor $PLAYER_ACTOR at 273.0837 -1788.2213 4.3614 

:AMPHIBI_1
0001: wait 0 ms
if
0256:   player $PLAYER_CHAR defined
jf @AMPHIBI_1
if
00DD:  actor $PLAYER_ACTOR driving_vehicle_type #RHINO
jf @AMPHIBI_1
03C0: 5@ = actor $PLAYER_ACTOR car
if
8119:   NOT   car 5@ wrecked
jf @AMPHIBI_23


:AMPHIBI_5
0001: wait 0 ms
if
0256:   player $PLAYER_CHAR defined
jf @AMPHIBI_1
if 
00DF:  actor $PLAYER_ACTOR driving
jf @AMPHIBI_1
0407: create_coordinate 11@ 12@ 13@ from_car 5@ offset  0.0  0.0  0.0
000F: 13@ -=  2.0  // floating-point values
092E: get_water_height_at 11@ 12@ flag 0 store_to 10@
if
10@ > -100.0
jf @AMPHIBI_5
if
0025:   10@ > 13@  // floating-point values
jf @AMPHIBI_5
0174: 9@ = car 5@ z_angle
if
00E1:   key_pressed  0  16
jf @AMPHIBI_7
0175: set_car 5@ z_angle_to 9@
02F6: 11@ = cosine 9@  // sinus swapped with cosine
02F7: 12@ = sinus 9@ // cosine swapped with sinus 
0013: 11@ *=  0.005  // floating-point values
0013: 12@ *=  0.005  // floating-point values
0013: 11@ *=  -1.0  // floating-point values
07D5: set_car 5@ velocity_in_direction_XYZ 11@ 12@ 0.010 rotation_velocitiesXY 0.0 0.0 unk 0.0
jump @AMPHIBI_11


:AMPHIBI_7
if
00E1:   key_pressed  0  14
jf @AMPHIBI_9
0174: 9@ = car 5@ z_angle
000B: 9@ +=  180.0  // floating-point values
02F6: 11@ = cosine 9@  // sinus swapped with cosine
02F7: 12@ = sinus 9@ // cosine swapped with sinus 
0013: 11@ *=  0.005  // floating-point values
0013: 12@ *=  0.005  // floating-point values
0013: 11@ *=  -1.0  // floating-point values
07D5: set_car 5@ velocity_in_direction_XYZ 11@ 12@ 0.010 rotation_velocitiesXY 0.0 0.0 unk 0.0
jump @AMPHIBI_11

:AMPHIBI_9
02F6: 11@ = cosine 9@  // sinus swapped with cosine
02F7: 12@ = sinus 9@ // cosine swapped with sinus 
0013: 11@ *=  0.001  // floating-point values
0013: 12@ *=  0.001  // floating-point values
0013: 11@ *=  -1.0  // floating-point values
07D5: set_car 5@ velocity_in_direction_XYZ 11@ 12@ 0.007 rotation_velocitiesXY 0.0 0.0 unk 0.0

:AMPHIBI_11
if
00E1:   key_pressed  0  0
jf @AMPHIBI_17
0494: get_joystick_data  0 0@ 1@ 8@ 3@
if
0039:   0@ ==  0  // integer values
jf @AMPHIBI_13
jump @AMPHIBI_17

:AMPHIBI_13
if 
0019:   0@ >  0  // integer values
jf @AMPHIBI_15
000F: 9@ -= 3.5 
0175: set_car 5@ z_angle_to 9@
jump @AMPHIBI_17

:AMPHIBI_15
if 
001B:    0 > 0@  // integer values
jf @AMPHIBI_17
000B: 9@ += 3.5
0175: set_car 5@ z_angle_to 9@

:AMPHIBI_17
if
00E1:   key_pressed  0  15
jf @AMPHIBI_5

0519: lock_vehicle 5@ in_current_position  1
0633: AS_actor $PLAYER_ACTOR exit_car

:AMPHIBI_20
0001: wait  0 ms
if
0256:   player $PLAYER_CHAR defined
jf @AMPHIBI_23
if
80DB:  not actor $PLAYER_ACTOR in_car 5@
jf @AMPHIBI_20

:AMPHIBI_23
wait 500
jump @AMPHIBI_1




MrGTAmodsgerman
  • MrGTAmodsgerman

    Rat

  • Members
  • Joined: 02 Jan 2012

#5

Posted 20 January 2014 - 08:52 PM

 

seems not possible with cheat adress
try this script:

{$CLEO .cs}
:AmphibienRhino
03A4: name_thread 'AMPHIBI'
wait 1000
00A1: put_actor $PLAYER_ACTOR at 273.0837 -1788.2213 4.3614 

:AMPHIBI_1
0001: wait 0 ms
if
0256:   player $PLAYER_CHAR defined
jf @AMPHIBI_1
if
00DD:  actor $PLAYER_ACTOR driving_vehicle_type #RHINO
jf @AMPHIBI_1
03C0: 5@ = actor $PLAYER_ACTOR car
if
8119:   NOT   car 5@ wrecked
jf @AMPHIBI_23


:AMPHIBI_5
0001: wait 0 ms
if
0256:   player $PLAYER_CHAR defined
jf @AMPHIBI_1
if 
00DF:  actor $PLAYER_ACTOR driving
jf @AMPHIBI_1
0407: create_coordinate 11@ 12@ 13@ from_car 5@ offset  0.0  0.0  0.0
000F: 13@ -=  2.0  // floating-point values
092E: get_water_height_at 11@ 12@ flag 0 store_to 10@
if
10@ > -100.0
jf @AMPHIBI_5
if
0025:   10@ > 13@  // floating-point values
jf @AMPHIBI_5
0174: 9@ = car 5@ z_angle
if
00E1:   key_pressed  0  16
jf @AMPHIBI_7
0175: set_car 5@ z_angle_to 9@
02F6: 11@ = cosine 9@  // sinus swapped with cosine
02F7: 12@ = sinus 9@ // cosine swapped with sinus 
0013: 11@ *=  0.005  // floating-point values
0013: 12@ *=  0.005  // floating-point values
0013: 11@ *=  -1.0  // floating-point values
07D5: set_car 5@ velocity_in_direction_XYZ 11@ 12@ 0.010 rotation_velocitiesXY 0.0 0.0 unk 0.0
jump @AMPHIBI_11


:AMPHIBI_7
if
00E1:   key_pressed  0  14
jf @AMPHIBI_9
0174: 9@ = car 5@ z_angle
000B: 9@ +=  180.0  // floating-point values
02F6: 11@ = cosine 9@  // sinus swapped with cosine
02F7: 12@ = sinus 9@ // cosine swapped with sinus 
0013: 11@ *=  0.005  // floating-point values
0013: 12@ *=  0.005  // floating-point values
0013: 11@ *=  -1.0  // floating-point values
07D5: set_car 5@ velocity_in_direction_XYZ 11@ 12@ 0.010 rotation_velocitiesXY 0.0 0.0 unk 0.0
jump @AMPHIBI_11

:AMPHIBI_9
02F6: 11@ = cosine 9@  // sinus swapped with cosine
02F7: 12@ = sinus 9@ // cosine swapped with sinus 
0013: 11@ *=  0.001  // floating-point values
0013: 12@ *=  0.001  // floating-point values
0013: 11@ *=  -1.0  // floating-point values
07D5: set_car 5@ velocity_in_direction_XYZ 11@ 12@ 0.007 rotation_velocitiesXY 0.0 0.0 unk 0.0

:AMPHIBI_11
if
00E1:   key_pressed  0  0
jf @AMPHIBI_17
0494: get_joystick_data  0 0@ 1@ 8@ 3@
if
0039:   0@ ==  0  // integer values
jf @AMPHIBI_13
jump @AMPHIBI_17

:AMPHIBI_13
if 
0019:   0@ >  0  // integer values
jf @AMPHIBI_15
000F: 9@ -= 3.5 
0175: set_car 5@ z_angle_to 9@
jump @AMPHIBI_17

:AMPHIBI_15
if 
001B:    0 > 0@  // integer values
jf @AMPHIBI_17
000B: 9@ += 3.5
0175: set_car 5@ z_angle_to 9@

:AMPHIBI_17
if
00E1:   key_pressed  0  15
jf @AMPHIBI_5

0519: lock_vehicle 5@ in_current_position  1
0633: AS_actor $PLAYER_ACTOR exit_car

:AMPHIBI_20
0001: wait  0 ms
if
0256:   player $PLAYER_CHAR defined
jf @AMPHIBI_23
if
80DB:  not actor $PLAYER_ACTOR in_car 5@
jf @AMPHIBI_20

:AMPHIBI_23
wait 500
jump @AMPHIBI_1



Big script but it is a very crazy,the rhino jump in the water and drive on the water not in there and it controls very difficult.
I have a idea,
a boat attach to the rhino and i automaticly drive the boat but sit in the rihno,and the boat is invisible,but is this possible??
The collision of the boat isnt working,the boat only works as a swimming motor. Hmm but i didnt know where i can find these opcodes :/
But thanks for the help ;)


GtaHellmodded
  • GtaHellmodded

    Hell Modded

  • Members
  • Joined: 05 Jul 2013

#6

Posted 29 January 2014 - 02:49 AM

your idea working man ! but player animation drive boat not like drive bike or car

here i some screenshot of my cleo mod i write using you idea:

gta_sa2014-01-2909-45-04-96_zpsa955d638.

gta_sa2014-01-2909-45-09-45_zps1d87fef3.


MrGTAmodsgerman
  • MrGTAmodsgerman

    Rat

  • Members
  • Joined: 02 Jan 2012

#7

Posted 04 March 2014 - 02:48 AM

your idea working man ! but player animation drive boat not like drive bike or car

here i some screenshot of my cleo mod i write using you idea:

gta_sa2014-01-2909-45-04-96_zpsa955d638.

gta_sa2014-01-2909-45-09-45_zps1d87fef3.

Thanks but can you help me with it? I cant download your mod and i didnt wanna brake the copyrights of your mod.


GtaHellmodded
  • GtaHellmodded

    Hell Modded

  • Members
  • Joined: 05 Jul 2013

#8

Posted 05 March 2014 - 06:13 AM

this mod ?? or Ghost Rider mod ?? :barf:


MrGTAmodsgerman
  • MrGTAmodsgerman

    Rat

  • Members
  • Joined: 02 Jan 2012

#9

Posted 05 March 2014 - 03:32 PM

this mod ?? or Ghost Rider mod ?? :barf:

This mod where i can see the way to make my mod with a swimming rhino


GtaHellmodded
  • GtaHellmodded

    Hell Modded

  • Members
  • Joined: 05 Jul 2013

#10

Posted 06 March 2014 - 04:13 AM

// 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 'RNWATER' 

:RNWATER_11
Model.Load(#DINGHY)
038B: load_requested_models 
04ED: load_animation "BIKEH" 
wait 0 
if 
   Player.Defined($PLAYER_CHAR)
jf @RNWATER_11 
if and
   Model.Available(#DINGHY)
0AB0:   key_pressed 8 
   Actor.DrivingVehicleType($PLAYER_ACTOR, #RHINO)
jf @RNWATER_11 
03C0: 10@ = actor $PLAYER_ACTOR car 
03E5: show_text_box 'FEM_ON'  // ON
04C4: store_coords_to 4@ 5@ 6@ from_actor $PLAYER_ACTOR with_offset 0.0 0.0 0.0 
9@ = Car.Create(#DINGHY, 4@, 5@, 6@)
072A: put_actor $PLAYER_ACTOR into_car 9@ driverseat 
0683: attach_car 10@ to_car 9@ with_offset 0.0 0.0 0.0 rotation 0.0 0.0 360.0 
Model.Destroy(#DINGHY)
wait 3000 

:RNWATER_196
wait 0 
if or
0AB0:   key_pressed 8 
   not Actor.Driving($PLAYER_ACTOR)
jf @RNWATER_196 
03E5: show_text_box 'FEM_OFF'  // OFF
05CD: AS_actor $PLAYER_ACTOR exit_car 9@ 
072A: put_actor $PLAYER_ACTOR into_car 10@ driverseat 
wait 100 
Car.Destroy(9@)
wait 1000 
jump @RNWATER_11 

need to make boat that attach to rniho invisible !





1 user(s) are reading this topic

0 members, 1 guests, 0 anonymous users