14.07.2016, 08:23
Quote:
So a few days ago i was looking to make a script that would make weapons feel a bit more fleshed out, in the base game weapons don't really have any noticeable recoil besides the spray-pattern, but it still doesn't take that much skill to control your weapon, in games like Ghost Recon Phantoms the recoil is very noticeable and requires you to not only burst-fire but also keep track of how high your aim is getting with each shot.
I wanted to replicate this in SAMP with the camera controls, so i did this: Код:
public OnPlayerWeaponShot(playerid, weaponid, hittype, hitid, Float:fX, Float:fY, Float:fZ) { new Float:x, Float:y, Float:z; if(recoil == 1) { GetPlayerCameraFrontVector(playerid, x, y, z); SetPlayerCameraLookAt(playerid, x, y, z + 1.0, CAMERA_MOVE); } return 1; } So is there any way you could accomplish what i'm trying to do in SAMP or is it not possible? |
Use:
PHP код:
GetPointInFrontOfCamera3D(playerid,&Float:tx,&Float:ty,&Float:tz,Float:radius,&Float:rx=0.0,&Float:rz=0.0);