What always surprises me about reloading in FPS games is how fast it goes. People can reload their gun consistently in one or two seconds while walking, running, even climbing up ladders... pretty amazing!
I have noticed the problem. Some games are slower than others. Some won't even let you change your mind once you start. Some will, but you have to start again from scratch. I think at least one would actually remember you taking the magazine out and let you resume from there when you switched back.MarsProbe said:I can't say I've ever noticed reloading to be a problem. Just make sure you always have a full clip and you'll be fine, I'm sure.
In the firing routine:Supernova2000 said:If magazine >0 then you only need to replace the magazine because there's still 1 bullet in the chamber. If magazine = 0 then you need to replace the mag AND pull the firing pin because, since it was empty, you have to chamber the 1st bullet. The only game's I've played that get this right are the Call of Duty series, Rainbow 6 Vegas 2 and Crysis.
In reload:*weapon=>chambered = 0;
animate_bolt_back(weapon_type);
if ( *weapon=>magazine )
{
if ( *weapon=>mag_ammo )
{
*weapon=>mag_ammo--;
animate_bolt_forward(weapon_type);
*weapon=>chambered = 1;
}
}
else animate_bolt_forward();
Okay, so it's a little more complicated than that if you don't want the whole game-world to freeze up while you reload, but that's pretty much it. Work out your own timing issues, damn you. I'm not getting paid for this, you know!if ( *weapon=>magazine )
{
animate_remove_mag(weapon_type);
*weapon=>magazine = 0;
*ammo_pool=>ammo_type += *weapon=>mag_ammo;
}
if ( !*weapon=>magazine )
{
animate_fit_mag(weapon_type);
*weapon=>magazine = 1;
*weapon=>mag_ammo = *next_mag=>ammo_type;
if ( *ammo_pool=>ammo_type > mag_capacity=>ammo_type )
{
*next_mag=>ammo_type = mag_capacity=>ammo_type;
}
else
{
*next_mag=>ammo_type = *ammo_pool=>ammo_type;
}
*ammo_pool=>ammo_type -= *next_mag=>ammo_type;
}