Jump to content

» «

Is actor driving any car?

3 replies to this topic
  • gokuta

    Square Civilian

  • Members
  • Joined: 24 Apr 2014
  • Afghanistan


Posted 25 July 2014 - 02:44 AM Edited by gokuta, 25 July 2014 - 02:45 AM.

Ok, I've got those two opcodes:

00DF:   actor $PLAYER_ACTOR driving
0449:   actor $PLAYER_ACTOR in_a_car

Somehow 00DF returns TRUE when I'm sitting in a car as a passenger. So,... what's the difference between them? And one more question: is there such an opcode, that return TRUE only if actor is sitting in any car as a driver and returns FALSE otherwise. Thanks

  • Automan

    Grandfather Modder

  • Members
  • Joined: 13 Dec 2008
  • Italy


Posted 25 July 2014 - 03:48 PM

Very strange ... 
Have you tried if the code works against it? ...
80DF:   not actor $PLAYER_ACTOR driving 


  • fastman92

    фастман92 | ف

  • Members
  • Joined: 28 Jul 2009
  • Poland
  • Best Total Overhaul 2017 Contribution [GTA: Underground]
    Best Conversion 2016 [GTA: Underground] [Contribution]
    Contribution Award [Mods]


Posted 25 July 2014 - 04:11 PM

00DF will return true if the character has a vehicle, even if they are not actually sat inside it (opening and closing the door).

Returns true if the character is occupying any vehicle.

He may be a driver or passenger.

Let's check it.

0449:   is_char_sitting_in_any_car $PLAYER_ACTOR
    03C0: store_car_char_is_in_no_save $PLAYER_ACTOR store_to [email protected]         

    046C: get_driver_of_car [email protected] store_to [email protected]
    003C:   $PLAYER_ACTOR == [email protected]
        // Carl Johnson is driver of [email protected] vehicle

  • Automan

    Grandfather Modder

  • Members
  • Joined: 13 Dec 2008
  • Italy


Posted 26 July 2014 - 09:11 AM

Sorry, but if you do get CJ drive of the game, 
it is only a driver. 
If you do get CJ in car of the scripts, 
you already know if CJ are driving or passenger... 
But maybe I do not understand fine the problem! :)

1 user(s) are reading this topic

0 members, 1 guests, 0 anonymous users