Advertisement

Author Topic: Defining recoil  (Read 475 times)

0 Members and 1 Guest are viewing this topic.

Offline Dajan

  • Members
  • *
Defining recoil
« on: 21 Mar 2010, 23:50:08 »
Yup, this has probably been asked before by many a person starting out - I just couldn't find their posts! S please feel free to direct me if you know where they are  :good:

my thesis:-
As everyone who has ever opened a config for a weapon knows, it is possible to define recoils. We can diect the game to use BIS recoils or we can specify our own.
When creating a new set we are presented with 12 values eg:
Code: [Select]
{0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}Now as I understand it these are esentially split into four groups of three eg:
Code: [Select]
{a, a, a,    b, b, b,    c, c, c,    d, d, d}with each set of three values refering to reaction along axes (correct me if I'm wrong)
With a little experimentation I have been able to get this far:
GroupA ~ how far on each axis the gun reacts
GroupB ~ how far on each axis the aim adjusts itself with each shot
GroupC ~ I have tentatively identifed as being the extension of GroupB for each subsequent shot

Anyone still reading? Hope so, because here's the question:-

Assuming I'm not completely off in my guesses above what do GroupC and GroupD do and what effect do the values have on them?

I know, it's all a little long winded, I just am hoping to avoid being given a list of good values when I'm trying to understand why the values are what they are.
I've looked on BIKI, I've searched the forums here and on BIS, either I'm simply too incompetent to use the net or people are jealously guarding this knowledge....

TIA

Offline Planck

  • Honoured
  • Former Staff
  • ****
  • I'm never wrong ....I'm just not always right !
Re: Defining recoil
« Reply #1 on: 22 Mar 2010, 00:14:04 »
If you searched the Biki, then presumably you came across this ... no?

http://community.bistudio.com/wiki/cfgRecoils


Planck
I know a little about a lot, and a lot about a little.

Offline Dajan

  • Members
  • *
Re: Defining recoil
« Reply #2 on: 22 Mar 2010, 00:23:36 »
I did indeed. It was upon reading that, that I started experimenting. The problem with it is that the explanation doesn't really help me whith what each value means.
OK, so one of the three values in each group is said to be time taken rather than adjustments on the z axis, but that doesn't then leave room for kick backwards. The page seems to simply say "this is what we decided to code for the game, work it out for yourself"

Offline Planck

  • Honoured
  • Former Staff
  • ****
  • I'm never wrong ....I'm just not always right !
Re: Defining recoil
« Reply #3 on: 22 Mar 2010, 13:36:55 »
Well, one thing it doesn't say is what the numbers represent.
Presumably the first number is a fraction of 1 second, second and third numbers maybe a fraction of a metre.

Just a guess though, then of course you start again with the next set of 3 numbers ... etc.


Planck
I know a little about a lot, and a lot about a little.

Offline Dajan

  • Members
  • *
Re: Defining recoil
« Reply #4 on: 22 Mar 2010, 13:49:27 »
Well I got as far as:-
No1 - pass
No2 - 0=no movement, 1=as much vertical ditplacement as possible
No3 - 0=ditto, 1= ditto for horizontal motion.
While those three seem to be instant the second set take place after the shot and are a slower climb.
This doesn't seem to fit what we were told on BIKI, so I'm wondering if people have actually worked on this or if they've simply toyed with the presets?

Offline Planck

  • Honoured
  • Former Staff
  • ****
  • I'm never wrong ....I'm just not always right !
Re: Defining recoil
« Reply #5 on: 22 Mar 2010, 19:57:16 »
Definition in the bin.pbo config for cfgRecoils:
Code: [Select]
class CfgRecoils
{
 access = 1;
 empty[] = {};
 impulse[] = {0.03,0.02,0.2,0.08,0.08,0.8,0.1,0.03,-0.1,0.3,0,0};
};

The config from weapons.pbo has a further 81 examples, specific to individual weapons and positions (prone for example).

Additional examples for the ksvk and m107 exist also.


Planck
I know a little about a lot, and a lot about a little.

Offline Dajan

  • Members
  • *
Re: Defining recoil
« Reply #6 on: 23 Mar 2010, 01:22:24 »
Ok, I'll have a look, see what i can decipher.
Ta!