Jump to content

Welcome to Obsidian Forum Community
Register now to gain access to all of our features. Once registered and logged in, you will be able to create topics, post replies to existing threads, give reputation to your fellow members, get your own private messenger, post status updates, manage your profile and so much more. If you already have an account, login here - otherwise create an account for free today!
Photo

Suggestion: Include Discovered Traps in Path Finding?

traps pathfinding ai gameplay

  • Please log in to reply
20 replies to this topic

#1
secretmantra

secretmantra

    (1) Prestidigitator

  • Members
  • 10 posts

Hey guys,

 

Would anyone else like the ability to make discovered traps incorporate into the path finding, so that your characters can't accidentally set off traps they've already been discovered? (Or make this a setting we could turn on at least?)

 

This seems like it shouldn't be too hard to implement, and it would be quite helpful imo. 


  • Hertzila, Doppelschwert, illathid and 12 others like this

#2
Boeroer

Boeroer

    Arch-Mage

  • Members
  • 14009 posts
  • Location:Bucharest, Romania
  • Lords of the Eastern Reach Backer
  • Deadfire Backer
  • Fig Backer
  • Black Isle Bastard!

Yes, that would be neat. 



#3
Failedlegend

Failedlegend

    (2) Evoker

  • Members
  • 69 posts
  • Xbox Gamertag:Failed Legend

It was a bit aggravating that often times even when the game paused upon trap discovery (with my rogue in the front) it was often too late to stop the party from bumbling into it. So /signed


Edited by Failedlegend, 03 March 2017 - 01:20 PM.

  • TrueNeutral, mistermannindy and ThatUndeadLegacy like this

#4
JerekKruger

JerekKruger

    Arch-Mage

  • Members
  • 3366 posts
  • Pillars of Eternity Backer
  • Deadfire Backer
  • Fig Backer
  • Black Isle Bastard!

I'd love to see this added.



#5
Osvir

Osvir

    Arch-Mage

  • Members
  • 3799 posts
  • Location:Stockholm, SE
  • Pillars of Eternity Silver Backer
  • Kickstarter Backer
  • Lords of the Eastern Reach Backer
  • Deadfire Silver Backer
  • Fig Backer
  • Black Isle Bastard!
Larian Studios have a great coded solution in Divinity: Original Sin, might be business secrets or whatever, but are Obsidian and Larian friends? *wink wink*

#6
illathid

illathid

    (6) Magician

  • Members
  • 726 posts
  • PSN Portable ID:illathid
  • Pillars of Eternity Silver Backer
  • Kickstarter Backer
  • Deadfire Silver Backer
  • Fig Backer
  • Black Isle Bastard!

Larian Studios have a great coded solution in Divinity: Original Sin, might be business secrets or whatever, but are Obsidian and Larian friends? *wink wink*

 

I don't think you understand how game programming work. That's like saying Harley Davidson has a great exhaust system on it's motorcycles, maybe Ford could us it on their cars. 


  • Leferd and compleCCity like this

#7
mistermannindy

mistermannindy

    (1) Prestidigitator

  • Members
  • 41 posts
  • Location:Indianapolis USA
  • Pillars of Eternity Backer
  • Deadfire Silver Backer
  • Fig Backer
Signed. If the party can see the trap, they should be able to avoid it as they move past. Definitely harder to implement during battles, however.

#8
Yonjuro

Yonjuro

    (7) Enchanter

  • Members
  • 861 posts
  • Pillars of Eternity Silver Backer
  • Deadfire Backer
  • Fig Backer

I like this idea.  

 

Note that, unlike D:OS, there may be traps that are impossible to walk around and that adds a complication. What is the right answer? Blunder into the trap when it it is impossible to avoid? Have additional UI that tells the player that there is no route around the trap? Something else?


  • secretmantra likes this

#9
algroth

algroth

    (9) Sorcerer

  • Members
  • 1324 posts
  • Deadfire Backer
  • Fig Backer
  • Black Isle Bastard!

I would perhaps add the caveat that traps should not be recognized by pathing in mid-combat, as it might cause issues with positioning and might also remove a degree of challenge in specific occasions. It would also make sense from an in-game perspective: the characters might be focused on the enemy and might in turn ignore the trap right ahead of them, or be forced onto them. For out of combat moments it makes sense that they should be able to avoid traps, especially by pathing around them.

 

Personally I've always found traps as implemented in games like Baldur's Gate and Pillars of Eternity a mechanic that promotes save scumming, though. Activated a trap? No worries, just quick load, find it and deactivate it, and get some XP and loot on top of it. I can see how it can be fun and useful when using these against enemies, but used against the party it acts more as an unnecessary nuissance than a real challenge.


Edited by algroth, 03 March 2017 - 03:55 PM.

  • secretmantra likes this

#10
JerekKruger

JerekKruger

    Arch-Mage

  • Members
  • 3366 posts
  • Pillars of Eternity Backer
  • Deadfire Backer
  • Fig Backer
  • Black Isle Bastard!

Note that, unlike D:OS, there may be traps that are impossible to walk around and that adds a complication. What is the right answer? Blunder into the trap when it it is impossible to avoid? Have additional UI that tells the player that there is no route around the trap? Something else?

 

