[BFV] ObjectTemplate.SoldierCameraPosition

Until this forum becomes busy just include BF2, 2142 or BFV in the title

[BFV] ObjectTemplate.SoldierCameraPosition

Postby billy_madison » Wed Nov 14, 2012 2:12 am

Looking at the objects/HandWeapons/SVD/Objects.con it sets this property on line 22:
ObjectTemplate.soldierCameraPosition -0.03/-0.04/0.0
which sets the camera and thus the crosshair.

Given that earlier it sets the property ObjecTemplate.projectilePosition 0/0/0 on line 12, does this mean that
the crosshair doesn't exactly lineup with the path of the bullet but is slightly down and to the left, and therefore
if you use the sniper scope (or crosshair) for aiming it will be off?
billy_madison
 
Posts: 5
Joined: Wed Sep 28, 2011 11:33 pm

Re: [BFV] ObjectTemplate.SoldierCameraPosition

Postby Senshi » Thu Nov 15, 2012 3:06 pm

Yes.

The crosshair is nothing more than a "helper", it is simply being painted at the centre of the screen. If you think about it, this is logical, though not apparent for most kinds of weapons, as all of them usually are very close to center (as is the SVD). Considering that the same principle applies to all vehicles, you can find several vehicles where the difference is vast: E.g. capital ships (in BF42), where the main turrets can be hugely offset from the tower that contains the camera. But even tanks will notice it, often with the coax MG being offset to the left or right of the main cannon.
User avatar
Senshi
 
Posts: 695
Joined: Sun Oct 18, 2009 1:14 pm
Location: Germany

Re: [BFV] ObjectTemplate.SoldierCameraPosition

Postby billy_madison » Sun Nov 25, 2012 6:36 am

Okay I found these camera values in CommonSoldierData.inc:
ObjectTemplate.setPoseCameraPos c_BfSoldierStanding 0/0.60/0
ObjectTemplate.setPoseCameraPos c_BfSoldierCrouching 0/0.05/0
ObjectTemplate.setPoseCameraPos c_BfSoldierLying 0/-0.7/0

I also noticed that the value for c_BfSoldierCrouching is different in bfv then bf42, in bf42 it is 0/0.12/0

I also added tracers to the SVD so that I can see where it shoots from by adding this line to the SVD's objects.con file:
ObjectTemplate.setTracerTemplate Tracer_Projectile CRD_NONE/0/0/0
The SVD tracers will line up on the crosshairs only when the aim is level
with the horizon, If I look up or down the tracer starts out below or above the camera, I tried putting in different values
but it is off to the side.

For comparison when I changed the M16's soldierCameraPosition to 0/0/0 the aim was deadnuts on. I want to figure out
why the sniper rifle seems to have this funny offset.
billy_madison
 
Posts: 5
Joined: Wed Sep 28, 2011 11:33 pm


Return to Battlefield 2, 2142 and Vietnam Discussion

Who is online

Users browsing this forum: No registered users and 8 guests

cron