altv-issues icon indicating copy to clipboard operation
altv-issues copied to clipboard

Add a native that makes it possible to fall out of the vehicle through the windscreen

Open Whitee303 opened this issue 3 years ago • 3 comments

Description of the problem

Add a native that makes it possible to fall out of the vehicle through the windscreen as in FiveM

https://github.com/citizenfx/fivem/blob/22ff65cf6e181d949570bca03b3d15e3e5ed55f1/code/components/extra-natives-five/src/VehicleExtraNatives.cpp#L1148

Desired solution for the problem

Alternatives you considered

No response

Additional context

No response

Version

No response

Whitee303 avatar Oct 23 '22 15:10 Whitee303

There is already a flag to set for it

yannbcf avatar Oct 23 '22 15:10 yannbcf

PED_FLAG_CAN_FLY_THRU_WINDSCREEN

https://docs.altv.mp/gta/articles/ped/flags.html

Doxoh avatar Oct 23 '22 15:10 Doxoh

PED_FLAG_CAN_FLY_THRU_WINDSCREEN

https://docs.altv.mp/gta/articles/ped/flags.html

He's suggesting to add some sort of method to let a ped fall thru a windscreen programatically. In the code above you could just set max speed to something really low and it would throw you out the vehicle.

// EDIT: It's possible by setting players pos the the vehicles pos and then apply some force and anim.

xLuxy avatar Oct 23 '22 15:10 xLuxy