Same as when a door is closed between you party an the area you command them to walk to I'd say.



#11
compleCCity

compleCCity

    (1) Prestidigitator

  • Members
  • 31 posts
  • Location:Lower Saxony, Germany
  • Steam:compleCCity
  • Deadfire Silver Backer
  • Fig Backer

Well, Neverwinter Nights (I) had the feature to mark traps, so that party members wouldn't run into them. Well, Neverwinter Nights II (by Obsidian!) technically still had this feature, but it wasn't implemented in the game/UI mechanics anymore. So, you might guess how the developers possibly think about this topic … 8)

 

I do like the idea off a different handling during combat. Could be implemented with a change of the trap's difficulty grade in this specific situation. Same mechanics as in – really? – Neverwinter Nights II! Out of combat: automatic 20 – during combat: dice.

 

In general: supported!


  • secretmantra likes this

#12
algroth

algroth

    (9) Sorcerer

  • Members
  • 1324 posts
  • Deadfire Backer
  • Fig Backer
  • Black Isle Bastard!

 

Note that, unlike D:OS, there may be traps that are impossible to walk around and that adds a complication. What is the right answer? Blunder into the trap when it it is impossible to avoid? Have additional UI that tells the player that there is no route around the trap? Something else?

 

Same as when a door is closed between you party an the area you command them to walk to I'd say.

 

You can always try to disarm the trap, and choose to trigger it if you can't.


  • secretmantra likes this

#13
Osvir

Osvir

    Arch-Mage

  • Members
  • 3799 posts
  • Location:Stockholm, SE
  • Pillars of Eternity Silver Backer
  • Kickstarter Backer
  • Lords of the Eastern Reach Backer
  • Deadfire Silver Backer
  • Fig Backer
  • Black Isle Bastard!

 

Larian Studios have a great coded solution in Divinity: Original Sin, might be business secrets or whatever, but are Obsidian and Larian friends? *wink wink*

 

I don't think you understand how game programming work. That's like saying Harley Davidson has a great exhaust system on it's motorcycles, maybe Ford could us it on their cars. 

 

 

Of course. My point was that in Divinity: OS the followers of the main controlled character avoids hazardous areas (you can notice this very early in the game).



#14
JerekKruger

JerekKruger

    Arch-Mage

  • Members
  • 3366 posts
  • Pillars of Eternity Backer
  • Deadfire Backer
  • Fig Backer
  • Black Isle Bastard!

 

 

Note that, unlike D:OS, there may be traps that are impossible to walk around and that adds a complication. What is the right answer? Blunder into the trap when it it is impossible to avoid? Have additional UI that tells the player that there is no route around the trap? Something else?

 

Same as when a door is closed between you party an the area you command them to walk to I'd say.

 

 

You can always try to disarm the trap, and choose to trigger it if you can't.

 

Sure, but the question was how the path finding code should govern traps that completely block your path and my suggestion was that it should treat them the same way it treats closed doors that completely block your path i.e. your party will not pass through.

 

Of course, to make this work you'd need an option to trigger a trap that you can't disarm by clicking on it, since you wouldn't have the option of simply walking through it. Is that currently in PoE? I usually have a high Mechanics character who can disarm any trap so this isn't something I have to deal with.


  • secretmantra likes this

#15
illathid

illathid

    (6) Magician

  • Members
  • 726 posts
  • PSN Portable ID:illathid
  • Pillars of Eternity Silver Backer
  • Kickstarter Backer
  • Deadfire Silver Backer
  • Fig Backer
  • Black Isle Bastard!

 

 

Larian Studios have a great coded solution in Divinity: Original Sin, might be business secrets or whatever, but are Obsidian and Larian friends? *wink wink*

 

I don't think you understand how game programming work. That's like saying Harley Davidson has a great exhaust system on it's motorcycles, maybe Ford could us it on their cars. 

 

 

Of course. My point was that in Divinity: OS the followers of the main controlled character avoids hazardous areas (you can notice this very early in the game).

 

 

Yeah, but Obsidian and Larian being friends would have nothing to do with it. It's a question of whether it fits the design of game, and whether Obsidian can come up with an AI solution that's better than the alternatives. 



#16
Silent Winter

Silent Winter

    (10) Necromancer

  • Members
  • 1594 posts
  • Pillars of Eternity Backer
  • Deadfire Backer
  • Fig Backer

 

 

 

Note that, unlike D:OS, there may be traps that are impossible to walk around and that adds a complication. What is the right answer? Blunder into the trap when it it is impossible to avoid? Have additional UI that tells the player that there is no route around the trap? Something else?

 

Same as when a door is closed between you party an the area you command them to walk to I'd say.

 

 

You can always try to disarm the trap, and choose to trigger it if you can't.

 

Sure, but the question was how the path finding code should govern traps that completely block your path and my suggestion was that it should treat them the same way it treats closed doors that completely block your path i.e. your party will not pass through.

 

Of course, to make this work you'd need an option to trigger a trap that you can't disarm by clicking on it, since you wouldn't have the option of simply walking through it. Is that currently in PoE? I usually have a high Mechanics character who can disarm any trap so this isn't something I have to deal with.

 

