Jump to content
The Dark Mod Forums

Blackjacking hit detection


At0mic

Recommended Posts

I believe some of the upset is helpful suggestions are being met with arguments instead of appreciation.

 

It's easy in my opinion to see how far away you can be, just swing much earlier than you imagine you might reach, move closer if missed, do it again, once you hit, they'll drop like a bag of rocks and voilà, realization one doesn't need to be close at all, the area is huge, and there's no chance of getting close enough for them to hear, or bump into them.

 

I realize I'm likely to be quoted and another argument will be made why my insight isn't as useful as a suggestion for someone to spend their time and money changing it. I imagine even if it were altered in some fashion, those who are making it hard on themselves and stubbornly refuting insights on how to adapt so it's easy, will continue to make it hard on themselves. Past behavior is the best predictor of future actions. The question is whether to enjoy playing the game, or spend time posting more of the same sentiments again, that have been repeated over and over, to the point of having lost credibility and/or compassion in those who might desire to help.

 

In more useful info, according to the recent forum poll, about half people ghost, and half knock out or kill AI. Anecdotally, it seems many begin playing by knocking out, then realize it's not as challenging without AI around, so as they get more sneak skills might switch to ghosting. So apparently a majority of the player base has little trouble knocking out AI, but presumably enough challenge so it's fun instead of boring.

"The measure of a man's character is what he would do if he knew he never would be found out."

- Baron Thomas Babington Macauley

Link to comment
Share on other sites

Also, it seems to differ from guards without helmets, which are KO'able from nearer distance (it seems) than for guards with helmets, for which you have to keep a larger distance. Might be wrong,

 

 

 

No, you're correct. With helmets, you have to hit the base of the neck, rather than the head, which means you do need to be a bit further back. With AI that don't have helmets you can hit the base of the neck OR the top of the head and both will succeed.

Link to comment
Share on other sites

That's not a good comparison. Rather like in the new Thief when you aim an arrow at the head of an unsuspecting guard you can make a headshot, but if you do the same when he is alerted you magically will never hit his head! The same goes for the helmeted guards, tell me what you want, alerting them is magically making them immune.

 

It probably isn't a great comparison, though my intention was to highlight that sometimes, we just accept things as how the game operates. There is a grace period while an alert state ramps up, just last night while I was testing a mission, I managed to blackjack a guy who was facing me, halfway through drawing his weapon while I was standing in front him, as he hadn't gone into immunity yet. Have you tried the blackjack training map?

Intel Sandy Bridge i7 2600K @ 3.4ghz stock clocks
8gb Kingston 1600mhz CL8 XMP RAM stock frequency
Sapphire Radeon HD7870 2GB FLeX GHz Edition @ stock @ 1920x1080

Link to comment
Share on other sites

You have to understand that the Dark Mod's current implementation simulates a straightforward blackjack hit and nothing more.

 

Normally, in game design, you would want to abstract the whole blackjacking system to a result that is more or less permissive based on the character you play, of course a master thief is going to be able to blackjack someone from a short distance. In reality, the closer you'd get, the more chances you'd have to manage the takedown, that's because a master thief is going to find their way around the helmet and armor to find a sweet spot on their own. Normally, then, you'd add some behavioral code to take that into account as well as adding more or less lenience based on the fact that the player character is (or is not) a skilled thief.

 

The Dark Mod doesn't abstract the blackjacking as a system, for both the sakes of player agency and simplicity, so it (correct me if I'm wrong) simply registers a hit where the physical blackjack object intersects with the AI model. That way, it leaves the blackjacking abstraction to the player, requiring them to learn the sweet spot and what the conditions for a successful hit are without making any assumptions on the level of skill the player character is supposed to have.

 

I personally wouldn't mind a different code path that doesn't take the precise location of the hit into account when you're KO'ing really close to an AI but other people who learned how to reliably blackjack might not think the same way.

Edited by Briareos H
Link to comment
Share on other sites

I wouldn't be opposed to a longer hit box that allows the player to stand closer to the AI, as long as it didn't allow the player to succeed from angles they aren't supposed to. I'm not exactly sure how the code registers the collision atm.

Link to comment
Share on other sites

