[Not ZDoom] [2.1.7] Reloding effect doesn't work properly

Bugs that have been investigated and resolved somehow.

Moderator: Developers

[2.1.7] Reloding effect doesn't work properly

Postby The NUtcracker » Tue Mar 20, 2007 5:18 pm

It's only on the easiest difficulty. Not as though this would really effect anyone, as almost every doomer plays UV. :D

What happens is it doesn't take out enough ammo when you reload.
Let's say you have a reloading pistol that has 6 bullets in it and you reload it. When you do, it only takes 3 ammo from your inventory.

But, as I said, this is only the easiest skill level.
User avatar
The NUtcracker
I refuse to create a custom title.
 
Joined: 14 Jan 2007
Location: South Dakota

Postby Zippy » Tue Mar 20, 2007 5:24 pm

My reloading stuff works absolutely fine. It's probably a problem with how you set yours up.
User avatar
Zippy
Scathing political commentary!
 
Joined: 23 Mar 2005
Location: Rochester

Postby The NUtcracker » Tue Mar 20, 2007 5:26 pm

Was it on easiest skill (I'm too young too die!)?

That's the only skill that has the problem.
User avatar
The NUtcracker
I refuse to create a custom title.
 
Joined: 14 Jan 2007
Location: South Dakota

Postby Zippy » Tue Mar 20, 2007 5:27 pm

Yes.
User avatar
Zippy
Scathing political commentary!
 
Joined: 23 Mar 2005
Location: Rochester

Postby Graf Zahl » Tue Mar 20, 2007 5:34 pm

This is directly related to the ammo doubling in this skill and can't be changed because it would break the skill level as it is.
User avatar
Graf Zahl
 
Joined: 19 Jul 2003
Location: Germany

Postby The NUtcracker » Tue Mar 20, 2007 5:36 pm

@Zippy I'm uploading a video of me demonstrating the bug in Zen dynamics. Watch the ammo that is loaded into the gun. It loads 6 bullets into the gun, but only 3 were taken out of your inventory. The recording was in GZDoom, but I tried it in ZDoom, and the exact same thing happened.
User avatar
The NUtcracker
I refuse to create a custom title.
 
Joined: 14 Jan 2007
Location: South Dakota

Postby randi » Tue Mar 20, 2007 5:47 pm

Without seeing your implementation, the only thing I can conclude is that you didn't account for the double ammo players receive in baby and nightmare modes.
User avatar
randi
Site Admin
 
Joined: 09 Jul 2003

Postby The NUtcracker » Tue Mar 20, 2007 5:57 pm

User avatar
The NUtcracker
I refuse to create a custom title.
 
Joined: 14 Jan 2007
Location: South Dakota

Postby Penguinator » Tue Mar 20, 2007 7:12 pm

The NUtcracker wrote:Done: http://www.sendspace.com/file/91oam3


I didn't download that as my computer is about to explode from lack of RAM but did you even see randy and Graf's posts. Now that you think about it, their reasons make perfect sense....
User avatar
Penguinator
Resurrect
 
Joined: 22 May 2006
Location: Hell

Postby Vaecrius » Tue Mar 20, 2007 7:18 pm

Apparently it happens anytime you have A_GiveInventory and ammo... I haven't tried it yet, but I suppose substituting an ACS equivalent would fix this?
User avatar
Vaecrius
Team Bad Allocation, blast off at the speed of light!
 
Joined: 04 Jan 2004
Location: Gotham City SAR, Wyld-Lands of the Lotus People, Dominionist PetroConfederacy of Saudi Canadia

Postby The NUtcracker » Tue Mar 20, 2007 7:20 pm

none wrote: didn't download that as my computer is about to explode from lack of RAM but did you even see randy and Graf's posts. Now that you think about it, their reasons make perfect sense....


That wasn't the point of posting it. I posted it to prove to Zippy that the bug does exist. Didn't you read my post? Or did I forget to mention it in my post?
User avatar
The NUtcracker
I refuse to create a custom title.
 
Joined: 14 Jan 2007
Location: South Dakota

Postby randi » Tue Mar 20, 2007 7:31 pm

And we're saying this is a bug with your implementation, not with ZDoom.
User avatar
randi
Site Admin
 
Joined: 09 Jul 2003

Postby Vaecrius » Tue Mar 20, 2007 7:35 pm

Well, I just tested the ACS and it does the same thing. And simply dividing the number by two doesn't work since that rounds down to zero, so the only thing left is a script that checks the skill and then takes away one unit of ammo...
User avatar
Vaecrius
Team Bad Allocation, blast off at the speed of light!
 
Joined: 04 Jan 2004
Location: Gotham City SAR, Wyld-Lands of the Lotus People, Dominionist PetroConfederacy of Saudi Canadia

Postby The NUtcracker » Tue Mar 20, 2007 7:40 pm

randy wrote:And we're saying this is a bug with your implementation, not with ZDoom.


*groans* I hate it when I forget to put something in my posts. (in this case, it was that I understand that it wasn't ZDoom's doing.)
User avatar
The NUtcracker
I refuse to create a custom title.
 
Joined: 14 Jan 2007
Location: South Dakota

Postby Zippy » Tue Mar 20, 2007 11:30 pm

Vaecrius wrote:Well, I just tested the ACS and it does the same thing.

For reference, this is basically what I use, and I have tested it (in 2.1.7 and SVN r492, which is the latest I have), and it does work correctly on all skill levels:
Code: Select allExpand view
if ( weapon == PISTOL ) {
   missing = PISMAX - CheckInventory("PistolAmmo");
   // Either you have enough backup ammo to fill what is missing
   // or you don't
   if ( CheckInventory("Clip") >= missing ) {
      // Have enough to fill
      TakeInventory("Clip",missing);
      GiveInventory("PistolAmmo",PISMAX);
   } else {
      // Don't have enough to fill
      GiveInventory( "PistolAmmo", CheckInventory("Clip") );
      TakeInventory("Clip",PISMAX);
   }
}
User avatar
Zippy
Scathing political commentary!
 
Joined: 23 Mar 2005
Location: Rochester

Next

Return to Closed Bugs

Who is online

Users browsing this forum: No registered users and 0 guests