GetPlayerCameraTargetObject -
KubiPL - 25.01.2015
Hello,
I would like to report problem with GetPlayerCameraTargetObject. It isn't accure enough.
[ame]www.youtube.com/watch?v=UD61dlE08ks[/ame]
Also I suggest to fix Set(Player)ObjectMaterial. Options such as modelid, txdname, texturename when passing default params (-1 or none) shouldn't changing their texutre to default if it was set before. This should keep changed texture, and change only color for specific texture.
If hard to understand:
First, create an object and set texture:
Код:
SetObjectMaterial(CreateObject(19378, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0),0,14777,"int_casinoint3","GB_midbar06",0);
Now change only color:
Код:
SetPlayerObjectMaterial(playerid, obj, 0, -1, "none", "none", 0xFFFF0000);
The default texture is applied insead of the last one (14777,"int_casinoint3","GB_midbar06").
Re: GetPlayerCameraTargetObject -
d0 - 25.01.2015
It is called CameraTarget not CrosshairTarget
GetPlayerCameraTargetObject uses the center of your camera/screen and not the position of the crosshair.
Re: GetPlayerCameraTargetObject -
KubiPL - 25.01.2015
Yea, I know that, but couldn't be this changed when player is aiming?
Also look at rest of thing, please.
Re: GetPlayerCameraTargetObject -
codectile - 25.01.2015
@KubiPL: It can be a crosshair based function, if Kalcor does so. Now to the topic, this function depends upon player's camera's front vector scale, if the scale's magnitude is large/small then, the object detection can be done within that amount (scale's magnitude) of distance from the player/camera.
Re: GetPlayerCameraTargetObject -
n0minal - 25.01.2015
I've tested it yesterday on small objects and its hard to be accurate on it because it uses the exactly center of camera, anyways, i use a custom function, heres the video:
https://www.youtube.com/watch?v=llsjbLfKJys
So much more accurate.
Re: GetPlayerCameraTargetObject -
MP_Spec - 25.01.2015
I also recorded a video about it. However, it is a problem with the vehicle too. Look at 1:50
https://www.youtube.com/watch?v=fT94...ature=*********