The thing I believe to be the cause of the complaints is this, if the player bumps into the AI from behind, or fails to hit the sweetspot on the first hit, the blackjack immunity ramps up instantly. I mean, snap of the finger instant, the cones disappear immediately. There is no grace period between the time of the collision and the time the AI spins around to see who or what bumped or hit them.

 

Anywhere between a 1 to 2 second grace period to allow for a bump, a missed blackjack, etc, would likely alleviate the complaints. It would help simulate a brief moment of confusion or being startled.

 

I actually didn't realize the immunity kicked in immediately until I checked. I thought the immunity didn't kick in until the AI spun around, identified the player / drew their weapon if they had one.

Link to comment
Share on other sites

Longer hit box on the blackjack? That would probably lead to hitting door frames and ceilings again.

 

I mean longer up the player's arm, so it can't overshoot as easily. But I'm assuming that the blackjack has a box cm, rather than a single point, which might not be accurate.

 

Anywhere between a 1 to 2 second grace period to allow for a bump, a missed blackjack, etc, would likely alleviate the complaints. It would help simulate a brief moment of confusion or being startled.

 

I don't see why players should get a second chance if they bump into the AI or fail to hit them in the right spot. Those are both pretty significant ways to fail.

 

edit: see image below. The red box simulates our current hit-detection. In the image below, that red area would overshoot the back of the head and the player would fail. If we extended the box to cover the blue area, then it would succeed. Again, assuming that the blackjack collision works like the sword does...I'm not sure if that's the case.

post-9-0-62287600-1397174374_thumb.jpg

  • Like 1
Link to comment
Share on other sites

Anywhere between a 1 to 2 second grace period to allow for a bump, a missed blackjack, etc, would likely alleviate the complaints. It would help simulate a brief moment of confusion or being startled.

 

The only thing that's changing, though is the addition of the 1-2 second grace period. We're not talking about delaying everything related to a failed KO, right? The AI will still bark and turn and draw a weapon on his old timetable.

 

I actually didn't realize the immunity kicked in immediately until I checked. I thought the immunity didn't kick in until the AI spun around, identified the player / drew their weapon if they had one.

 

Immunity depends on alert level. Since alert level changes immediately, immunity is affected immediately. While we need to continue to allow alert level to change immediately, we can afford to wait some random time between 1 and 2 seconds before declaring immunity.

 

This only pertains to AI going from non-immune to immune. AI that have already arrived at immunity will apply that on the very first KO attempt.

Link to comment
Share on other sites

Immunity doesn't kick in immediately all the time though, as I've successfully KO'd guards after alerting them and others have as well.

Link to comment
Share on other sites

I don't see why players should get a second chance if they bump into the AI or fail to hit them in the right spot. Those are both pretty significant ways to fail.

 

I think it's a fair simulation of the AI temporarily being confused before they actually turn around and see the player.

 

You can check it out yourself and see how the current system looks.

 

tdm_ai_showko 1

 

Bump into the AI. The cone is gone before they have even turned around to identify the player or drawn their weapon to signify that they are on high alert. Personally, I feel that reaction is a tad too superhuman.

Link to comment
Share on other sites

The only thing that's changing, though is the addition of the 1-2 second grace period. We're not talking about delaying everything related to a failed KO, right? The AI will still bark and turn and draw a weapon on his old timetable.

 

Yes, exactly. The delay would not affect the AI behavior, it's simply a 1 to 2 second delay in the cone disappearing. The AI will still turn around and draw their weapon. The player may still get their head served on a platter.

Link to comment
Share on other sites

But I'm assuming that the blackjack has a box cm, rather than a single point, which might not be accurate.

 

It appears that there's a cm box. These numbers assume the blackjack is horizontal, pointing in the Y direction.

 

"att_cm_maxs_overhead" "2.5 27 5"
"att_cm_mins_overhead" "-2.5 5 -5"

Link to comment
Share on other sites

Immunity doesn't kick in immediately all the time though, as I've successfully KO'd guards after alerting them and others have as well.

 

Here's the sequence, which happens all in the same frame:

 

Hit by blackjack->Do damage->Check for KO->Raise alert level if not KO'ed

 

The first blow won't have the immunity protection that comes from the alert level, but subsequent blows will.

 

