Jump to content
Sign in to follow this  
coolfact

Livefeed and attachTo

Recommended Posts

I am trying to create a simple livefeed script for people inside tanks, so they can view whats happening in front of the vehicle when in 1st person. However the relative coordinate system is making me a bit confused, if I want to attach the source object to the 'driverview' memPoint and the target object 1m in front of the memPoint/vehicle (so the livefeed will show whats in front of the vehicle), how should the highlighted (red) array be set, I have tried different combinations but to no avail.

//Create and hide objects used for livefeed
_source = "Sign_Sphere10cm_F" createVehicleLocal position player;
_target = "Sign_Sphere10cm_F" createVehicleLocal position player;
hideObject _target;
hideObject _source;

// Vehicle objects needs to be attached to
_veh = vehicle player;

//attach objects to vehicle
_source attachTo [_veh,[0,0,0], "driverview"]; _target attachTo [_veh,[1,0,0], "driverview"]; // Create livefeed [_source,_target,player,0] call BIS_fnc_liveFeed;

 

Share this post


Link to post
Share on other sites

This seems to point forward at least

//Create and hide objects used for livefeed
_source = "Sign_Sphere10cm_F" createVehicleLocal position player;
_target = "Sign_Sphere10cm_F" createVehicleLocal position player;
hideObject _target;
hideObject _source;

 // Vehicle objects needs to be attached to
_veh = vehicle player;
 
 //attach objects to vehicle
_source attachTo [_veh,[0,2,1.5], "driverview"];
 _target attachTo [_veh,[0,3,-0.9], "driverview"];  
  [_source,_target,player,0] call BIS_fnc_liveFeed;

Not sure about the perspective though.

Share this post


Link to post
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
Sign in to follow this  

×