Yes, that is currently how traps are handled if you can't disarm them - it asks if you'd like to trigger it (so you send the one most likely to avoid/reduce the effects of the trap)


  • algroth likes this

#17
Boeroer

Boeroer

    Arch-Mage

  • Members
  • 14009 posts
  • Location:Bucharest, Romania
  • Lords of the Eastern Reach Backer
  • Deadfire Backer
  • Fig Backer
  • Black Isle Bastard!

Larian Studios have a great coded solution in Divinity: Original Sin, might be business secrets or whatever, but are Obsidian and Larian friends? *wink wink*


I don't think you understand how game programming work. That's like saying Harley Davidson has a great exhaust system on it's motorcycles, maybe Ford could us it on their cars.

Of course. My point was that in Divinity: OS the followers of the main controlled character avoids hazardous areas (you can notice this very early in the game).

Yeah, but Obsidian and Larian being friends would have nothing to do with it. It's a question of whether it fits the design of game, and whether Obsidian can come up with an AI solution that's better than the alternatives.

Sharing knowledge about a piece of code in a game is not like trying to use a motorcycle part in a car. It's more like explaining how the motorcycle part works and then using this knowledge to build one that's fitting your car.
I'm pretty sure that OBS wouldn't try to copy & paste code. :)

I think it's pretty easy to exclude traps from the walkable area. Once you detect the trap it gets highlighted. This highlight sprite gets added to the scene and has a component (for example Collider2d in Unity) that prevents the player from stepping onto it. You could even play a special animation when going near to it. The trap itself has a collider to trigger the trap when you step on it, I presume, pretty simple. It would be like covering the trap with a seal - or like putting a chest or a man or any solid object on top of the trap so you can't step onto it.

You could also exclude the highlighted area from the walkable navigation mesh (NavMesh). But since those are baked most of the time it seems to be more complicated.

So, pretty easy to implement I guess. I can't say which other problems this may cause (blocking or something), but you could script or design around that I think.
Maybe they'll do it if we ask nicely.
  • secretmantra likes this

#18
Baltic

Baltic

    (3) Conjurer

  • Members
  • 162 posts
  • Deadfire Backer
  • Fig Backer

Note that, unlike D:OS, there may be traps that are impossible to walk around and that adds a complication. What is the right answer? Blunder into the trap when it it is impossible to avoid? Have additional UI that tells the player that there is no route around the trap? Something else?

 
Same as when a door is closed between you party an the area you command them to walk to I'd say.
 
You can always try to disarm the trap, and choose to trigger it if you can't.
 
Sure, but the question was how the path finding code should govern traps that completely block your path and my suggestion was that it should treat them the same way it treats closed doors that completely block your path i.e. your party will not pass through.
 
Of course, to make this work you'd need an option to trigger a trap that you can't disarm by clicking on it, since you wouldn't have the option of simply walking through it. Is that currently in PoE? I usually have a high Mechanics character who can disarm any trap so this isn't something I have to deal with.
Yes, that is currently how traps are handled if you can't disarm them - it asks if you'd like to trigger it (so you send the one most likely to avoid/reduce the effects of the trap)
Only on trapped containers though, currently you have to walk over traps on the floor to trigger them.
  • Silent Winter likes this

#19
Silent Winter

Silent Winter

    (10) Necromancer

  • Members
  • 1594 posts
  • Pillars of Eternity Backer
  • Deadfire Backer
  • Fig Backer

 

 

 

 

 

Note that, unlike D:OS, there may be traps that are impossible to walk around and that adds a complication. What is the right answer? Blunder into the trap when it it is impossible to avoid? Have additional UI that tells the player that there is no route around the trap? Something else?

 
Same as when a door is closed between you party an the area you command them to walk to I'd say.
 
You can always try to disarm the trap, and choose to trigger it if you can't.
 
Sure, but the question was how the path finding code should govern traps that completely block your path and my suggestion was that it should treat them the same way it treats closed doors that completely block your path i.e. your party will not pass through.
 
Of course, to make this work you'd need an option to trigger a trap that you can't disarm by clicking on it, since you wouldn't have the option of simply walking through it. Is that currently in PoE? I usually have a high Mechanics character who can disarm any trap so this isn't something I have to deal with.
Yes, that is currently how traps are handled if you can't disarm them - it asks if you'd like to trigger it (so you send the one most likely to avoid/reduce the effects of the trap)
Only on trapped containers though, currently you have to walk over traps on the floor to trigger them.

 

Ah, I hadn't realised that.  In that case the option would need to be added if they wanted to remove the discovered traps from walkable area.



#20
Boeroer

Boeroer

    Arch-Mage

  • Members
  • 14009 posts
  • Location:Bucharest, Romania
  • Lords of the Eastern Reach Backer
  • Deadfire Backer
  • Fig Backer
  • Black Isle Bastard!
Should be easy to add to floor traps since it's already in the chest traps.
  • algroth and secretmantra like this





Also tagged with one or more of these keywords: traps, pathfinding, ai, gameplay

0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users