Jump to content


Photo

Newbie DarkRadiant Questions


7266 replies to this topic

#7201 Xarg

Xarg

    Advanced Member

  • Member
  • PipPipPip
  • 1302 posts

Posted 15 March 2017 - 05:57 AM

The biggest problem I've found with AI using stairs is they don't actually seem to have a stairs animation, they just use the walk animation and translate up and down. Spent a few hours the other day trying to design some stair profiles, the best I could come up with for tread depth was 22.5 units per stair leaves the feet at about the same position for each step, but without making the staircase hideously long and thus stretching out the buildings, the AI still not only clips their feet through the stairs, but will generally skip every 2nd or 3rd stair depending on where they are in the walk animation before entering the staircase. I got this to work somewhat predictably by using a short path_wait (stop walk animation) at the top and bottom of the stairs so that they'd start the animation from the beginning when they use the stairs, but it still looks meh.


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

 


#7202 Sotha

Sotha

    Vertical Contest Winner

  • Active Developer
  • PipPipPipPipPip
  • 5498 posts

Posted 15 March 2017 - 09:41 AM

I wonder if it would be possible for the AI to have a different walk animation when they travel elevations. The AI would need to detect an elevation difference and then temporarily choose a different walking animation. I know some games have special stair anims for AI.
Clipper
-The mapper's best friend.

#7203 AluminumHaste

AluminumHaste

    Darkmod Contributor

  • Development Role
  • PipPipPipPipPip
  • 5547 posts

Posted 15 March 2017 - 09:53 AM

As far as I know, foot placement on elevations and terrain is not a canned animation, but procedural.


I always assumed I'd taste like boot leather.

 

#7204 Springheel

Springheel

    Creative Director (retired)

  • Admin
  • 35818 posts

Posted 15 March 2017 - 10:24 AM

You could probably do a canned animation if stairs were always the same size.  But it wouldn't work well for us.


Posted Image

#7205 Destined

Destined

    Advanced Member

  • Member
  • PipPipPip
  • 910 posts

Posted 15 March 2017 - 12:39 PM

As far as I know, foot placement on elevations and terrain is not a canned animation, but procedural.

If I remember correctly, it uses the regular walking animation and uses IK to account for the height difference. This is also why it only works fine for not too steep slopes. Also, I believe that this system works not too bad for AI walking upstairs and is less effective for walking downstairs as this movement differs stronger from regular walking.



#7206 Petike the Taffer

Petike the Taffer

    Member

  • Member
  • PipPip
  • 207 posts

Posted 18 March 2017 - 10:10 PM

Just some quick questions about the direction visportal brushes should be oriented in, as I'm testing their basics for the FM map I'm building:

 

Which side of an already created VP brush should be facing outwards ? Is it the reddish placeholder texture "Portal" ?

 

Will a duo of VP brushes not work properly if the sides with the above mentioned texture aren't facing away from each other ?



#7207 grayman

grayman

    Master Builder, Coder

  • Active Developer
  • PipPipPipPipPip
  • 11496 posts

Posted 18 March 2017 - 10:28 PM

Think of the VPs as 2D and not 3D.

 

"planes" not "brushes". The face with the "Vis Portal" texture is the VP. The other brush faces are irrelevant.

 

Given that, there is no "toward" or "away".



#7208 demagogue

demagogue

    Mod hero

  • Active Developer
  • PipPipPipPipPip
  • 5094 posts

Posted 18 March 2017 - 11:05 PM

An example of something that matters is that you want the VP surface touching a closed door, like embedded in the model, so it closes when the door closes. Aside from that, you just want it placed to be most efficient.

Also it's really important to use nodraw for the non portal sides. If you use any other texture it'll either kill the VP or AI will not walk through it. So you have to watch those other sides to that extent.

I can't really envision what your second question is asking. You can have 2 VP surfaces on 2 brushes flush with other and they'll act like one VP, useful for non rectangular gaps. But if that's not what you're asking, could you describe the phsycal arrangement better and what you're asking about it?
Posted Image

#7209 Judith

Judith

    Member

  • Member
  • PipPip
  • 281 posts

Posted 19 March 2017 - 08:53 AM

I won't pretend that I know what I'm talking about, but wouldn't it be easier just to use portal materials with planes instead of 3d brushes? (That's how it was meant to be used in older Unreal engines).



#7210 grayman

grayman

    Master Builder, Coder

  • Active Developer
  • PipPipPipPipPip
  • 11496 posts

Posted 19 March 2017 - 09:05 AM

Planes are patches.

 

So there are two reasons to use a brush instead of a patch:

 

1 - To make a patch, you'd first make a brush and transform it into a patch, so there's one extra (unnecessary) step.

 

2 - Also, using a brush for  a visportal makes it easier to see in the orthogonal views in DR.



#7211 Judith

Judith

    Member

  • Member
  • PipPip
  • 281 posts

Posted 19 March 2017 - 09:20 AM

I don't have the DR on my laptop, but I'm almost sure there's a "make plane" command in the upper menu bar, so you can have that right away.



#7212 grayman

grayman

    Master Builder, Coder

  • Active Developer
  • PipPipPipPipPip
  • 11496 posts

Posted 19 March 2017 - 10:17 AM

I don't have the DR on my laptop, but I'm almost sure there's a "make plane" command in the upper menu bar, so you can have that right away.

 

You must have a special version, then.


  • Springheel likes this

#7213 Judith

