Quantcast

Jump to content

» «
Photo

Niko drives from the passenger seats

15 replies to this topic
DGKN
  • DGKN

    Player Hater

  • Members
  • Joined: 26 Jul 2012

#1

Posted 18 August 2013 - 02:56 PM

Hi guys!

I remember a mod in Vice City where the player could sit in a passenger seat (in the back of a car, limo) and drive the car from that position.
This was really nice if you had a bodyguard who would sit in the driver seat and it would look like you had a personal driver.

Is there a similar mod for GTA IV ? If not, is it hard to code?


Thanks a lot for reading !

LuigiPeace
  • LuigiPeace

    Player Hater

  • Members
  • Joined: 02 Aug 2013

#2

Posted 18 August 2013 - 03:31 PM

You mean the player still control the car but from a passenger seat ? mercie_blink.gif
I know it's possible to have a ped driving a car to a specific location (that you could choose) and to make you sit in a passenger seat. So you'll have a personal driver (like Taxi but without any cost).
But I don't know if it's possible to control the car from a passenger seat...

Is it hard to code, it depends of every actions the mod would have to make. (Does the personal driver wait for you at your parking, or do you have to call him in order to make him come to you, ...) I think it can be easy but control the car from a passenger seat seems more difficult (if there isn't native functions to help)

pedro2555
  • pedro2555

    Open Sourcer

  • Members
  • Joined: 02 Sep 2012
  • Portugal

#3

Posted 18 August 2013 - 05:40 PM

Put a ped in the passenger seat (using the same model as the player), and make the player invisible. Done.

Maybe a swap action on entering and exiting for better looks. It is not difficult you just need to think out of the box biggrin.gif .

Michael Wojtanis
  • Michael Wojtanis

    Rinepim

  • Members
  • Joined: 17 Jul 2013

#4

Posted 19 August 2013 - 11:37 AM

Just copy a all player components and make same model like player - make inviisible real player.
Thank just think about sitting in and out.

LuigiPeace
  • LuigiPeace

    Player Hater

  • Members
  • Joined: 02 Aug 2013

#5

Posted 19 August 2013 - 12:53 PM

Why make the real player invisible ? He wants the player's skin for the passenger seat and a bodyguard's skin for the driver seat, no ?

Michael Wojtanis
  • Michael Wojtanis

    Rinepim

  • Members
  • Joined: 17 Jul 2013

#6

Posted 19 August 2013 - 01:43 PM

Oh lol i was thinking about other thing...
Sorry. wink.gif

There is the native task drive. There are functions like turn left, turn right etc. This can be good.

LuigiPeace
  • LuigiPeace

    Player Hater

  • Members
  • Joined: 02 Aug 2013

#7

Posted 19 August 2013 - 02:17 PM

Well, with how pedro2555 see it :

When you're with your bodyguard, you can "override" the F key so when you press it you make the player sit in the passenger seat (of the bodyguard' car or yours) : TaskEnterCarAsPassenger.
The same way your bodyguard sit in the driver seat : TaskEnterCarAsDriver.

This way, things look real to the player. When they are both in the car (IsCharInAnyCar), you teleport the player to the driver seat (WarpCharIntoCar) and the bodyguard to the passenger seat (WarpCharIntoCarAsPassenger). You swap the player's skin and the bodyguard's skin and you're done. You can drive the car...

When you want to get out, you "override" the F key and does the same things in reverse wink.gif

But maybe a third seat is required during the warp step...

DGKN
  • DGKN

    Player Hater

  • Members
  • Joined: 26 Jul 2012

#8

Posted 19 August 2013 - 03:13 PM

Thanks for the ideas guys.

I'm going to try to script this. Btw, how can I check if there's a bodyguard with me? Is there a native function for that?

LuigiPeace
  • LuigiPeace

    Player Hater

  • Members
  • Joined: 02 Aug 2013

#9

Posted 19 August 2013 - 03:20 PM

Hum... I don't remember : does Niko can have a bodyguard (by default) in the game ?

#yes :
- maybe a native function already exist
- if there isn't a native function go to #no

#no :
Groups & relationship for peds should help you a lot wink.gif

PacketOVerload_x64Bit
  • PacketOVerload_x64Bit

    Window Licker 4 Blondes

  • Members
  • Joined: 13 Mar 2010
  • Canada

#10

Posted 19 August 2013 - 10:37 PM

Simple Native Trainer.

