Author Topic: Making fire rate slower, and making it semi-auto  (Read 516 times)

Does anyone know about how and where I can put/do this? I was toying around with Gravity Cat's CX-32, and I do wonder, how to make it, semi-auto and making it to act like a bolt action sniper.

Please help me, cause I really want to learn how to code and stuff, and I figured that GCat's CX-32 was an greate example to start with.

Thanks!

Modify the stateTimeout values for the Fire state names.

I don't recommend learning with the CX32 because all of the code is in one line without any white space and it's extremely hard to read.

Modify the stateTimeout values for the Fire state names.

I don't recommend learning with the CX32 because all of the code is in one line without any white space and it's extremely hard to read.

stateTimeout? Does that make it semi-auto like a bolt action? Cause I am wanting it to have a certain amount of time before you are able to fire again

I find it, somewhat hard to read, but I figure stuff out anyway! :D
« Last Edit: August 26, 2013, 01:49:28 PM by bangbang »

stateTimeout? Does that make it semi-auto like a bolt action?

I find it, somewhat hard to read, but I figure stuff out anyway! :D

The thing you want to edit is the time outs between states, such as Fire, Reload, Ready. Between the correct states, the timeout determines a timeout in (seconds?). Change the right timeout to make it delay the fire rate. States vary on the weapon.

The thing you want to edit is the time outs between states, such as Fire, Reload, Ready. Between the correct states, the timeout determines a timeout in (seconds?). Change the right timeout to make it delay the fire rate. States vary on the weapon.

Well, I am not wanting to be able to hold the button down to make it fire again, but I want to click again to fire next shot, if this is what its leading too?

There should be a state in there after "Fire". There, you'll want to add stateTransisitionOnTriggerUp[stateNumber] = "firstStateNameBeforeFire"; and remove stateTransition[stateNumber] = "stateName"; or stateTransitionOnTimeout[stateNumber] = "stateName"; You'll probably still want to edit some timeout values as well.

There should be a state in there after "Fire". There, you'll want to add stateTransisitionOnTriggerUp[stateNumber] = "firstStateNameBeforeFire"; and remove stateTransition[stateNumber] = "stateName"; or stateTransitionOnTimeout[stateNumber] = "stateName"; You'll probably still want to edit some timeout values as well.

I see, but I've encounterd another problem.

I made a Tavor-21, and it has 20 in it's magazine, but when I fire the CX-32 for abit, and switch back to the Tavor-21, it has a maximum amount of ammo, equal to the CX-32 (30 rounds)