project reality header
Go Back   Project Reality Forums > PR:BF2 Mod Forums > PR:BF2 Community Modding
08 Sep 2024, 00:00:00 (PRT)
Register Developer Blogs Members List Search Quick Links
PR:BF2 Community Modding Making or wanting help making your own asset? Check in here

Reply
 
Thread Tools Display Modes
Old 2014-01-12, 02:30   #1
qwerq

qwerq's Avatar
Default [?] Adding "camera recoil to handheld weapons

I've been screwing around with modding in BF2 for a few months now and I've been constantly developing a personal BF2 mod. So far I've overhauled the all the weapon and vehicle stats as well as most of the effects.

Anyways, I want to add the camera shaking effect of vehicle weapons to the handheld weapons, similar to PR, but I'm not sure how. I've tried this:

Code:
rem ---BeginComp:SoldierBasedRecoilComp ---
ObjectTemplate.createComponent SoldierBasedRecoilComp
ObjectTemplate.recoil.hasRecoilForce 1
ObjectTemplate.recoil.goBackOnRecoil 1
ObjectTemplate.recoil.recoilForceUp CRD_UNIFORM/0.8/1/0
ObjectTemplate.recoil.recoilForceLeftRight CRD_UNIFORM/-0.5/0.5/0
ObjectTemplate.recoil.zoomModifier 0.9
ObjectTemplate.recoil.recoilGraphFrameCount 8
ObjectTemplate.recoil.recoilGraphExponent 9
ObjectTemplate.recoil.recoilGraphTotalMovement 1
rem ---EndComp ---
rem ---BeginComp:WeaponBasedRecoilComp ---
rem ObjectTemplate.createComponent WeaponBasedRecoilComp
ObjectTemplate.recoil.cameraRecoilSpeed 10
ObjectTemplate.recoil.cameraRecoilSize 3
rem ---EndComp ---
This:

Code:
rem ---BeginComp:SoldierBasedRecoilComp ---
ObjectTemplate.createComponent SoldierBasedRecoilComp
ObjectTemplate.recoil.hasRecoilForce 1
ObjectTemplate.recoil.goBackOnRecoil 1
ObjectTemplate.recoil.recoilForceUp CRD_UNIFORM/0.8/1/0
ObjectTemplate.recoil.recoilForceLeftRight CRD_UNIFORM/-0.5/0.5/0
ObjectTemplate.recoil.zoomModifier 0.9
ObjectTemplate.recoil.recoilGraphFrameCount 8
ObjectTemplate.recoil.recoilGraphExponent 9
ObjectTemplate.recoil.recoilGraphTotalMovement 1
ObjectTemplate.recoil.cameraRecoilSpeed 10
ObjectTemplate.recoil.cameraRecoilSize 3
rem ---EndComp ---
This:

Code:
rem ---BeginComp:WeaponBasedRecoilComp ---
rem ObjectTemplate.createComponent WeaponBasedRecoilComp
ObjectTemplate.recoil.hasRecoilForce 1
ObjectTemplate.recoil.goBackOnRecoil 1
ObjectTemplate.recoil.recoilForceUp CRD_UNIFORM/0.8/1/0
ObjectTemplate.recoil.recoilForceLeftRight CRD_UNIFORM/-0.5/0.5/0
ObjectTemplate.recoil.zoomModifier 0.9
ObjectTemplate.recoil.recoilGraphFrameCount 8
ObjectTemplate.recoil.recoilGraphExponent 9
ObjectTemplate.recoil.recoilGraphTotalMovement 1
ObjectTemplate.recoil.cameraRecoilSpeed 10
ObjectTemplate.recoil.cameraRecoilSize 3
rem ---EndComp ---

They didn't work, as expected.

I've checked the recoil files in PR and they just had the SoldierBasedRecoilComp, nothing about WeaponBasedRecoil or cameraRecoil.

Anyone have any idea how to accomplish this? Thanks in advance.
qwerq is offline Reply With Quote
Old 2014-01-12, 03:06   #2
M42 Zwilling
Retired PR Developer

M42 Zwilling's Avatar
Default Re: [?] Adding "camera recoil to handheld weapons

Those settings for camera recoil don't work on handheld weapons. PR accomplishes the camera shake with the fire animation.



"How many posts have there been about how much better PR was back in 0.X? The fact is that if we played the older versions we would start to remember the shortcomings, but we tend to hold onto the good memories tighter than the bad ones." - Murphy
M42 Zwilling is offline Reply With Quote
Reply


Tags
adding camera, camera, handheld, recoil, weapons

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off



All times are GMT. The time now is 03:06.