As for KO'ing alerted guards, that depends on their alert level and whether they're wearing helmets or not, and where their "I'm immune above this alert level" setting is. Since alert levels come down over time, it's possible that an unhelmeted guard is immune for a while, but becomes non-immune later. You should be able to knock him out, but only from behind.

 

If you've KO'ed a helmeted guard carrying his weapon around, then it's a bug, because they're supposed to be immune in that state. I just read the code again, and the only way to KO such a guard is if they're marked as a civilian.

 

Edit: Or you drop a real heavy crate on their head from a distance. (IIRC) :ph34r:

Link to comment
Share on other sites

Now that I think about this a bit more, I doubt that anyone who can't land the first blow is no way in H**L going to be able to land a second or third. That head is going to be moving.

 

They might. The CM for the blackjack gives the player a little more width in order to compensate for some of the twitchyness we ran into prior to release 1.05. I can't remember the exact details, but I think it had to do with the CM's on the heads of the AI not being entirely accurate. Unlike the old Thief games where you could hit the AI anywhere on their body, TDM has greatly reduced the target area.

Link to comment
Share on other sites

edit: see image below. The red box simulates our current hit-detection. In the image below, that red area would overshoot the back of the head and the player would fail. If we extended the box to cover the blue area, then it would succeed. Again, assuming that the blackjack collision works like the sword does...I'm not sure if that's the case.

 

I'll try setting that up.

 

EDIT:

 

Ok, I tried that and unfortunately it still fails when you get too close. I extended the CM right down the arm. I seem to recall ishtvan saying something about the outer surface of the CM needing to make contact with the KO cone, but when you're too close the blackjack CM somehow passes through the AI instead of the surface of the CM hitting the ko zone. :wacko:

 

I wonder if it's possible to treat the CM as a volume instead so that as long as the ko cone is inside of the volume it will count as a hit? Not really sure what I'm talking about here, but visually when I swung at the AI with the extended CM, it certainly looks like I should have gotten a ko.

Link to comment
Share on other sites

Bump into the AI. The cone is gone before they have even turned around to identify the player or drawn their weapon to signify that they are on high alert. Personally, I feel that reaction is a tad too superhuman.

 

If I was on patrol and had someone suddenly bump into me from behind, I think I'd immediately be pretty damn alert.

 

But even in gameplay terms, why should the player get a do-over (a chance to swing again) if they've bumped into an AI? I don't see any particular rationale for it. It's a clear fail, and you should have to deal with the consequences.

 

If you've KO'ed a helmeted guard carrying his weapon around, then it's a bug

 

 

I wasn't saying that. I've KO'd guards who I've alerted within a second or two of alerting them, so there is a short grace period already. It's not uncommon for a guard to be alerted as I come up behind him, he detects me and spins around, and I bash him in the face and knock him out. I can't recall exactly what the circumstances are--whether it happens with helmeted guards, or exactly what kind of alert it was, but it's not infrequent. I'm sure an industrious person could find a few examples on Youtube.

Link to comment
Share on other sites

Bump into the AI. The cone is gone before they have even turned around to identify the player or drawn their weapon to signify that they are on high alert. Personally, I feel that reaction is a tad too superhuman.

 

That's exacltly what I meant and a short delay would be great there! Also we are not normally talking about just bumping into the AI, but doing so because the blackjacking wasn't perfect. As my video shows, you can land several better ones until the AI even turns around but right now this wouldn't help because it is already immune...

Edited by wesp5
Link to comment
Share on other sites

But even in gameplay terms, why should the player get a do-over (a chance to swing again) if they've bumped into an AI? I don't see any particular rationale for it. It's a clear fail, and you should have to deal with the consequences.

 

Yeah, it's fair if it's a genuine black jack failure but from what people have been saying and replicating it in my tests, I don't think it's as much user failure as it is a failure of the system. When I've been standing closer to the AI, visually I can see no reason why the blackjack would fail so I can totally understand why players are having trouble with this.

 

I was looking back at my notes from the 1.05 blackjack revamp and there is still the remaining issue of the AI head CM's not registering a blackjack when the player is closer and I think that is the main reason why people are failing and succumbing to angry / immune AI. I don't think the player should be punished for a short coming in the system, however I don't want to cripple the system either. It would be nice to have it fixed correctly, but how much work is that? That's why I suggested the grace delay in situations where the player fails due to this crack in the system.

 

