Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- void microTeleport()
- {
- Ped playerPed = PLAYER::PLAYER_PED_ID();
- static Vector3 curLocation = ENTITY::GET_ENTITY_COORDS(playerPed, 0);
- static float curHeading = ENTITY::GET_ENTITY_HEADING(playerPed);
- float forwardPush = 0.1; //tiny
- float xVect = forwardPush * sin(degToRad(curHeading)) * -1.0f;
- float yVect = forwardPush * cos(degToRad(curHeading));
- ENTITY::SET_ENTITY_COORDS_NO_OFFSET(playerPed, curLocation.x + xVect, curLocation.y + yVect, curLocation.z, 1, 1, 1);
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement