Duke4.net Forums: Hitboxes in Duke Nukem 3d - Duke4.net Forums

Jump to content

Page 1 of 1
  • You cannot start a new topic
  • You cannot reply to this topic

Hitboxes in Duke Nukem 3d  "Is it just me or...?"

#1

One reason why I never liked Duke Nukem 3D quite as much as Doom is that something feels off about the gunplay. I am still not quite sure I can put the finger on what it is, although as I was recently replaying Duke Nukem 3D in preparation for Ion Maiden, I did notice that shots did not always seem to land. For example, it takes sometimes several direct shots of the Shrinker to cause the target to shrink; I have also seen rockets going through a Fat Commander or a Mini-Battlelord. Is it a known vanilla issue with the Build engine? If so, has it been solved for Ion Maiden?
2

User is offline   MusicallyInspired 

  • The Sarien Encounter

#2

I've never run into any of those problems. Duke3D always felt good to me. Am I crazy?

This post has been edited by MusicallyInspired: 25 February 2019 - 06:21 AM

1

User is offline   Zaxx 

  • Banned

#3

View PostMusicallyInspired, on 25 February 2019 - 06:21 AM, said:

I've never run into any of those problems. Duke3D always felt good to me. Am I crazy?

Disable autoaim and you will see some of that. :) Really the heart of the problem must be that Duke 3D was made with autoaim in mind so once you get rid of that there will be a few problems with hitting those sprites.
0

User is online   Ninety-Six 

#4

You'll see some of it with autoaim too. Projectiles are a bit bugged.
0

User is offline   Zaxx 

  • Banned

#5

Yeah, now that you mentioned it I remember some projectiles not hitting when it comes to shooting vertically.
0

User is offline   Player Lin 

#6

That's why I never disable autoaim on these old games, even with source ports, it's how they were designed in the original time, unless the engine got changed to make it better for disabled autoaim...

But yeah...EDuke32 engine's autoaim acting weirdly on recent snapshot builds... :)

EDIT: Oh right, some projectiles also like to do no damage in the original if the position is "right"... it was annoying when happens but mostly it won't be a big problem, unless you're running out of ammo...

This post has been edited by Player Lin: 25 February 2019 - 09:16 AM

1

User is offline   NNC 

#7

Shrinker is the only weapon with this issue, particularly against minibosses, but it also sometimes hits a monster, the monster "bleeds" a bit (read: take the hit), but nothing else happens. It's still not a major issue with the game.

Doom had these minor problems too. I, for one, think the Revenant hitbox is extremely small.
0

#8

I've definitely had rockets go through things before now, but I always thought it was just a busted cstat flag for that particular monster. I do wonder if the weird movement interpolation plays a part, if you watch the monsters side-on you can see that they don't walk smoothly and instead 'appear' a few steps ahead at intervals, perhaps the hitbox doesn't quite line up with this at all times.
Doom's combat might seem to work better solely because it is comparatively primitive, your movement is certainly far more limited for one and things just don't seem to move quite as fast.
Dark Forces' combat always felt really solid to me, I dunno, shooting and punching things in that game just feels oddly satisfying. Meanwhile I'm certain some of my shots in Nitemare 3D go right through the enemy.

This post has been edited by High Treason: 25 February 2019 - 09:57 AM

0

#9

I'm not a programmer or something like that, but , as far i remember, i never run in these problems on the N64 version (ofc there are other types of problems), the hitboxes feel solid there and i think is made on Buld Engine aswell, isn't it?
If someone can find the difference inside the code between Pc and N64 may solve the mistery and fix it, if possible.


View PostNancsi, on 25 February 2019 - 09:47 AM, said:

Shrinker is the only weapon with this issue, particularly against minibosses, but it also sometimes hits a monster, the monster "bleeds" a bit (read: take the hit), but nothing else happens. It's still not a major issue with the game.

Sometimes can shrink 2 close monsters with one shoot too :).
0

#10

That's because the shrinker is technically a projectile with an explosion. That radius is the bane of my existence when building weird target-shooter machines in maps. As for shrinking enemies, that's its own whole world of strange goings on, like when enemies get stuck shrunk and attack you, but cannot be killed.
0

User is online   Danukem 

  • Duke Plus Developer

#11

Hitscan works fine, but projectiles have always been a bit buggy and can go right through sprites under certain conditions. The shrinker mentioned in the OP is a special case which is definitely not the fault of the Build engine, though. If you look at the source there is special hardcoding for it -- what it does it generate a special radiusexplosion which causes 0 damage in a small radius. The actual projectile itself does nothing. It's easy to see how that could fail to be detected by the sprite getting shot.

EDIT: was typing at the same time as High Treason

This post has been edited by Trooper Dan: 25 February 2019 - 11:57 AM

0

User is online   Ninety-Six 

#12

The pass-through is more likely to trigger if the targeted enemy is above or below the player.
0

#13

View PostTrooper Dan, on 25 February 2019 - 11:56 AM, said:

EDIT: was typing at the same time as High Treason


That's OK, your explanation was better anyway.


On the subject of projectiles doing things they shouldn't, there was also the issue of instakill lasers, but I think that only affected earlier versions of the game and was rare. That one itself is kinda strange because I think the effect of the FIRELASER is handled the same way (FRAMEEFFECT1) as with Duke's sprite when steroids are in use, the extra sprites shouldn't have that effect.
0

User is online   Danukem 

  • Duke Plus Developer

#14

View PostHigh Treason, on 25 February 2019 - 12:13 PM, said:

On the subject of projectiles doing things they shouldn't, there was also the issue of instakill lasers, but I think that only affected earlier versions of the game and was rare. That one itself is kinda strange because I think the effect of the FIRELASER is handled the same way (FRAMEEFFECT1) as with Duke's sprite when steroids are in use, the extra sprites shouldn't have that effect.


Not quite. For FIRELASER, there is a chain of sprites and each one has the picnum FIRELASER; so each one is literally a projectile, they are not just lookalikes. I noticed this when it caused scripting problems for me. I haven't looked into it but I presume it's something like a linked list, and the game has to be coded to only count impacts from the head of the list.
0

User is offline   Fox 

  • Fraka kaka kaka kaka-kow!

#15

The shrinker is a specific issue.

The shrinker is a projectile with an explosion radius. When the game calculates the distance between the projectile and enemy, it uses the coordinates located at the feet of the enemy (if you use the map editor, you are aware sprites are vertically position on their base). However when you use auto-aiming, it aims at the enemy chest height. Since the battlelord is taller than other enemies, the distance between it's auto-aiming center and base is greater than the shrinker radius.
0

User is online   Danukem 

  • Duke Plus Developer

#16

@Fox: that's true, but if the SHRINKSPARK is literally hitting the clipping sphere of the sprite and making it spawn blood, shouldn't that be handled as an automatic hit regardless of distance to the base of the sprite? Wouldn't it be easy to add that into the source code? As someone who contributes very useful features to Eduke32 yourself, maybe you have insight as to why this hasn't happened already. Modders like me are left scratching our heads, wondering why obvious stuff like that has never been done over the years.
0

User is offline   Fox 

  • Fraka kaka kaka kaka-kow!

#17

SHRINKSPARK is hard-coded to not cause direct damage.
0

User is online   Danukem 

  • Duke Plus Developer

#18

View PostFox, on 25 February 2019 - 01:32 PM, said:

SHRINKSPARK is hard-coded to not cause direct damage.


Yes, but why leave it that way? Just because it has always been that way? And as you know SHRINKSPARK doesn't cause actual damage, the radius sets htpicnum to SHRINKSPARK and it sets htextra to 0, and that gets detected as a hit because normally htextra is -1. A direct hit could also set htextra to 0 and it would get detected without causing damage.

This is why I asked the question: what is the rationale behind which shortcomings get fixed and which don't? Is the goal to make EDuke32 gameplay identical to DOS Duke? (it's not by the way).
0

#19

View PostHigh Treason, on 25 February 2019 - 09:55 AM, said:

Doom's combat might seem to work better solely because it is comparatively primitive, your movement is certainly far more limited for one and things just don't seem to move quite as fast.


I suppose. Still, to me, the best of both worlds is still Doom mods like Samsara and the sadly 3DGE-exclusive Duke It Out In Doom, which allow you to use a fairly faithful recreation of Duke's arsenal.
0

User is offline   Fox 

  • Fraka kaka kaka kaka-kow!

#20

View PostTrooper Dan, on 25 February 2019 - 01:45 PM, said:

Yes, but why leave it that way? Just because it has always been that way? And as you know SHRINKSPARK doesn't cause actual damage, the radius sets htpicnum to SHRINKSPARK and it sets htextra to 0, and that gets detected as a hit because normally htextra is -1. A direct hit could also set htextra to 0 and it would get detected without causing damage.

This is why I asked the question: what is the rationale behind which shortcomings get fixed and which don't? Is the goal to make EDuke32 gameplay identical to DOS Duke? (it's not by the way).

This would be too much of a change on gameplay. If it depended on me, gameplay would be identical to DOS (except on extreme cases)
0

User is offline   Fox 

  • Fraka kaka kaka kaka-kow!

#21

View PostHigh Treason, on 25 February 2019 - 09:55 AM, said:

I do wonder if the weird movement interpolation plays a part, if you watch the monsters side-on you can see that they don't walk smoothly and instead 'appear' a few steps ahead at intervals, perhaps the hitbox doesn't quite line up with this at all times.

Interpolation is done purely on the visual side, it does touch the "real" coordinates of the sprites.
0

#22

By real co-ordinates you mean where the enemy actually is and not where it appears to be? Because that could definitely explain projectiles appearing to go right through them sometimes.

View PostTrooper Dan, on 25 February 2019 - 12:19 PM, said:

Not quite. For FIRELASER, there is a chain of sprites and each one has the picnum FIRELASER; so each one is literally a projectile, they are not just lookalikes. I noticed this when it caused scripting problems for me. I haven't looked into it but I presume it's something like a linked list, and the game has to be coded to only count impacts from the head of the list.


Ah, I'd assumed it was 'FRAMEEFFECT1' taking on a new htpicnum and not an actual picnum, and that this would be handled differently.
0

User is offline   Player Lin 

#23

View PostNancsi, on 25 February 2019 - 09:47 AM, said:

Doom had these minor problems too. I, for one, think the Revenant hitbox is extremely small.



Revenant is weird by design...

Posted Image
Source of this picture.

Its sprite is 92px high but its actor height just only 56(and 51px of width in sprite, but only 20 "radius" => 40 actual width), so his(?) hitbox is small than what you see.

Who know why id did this weird thing?...maybe make it more dangerous or something, but it looks silly once you know its actual hitbox is smaller than its sprite or when you see its sprite got cut off in ports with OpenGL renderer when the celling is higher than 56 but lower than 92. (Some other monsters in DooM 1/2 also suffers this but Revenant is most obvious one.)

This post has been edited by Player Lin: 26 February 2019 - 08:57 AM

1

User is offline   Gargoyle 

#24

The gunplay is definitely quirky sometimes.

- Some ambushing enemies immune to projectiles and splash damage.

- Shoot a falling enemy with RPG while autoaim is enabled -> projectile misses the target but hits anyways.

- Splash damage doesn't trigger barrel chain reaction of explosions.

- The "falling" explosion sprites of Devastator missiles.

- Sometimes in E2L1 a single shotgun blast can take out the two Assault Troopers near the pipe bomb secret.

- In E3L8, Shooting the Assault Captain with RPG instantly kills one of the ambushing Mini Battlelords in the front desk room.
2

Share this topic:


Page 1 of 1
  • You cannot start a new topic
  • You cannot reply to this topic


All copyrights and trademarks not owned by Voidpoint, LLC are the sole property of their respective owners. Play Ion Fury! ;) © Voidpoint, LLC

Enter your sign in name and password


Sign in options