I certainly don't want to cripple the system but I don't think it should be ignored either.

 

Two options:

 

1. A slight grace period to compensate for the system in those instances (likely the easier / faster fix)

2. Someone takes a look at the CM functionality for the AI's heads to see if we can plug the cracks.

 

We didn't have the full source code back when the 1.05 revamp happened so maybe there is a way to prevent the fail from happening now that we have all the CM data. Unfortunately, the bulk of this work would likely rely on Grayman as I don't have the C++ knowledge to rewrite something like this.

 

 

 

That's exacltly what I meant and a short delay would be great there! Also we are not normally talking about just bumping into the AI, but doing so because the blackjacking wasn't perfect. As my video shows, you can land several better ones until the AI even turns around but right now this wouldn't help because it is already immune...

 

Either a short delay or a fix for the core issue

Link to comment
Share on other sites

Another idea is a check for distance to the AI, and if the AI is within a certain bound in the arc path, it uses a different animation that has the blackjack hitting closer, what it should assume would be the proper target for an AI that close. It's plausible in the sense in real-life you'd adjust your arc to the sweet-spot depending on distance to the target.

 

Edit: A drawback is player expectation. If you change the animation over different cases, the player might not be confident what he's going to hit or how to approach an AI. That might not be a real problem in practice, though, as the animation only changes in the special case where it's obvious he wants to use the blackjack to hit the head & is too close.

 

Edit2: Second drawback is a perception of contextual handholding, where the game is making an adjustment for them, rather than trusting the player to figure it out themselves over time.

What do you see when you turn out the light? I can't tell you but I know that it's mine.

Link to comment
Share on other sites

Another idea is a check for distance to the AI, and if the AI is within a certain bound in the arc path, it uses a different animation that has the blackjack hitting closer, what it should assume would be the proper target for an AI that close. It's plausible in the sense in real-life you'd adjust your arc to the sweet-spot depending on distance to the target.

 

That would require creating a whole new animation as a work around for a bug in the head collision system and it would no doubt take a few tries to find an animation that works. It would be less work to add a delay or fix the issue I think as the problem itself isn't rooted in the swing animation but rather how the CM system is failing on the head.

 

I was thinking last night that moving the ko cone either forward or upward a tiny bit might help to alleviate the issue, since more of the head would then be covered by the cone...not sure about that though.

Link to comment
Share on other sites

Yeah, it's fair if it's a genuine black jack failure but from what people have been saying and replicating it in my tests, I don't think it's as much user failure as it is a failure of the system. When I've been standing closer to the AI, visually I can see no reason why the blackjack would fail so I can totally understand why players are having trouble with this.

 

If that's true, then we should fix that problem rather than adding a new grace period. I'm not convinced that the problem is a big one, however. Once people learn to stay further back, the problem is solved. We do get some people complaining about the difficulty of blacjacking, but it's not like it's a constant flow of people. It's like hitting doorframes when you try to swing--in an ideal world that wouldnt' happen, but it's tricky to fix and can easily be avoided by just learning the system.

 

there is still the remaining issue of the AI head CM's not registering a blackjack when the player is closer

 

What exactly is the issue? The CM makes a proper impact but it doesn't register as an impact?

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.


  • Recent Status Updates

    • Petike the Taffer

      I've finally managed to log in to The Dark Mod Wiki. I'm back in the saddle and before the holidays start in full, I'll be adding a few new FM articles and doing other updates. Written in Stone is already done.
      · 4 replies
    • nbohr1more

      TDM 15th Anniversary Contest is now active! Please declare your participation: https://forums.thedarkmod.com/index.php?/topic/22413-the-dark-mod-15th-anniversary-contest-entry-thread/
       
      · 0 replies
    • JackFarmer

      @TheUnbeholden
      You cannot receive PMs. Could you please be so kind and check your mailbox if it is full (or maybe you switched off the function)?
      · 1 reply
    • OrbWeaver

      I like the new frob highlight but it would nice if it was less "flickery" while moving over objects (especially barred metal doors).
      · 4 replies
    • nbohr1more

      Please vote in the 15th Anniversary Contest Theme Poll
       
      · 0 replies
×
×
  • Create New...