1. Spawn a car.
2. Set your destination waypoint on the map.
3. Spawn a driver from the Bodyguards menu. Check drive options, typically Drive style 1, about 18MPH at the most for casual driving.
4. Go to Car Options, Second Menu, Select Toggle Through Passenger Seats (until you find the one you like).

While it's not driving directly, it's the next best thing. Setting Drive Style 2 makes drivers that are more agressive in traffic. You can select the type of driver by using the first menu under Bodyguard Menu, which model f_y_bronx for example.

stef538
  • stef538

    It's just me, going 88 MPH.

  • Members
  • Joined: 06 Oct 2012
  • Netherlands

#11

Posted 31 March 2014 - 04:14 PM

But wait a minute, if you copy the player files, and you have a ped niko, how can you set the same clothes ?

  • LordOfTheBongs likes this

Skorpro
  • Skorpro

    GTAholic

  • Members
  • Joined: 19 Jul 2009
  • Germany

#12

Posted 05 April 2014 - 09:20 AM

Hmmm, sounds interesting... to swap player with ped (passenger <-> driver) is possible but you can't change ped to player model (CHANGE_PLAYER_MODEL(Player playerIndex, uint model))...

I think there are 2 methods:

1. change player to a ped model. Now it's possible to get drivers & players model and swap both...

2. force the ped driver to do what you want via task...

... I will check some stuff, maybe I have an idea ;)

c ya


pedro2555
  • pedro2555

    Open Sourcer

  • Members
  • Joined: 02 Sep 2012
  • Portugal

#13

Posted 05 April 2014 - 09:55 AM

Hmmm, sounds interesting... to swap player with ped (passenger <-> driver) is possible but you can't change ped to player model (CHANGE_PLAYER_MODEL(Player playerIndex, uint model))...

I think there are 2 methods:

1. change player to a ped model. Now it's possible to get drivers & players model and swap both...

2. force the ped driver to do what you want via task...

... I will check some stuff, maybe I have an idea ;)

c ya

It depends on the actual goal.

 

There are two ways people are interpreting this request:

  1. Niko seats in the passenger seat, and the player still has control of the vehicle (which is my interpretation);
  2. Niko seats in the passenger seat, while AI takes control of the vehicle.

The first approach seems easier and more feasible than the second one. To make it work I think is just a question of creating a ped on the passenger seat with the same model as Niko, and change the Niko model to something else, when exiting the vehicle swap back. 


Skorpro
  • Skorpro

    GTAholic

  • Members
  • Joined: 19 Jul 2009
  • Germany

#14

Posted 05 April 2014 - 11:50 AM

... the player could sit in a passenger seat (in the back of a car, limo) and drive the car from that position. ... it would look like you had a personal driver.

 

Hi pedro2555,

I think he meant your first point "Niko seats in the passenger seat, and the player still has control of the vehicle".

 

The first approach seems easier and more feasible than the second one. To make it work I think is just a question of creating a ped on the passenger seat with the same model as Niko, and change the Niko model to something else, when exiting the vehicle swap back. 

 

 

IMO it's harder 'cause you can't change a ped model to player model (so far as I know... ;))

But you can control the ped driver...

TaskCarDriveWander(Ped ped, Vehicle vehicle, f32 speed, eVehicleDrivingStyle drivingStyle)

// HINT: roadDist => -1 follow path/street & 45000 ignore path dist 
// The 'unknown' unsigned int parts are MAYBE drivingStyle, pedType...
TaskCarDriveToCoord(Ped ped, Vehicle car, float x, float y, float z, float speed, u32 unknown1, u32 veh_model, u32 unknown2, u32 unknown3, u32 roadDist)

A part of this mod is already done but it's not ready yet :)


pedro2555
  • pedro2555

    Open Sourcer

  • Members
  • Joined: 02 Sep 2012
  • Portugal

#15

Posted 05 April 2014 - 12:00 PM


IMO it's harder 'cause you can't change a ped model to player model (so far as I know... ;))

 

Wait, you can't have a ped with the Niko model ? That is weird.. I'm gonna try it..


Skorpro
  • Skorpro

    GTAholic

  • Members
  • Joined: 19 Jul 2009
  • Germany

#16

Posted 16 April 2014 - 11:30 PM

Hi,

I was very busy... anyway here it is :)

Note: The steering is not the best but there is no other method to control a ped in car!

 

Link:   Driver Control Mod v0.9





1 user(s) are reading this topic

0 members, 1 guests, 0 anonymous users