Judith

    Member

  • Member
  • PipPip
  • 281 posts

Posted 19 March 2017 - 12:13 PM

Not really, just the 2.2.1 x64 version.

 

Clipboard02.jpg



#7214 AluminumHaste

AluminumHaste

    Darkmod Contributor

  • Development Role
  • PipPipPipPipPip
  • 5547 posts

Posted 19 March 2017 - 12:27 PM

Yes, Create Simple Patch Mesh and Make Plane are the same thing :wacko:

 

Usually you would draw out a brush in the ortho views, then select the view you want to have the patch facing, then Shit+P to convert it into a patch.

Or

You could draw out a brush in the shape of the visportal, (to fill a doorway for example)

 

drvisportal1.jpg

 

then right click and select Make Visportal

 

drvisportal2.jpg


I always assumed I'd taste like boot leather.

 

#7215 grayman

grayman

    Master Builder, Coder

  • Active Developer
  • PipPipPipPipPip
  • 11496 posts

Posted 19 March 2017 - 12:47 PM

Not really, just the 2.2.1 x64 version.

 

 

 

I don't see "Make Plane".

 

"Create Simple Patch Mesh" uses a pre-defined brush, as AH said, so there's 2 steps: make the brush, make the patch.



#7216 Judith

Judith

    Member

  • Member
  • PipPip
  • 281 posts

Posted 19 March 2017 - 12:56 PM

I just press Shift+P, hit Enter and I have a plane, not sure what you're talking about.



#7217 OGDA

OGDA

    Member

  • Member
  • PipPip
  • 24 posts

Posted 19 March 2017 - 01:23 PM

Hello,

 

is there a spawn_arg I can set on a lever/button/switch which is connected to a door, so that an AI never uses that lever?

I have a hidden door, and when fleeing and in proximity, the AI uses the lever to open the hidden door.



#7218 Destined

Destined

    Advanced Member

  • Member
  • PipPipPip
  • 910 posts

Posted 19 March 2017 - 01:46 PM

You can use a ai_should_not_handle on the door, so AI won't use it. I am not 100% sure, if this spawnarg should go on the door or the lever. Maybe try both, just to be sure ;)



#7219 AluminumHaste

AluminumHaste

    Darkmod Contributor

  • Development Role
  • PipPipPipPipPip
  • 5547 posts

Posted 19 March 2017 - 01:57 PM

I just press Shift+P, hit Enter and I have a plane, not sure what you're talking about.

 

Yes that works for a generic sized patch, not that useful as you'll have to resize it to fit into the space where you want a visportal.

So there's still multiple steps.


I always assumed I'd taste like boot leather.

 

#7220 OGDA

OGDA

    Member

  • Member
  • PipPip
  • 24 posts

Posted 19 March 2017 - 02:19 PM

You can use a ai_should_not_handle on the door, so AI won't use it. I am not 100% sure, if this spawnarg should go on the door or the lever. Maybe try both, just to be sure ;)

 

Thank you!



#7221 montag

montag

    Member

  • Member
  • PipPip
  • 37 posts

Posted 19 March 2017 - 04:15 PM

Could someone satisfy my curiosity? In video #8 Monsterclips & AI of Sotha's Bakery Job, there is a monsterclip set around the bed. How do the AIs use the bed, do sleeping and sitting "commands" (not the right term) somehow overrule the monsterclip?



#7222 AluminumHaste

AluminumHaste

    Darkmod Contributor

  • Development Role
  • PipPipPipPipPip
  • 5547 posts

Posted 19 March 2017 - 05:37 PM

To the ai there is no bed, just monsterclip.


  • montag likes this

I always assumed I'd taste like boot leather.

 

#7223 demagogue

demagogue

    Mod hero

  • Active Developer
  • PipPipPipPipPip
  • 5094 posts

Posted 19 March 2017 - 07:37 PM

Think of monsterclip as basically just an invisible solid brush. The AI can lie on top of it, or walk on it if it covers bumpy ground, it has pathfinding computed on its top surface, etc. (In fact you may want to have it go to the ceiling to cut down the pathfinding overhead too, not for beds, but other things). It's not like they're forbidden to touch it, only they can't clip inside it and can't touch its contents.
  • montag likes this
Posted Image

#7224 montag

montag

    Member

  • Member
  • PipPip
  • 37 posts

Posted 19 March 2017 - 08:43 PM

Ah, ok I see what I missed there, he lowered the mc to the height of the bed, I missed that on the first watch. I saw him raise the other mc's, and he even mentioned he did that to prevent AI from trying to walk on their top surface. Thanks, AluminumHaste and demagogue, appreciate your time!

 

#7225 montag

montag

    Member

  • Member
  • PipPip
  • 37 posts

Posted 19 March 2017 - 08:49 PM

 

Ah, ok I see what I missed there, he lowered the mc to the height of the bed, I missed that on the first watch. I saw him raise the other mc's, and he even mentioned he did that to prevent AI from trying to walk on their top surface. Thanks, AluminumHaste and demagogue, appreciate your time!

 

 

 

To the ai there is box bed, just monsterclip.

I was actually a little saddened to learn that the AI only see an empty room, must be kinda boring for them. Would explain why they always seem to be able to find me when I think I'm in a nice little hiding spot!

 

wow, I just managed to quote myself, I'm going to blame Sotha for keeping me up so late last night. :D


Edited by montag, 19 March 2017 - 08:52 PM.




Reply to this topic



  


0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users