Author Topic: Overheat Script  (Read 1319 times)

Could someone create a simple script that would automatically refill the ammo of a weapon, at a constant rate of about one per half second or so, up to 20 units (bullets)? The weapon will deplete the ammunition, "heating" the weapon, and cool/overheat upon reaching 0 units, though i can make that part with ease.

edit: (i guess i should have placed this in coding help)

So like the ammo from the Apache and the heating thing from the old LMG in T+T?

yeah, i think so. its the only thing i need for my new weapon now other than the impact explosion

Couldn't you do it by having ammo for the gun that refills when you don't use it, and when it runs out of "ammo", you have it play an animation.
Keep in mind I can't code so I don't know anything.

whoops didn't read the op
« Last Edit: October 19, 2011, 03:15:21 PM by Mr.jacksaunt »

that's exactly what I seek to accomplish, at least if anyone can help me out
« Last Edit: October 19, 2011, 12:08:17 AM by Midway Sentinel »

ok, this is under the onFire datablock, would it work?

Code: [Select]
  if(%obj.toolAmmo[%obj.currTool] < 20)
  {
  %obj.toolAmmo[%obj.currTool] ++ 1;
  return %p;
  }

Essentially, like the weapons from mass effect?

i personally never played Mass Effect, though it looks incredible

(script approval, anyone?)

Instead of saying "would this work?" actually implement it into your code, try it out, and when if it doesn't work, then come ask how you can change it so that it will work. You get a more immediate response that way.


ok, I've been looking though the LMG's script, and i get the part about tracking and fluctuating heat levels, but what part makes it actually "overheat" (like w/ animations and such)? and if there is none, how could it?

Don't flame me, Im not a scripter, but shouldn't this be made with some kind of variable?
I mean on fire in subscrables 1 from "heat", and when you stop firing, it will slowy charge up?
lol, BTW I guna make this with VCE :3