Jump to content

Hdt grass collision


Guest

Recommended Posts

So it's a sleepless night again and I thought about what smp can do else than jiggle tiddeys.. Guys what about grassplants reacting for players walking over them like its seen in most newer games? Anyway I will have a look into this.. second thing is I want to add large banners in jarl houses which take use of smp too..though, when I create grass object in nif with like 3 bones or two and let it collide with feet, is this possible? Should boost immersion over 9000 xD

Link to comment

Good question about the framerate drop. I don't know why more games don't have this, but for all I know it might be hugely resource intensive.

But some older games have this too, actually. For example, a 2003 game (published by Bethesda, actually) called Pirates of the Caribbean has plants shuffling around when you walk through them. That's the oldest game I'm personally aware of that does it, though there might be others that are even older.

 

Now, it might be easier on the older game because fewer resources are used for other things. Or, since IIRC there aren't any physics in the game, the plants might just be objects with a trigger box on them that fires off a pregenerated animation, or something like that.

 

Still, interesting thought.

I'm interested to see what you can come up with... :)

Link to comment

So it's a sleepless night again and I thought about what smp can do else than jiggle tiddeys.. Guys what about grassplants reacting for players walking over them like its seen in most newer games? Anyway I will have a look into this.. second thing is I want to add large banners in jarl houses which take use of smp too..though, when I create grass object in nif with like 3 bones or two and let it collide with feet, is this possible? Should boost immersion over 9000 xD

 

Very interesting idea but you don't need HDT for that. In fact, I think with HDT it probably wouldn't work because it is very limited to bodies and armor parts from my experience. You could just use the normal havok resources skyrim has by adding havok constraints and rigidbodies to the nif in nifskope.

Maybe take a look at the havok ropes in my resource mod, they work completely independent of HDT.

PS. I think the same is true for SMP but I havent worked at all with it so I don't really know...

 

 

The only thing where I am not sure if it will work is that grass isn't an activator or a static world object but kind of a special object and I don't know if havok works at all with it. But you could test it by maybe replacing a grass nif with my rope or the vanilla bonetraps.

You can also stress test this way by filling a room with 100+ ropes and check if everything gets into slideshow mode. The thing with the normal havok objects is that they completely ignore physic movements before they collide with anything and this is exactly the behaviour one needs to make grass that doesn't kill framerate.

If anyone wants to test this, good luck and share your results  ;)

If this works I can help you with making a havok grass nif...

Link to comment

It is reasonably possible to implement grass collision in Skyrim, but only with animations instead of physics. Otherwise it would be nigh impossible to make it stay upright rather than flop to the ground. There's no such problem with hanging objects, however. Drapes, curtains, capes, vines, whatever.

Link to comment

i think if you give the grass 2 bones or so and make it dont collide with other grass and only feet there will be no problem with smp because you always only touch 1 or 2 grass plants lol.. i read old thread about this and they said physics grass is very perfromance hungry BUT we will have 64 bit in 5 days AND if skse is updated ALL MODS WORK FOR SSE.. btw imagine there are never more than five pairs of feet touching the grass.. only if fight bandits or have many followers.. i think if you position the bones right then it will be possible, just simulate hangin bones instead of from ground to top...i will give it a try since i have very good cpu and gpu.. 

edit: if you use enough stiffness on the grasses and make only 1 moving bone this should work fine

i dont know about "wind" on grass, since this would only work with scripts and giant invisible collision objects lol 

 

 

so where is these hdt ropes you talk about sir?
 

Link to comment

 

You can also stress test this way by filling a room with 100+ ropes and check if everything gets into slideshow mode. The thing with the normal havok objects is that they completely ignore physic movements before they collide with anything and this is exactly the behaviour one needs to make grass that doesn't kill framerate.

If anyone wants to test this, good luck and share your results  ;)

 

 

Seems to be working fine for me. I threw together a quick test mod and tried it with up to 288 ropes in a single interior cell, and there was no apparent performance hit. I didn't think to run FRAPS or anything, so I can't be certain, but it felt normal enough.

 

If anyone else wants to give it a go to double-check, the cells are:

heretical_ropetest_12      ; 12 ropes in the cell

heretical_ropetest_24      ; 24 ropes in the cell

heretical_ropetest_48      ; 48 ropes in the cell

heretical_ropetest_72      ; 72 ropes in the cell

heretical_ropetest_144     ; 144 ropes in the cell

heretical_ropetest_288     ; 288 ropes in the cell

heretical_ropetest_group   ; ?75? ropes in the cell, in a small area

 

attachment=313672:heretical rope test.7z (removed - use next one instead)

 

post-462261-0-41853700-1477144823_thumb.jpg

 

EDIT:

Of course, I couldn't walk over all, or even many, of the ropes at once, and neither a Fireball nor Unrelenting Force gave them a kick. I should put a bunch of them (say, 20 or so) in close proximity and then try walking through them...

 

Seems to be working fine. They're a little "stiff" (I don't know the terminology) so it's tough pushing through a big group, but the framerate was fine. I didn't count when I was plopping them in, but there's something like 75 ropes in a small area. The cell is heretical_ropetest_group.

 

heretical rope test 2.7z

 

Link to comment

HDT mostly responds to gravity, right? That is, things dangle and sway. Grass, on the other hand, sticks up. Applying HDT to grass might just make it lay flat? It would probably stir when being walked over, but otherwise just sit still, flat on the ground?

It is reasonably possible to implement grass collision in Skyrim, but only with animations instead of physics. Otherwise it would be nigh impossible to make it stay upright rather than flop to the ground. There's no such problem with hanging objects, however. Drapes, curtains, capes, vines, whatever.

There are more havok constraints than the ragdoll or ballandsocket constraints . I could use a hinge constraint to have 2-way movement for the grass. This shouldn't be a problem just because havok is mostly used for dangly things it doesn't mean it hasn't other uses. Maybe this even works with the ragdoll constraints if I set the gravity to pull upwards.

 

 

i think if you give the grass 2 bones or so and make it dont collide with other grass and only feet there will be no problem with smp because you always only touch 1 or 2 grass plants lol.. i read old thread about this and they said physics grass is very perfromance hungry BUT we will have 64 bit in 5 days AND if skse is updated ALL MODS WORK FOR SSE.. btw imagine there are never more than five pairs of feet touching the grass.. only if fight bandits or have many followers.. i think if you position the bones right then it will be possible, just simulate hangin bones instead of from ground to top...i will give it a try since i have very good cpu and gpu.. 

edit: if you use enough stiffness on the grasses and make only 1 moving bone this should work fine

i dont know about "wind" on grass, since this would only work with scripts and giant invisible collision objects lol 

 

 

so where is these hdt ropes you talk about sir?

 

Like I said SMP or HDT probably will not work I have to use the normal havok stuff, which btw is exactly the same as HDT. Same constraints, same rigidbodies. 

Basically, HDT is havok for clothes and bodies that use external xml data instead of the normal nif havok data.

 

About all mods working with SSE when SKSE is updated... you forgot about FNIS. I have a feeling updating FNIS for the SSE will be the bigger problem, plus fore isn't active anymore and he already mentioned if it isn't easily done he will not make an SSE FNIS Edition.

 

 

 

You can also stress test this way by filling a room with 100+ ropes and check if everything gets into slideshow mode. The thing with the normal havok objects is that they completely ignore physic movements before they collide with anything and this is exactly the behaviour one needs to make grass that doesn't kill framerate.

If anyone wants to test this, good luck and share your results  ;)

 

 

Seems to be working fine for me. I threw together a quick test mod and tried it with up to 288 ropes in a single interior cell, and there was no apparent performance hit. I didn't think to run FRAPS or anything, so I can't be certain, but it felt normal enough.

 

If anyone else wants to give it a go to double-check, the cells are:

heretical_ropetest_12      ; 12 ropes in the cell

heretical_ropetest_24      ; 24 ropes in the cell

heretical_ropetest_48      ; 48 ropes in the cell

heretical_ropetest_72      ; 72 ropes in the cell

heretical_ropetest_144     ; 144 ropes in the cell

heretical_ropetest_288     ; 288 ropes in the cell

heretical_ropetest_group   ; ?75? ropes in the cell, in a small area

 

attachment=313672:heretical rope test.7z (removed - use next one instead)

 

attachicon.gifScreenShot122.jpg

 

EDIT:

Of course, I couldn't walk over all, or even many, of the ropes at once, and neither a Fireball nor Unrelenting Force gave them a kick. I should put a bunch of them (say, 20 or so) in close proximity and then try walking through them...

 

Seems to be working fine. They're a little "stiff" (I don't know the terminology) so it's tough pushing through a big group, but the framerate was fine. I didn't count when I was plopping them in, but there's something like 75 ropes in a small area. The cell is heretical_ropetest_group.

 

attachicon.gifheretical rope test 2.7z

 

Looks promising, when I find the time I will try to put havok into one of the grass nifs then. Thanks for testing  :)

Link to comment

i think i found a solution to this, only working with skyrim havok physics, im working on grass plants and ropes now..

Isn't that what I said that one needs to use the nif internal havok physics? Anyway I hope you get it to work If you have problems with the nifskope havok data pm me.

Btw you are working on ropes? Did you see that I already made ropes? I mean if you want to make more have fun, just saying they already exist in Heretical Resources 

post-1056756-0-42370800-1477247456_thumb.jpg

Link to comment

@prZ Since you seem to have worked a lot with SMP can you tell me what the exact difference between HDT and SMP is? And can both be installed and run at the same time? If it doesn't conflict with normal HDT I might use it on some of my items too.

Ps. Do you know if SMP works on objects other than armor and bodies? I know HDT doesn't but like I said I have absolutely no knowledge on SMP.

Link to comment

@prZ Since you seem to have worked a lot with SMP can you tell me what the exact difference between HDT and SMP is? And can both be installed and run at the same time? If it doesn't conflict with normal HDT I might use it on some of my items too.

Ps. Do you know if SMP works on objects other than armor and bodies? I know HDT doesn't but like I said I have absolutely no knowledge on SMP.

Google soft mesh physics

Link to comment

 

There are more havok constraints than the ragdoll or ballandsocket constraints . I could use a hinge constraint to have 2-way movement for the grass. This shouldn't be a problem just because havok is mostly used for dangly things it doesn't mean it hasn't other uses. Maybe this even works with the ragdoll constraints if I set the gravity to pull upwards.

Probably would cause a ton of weird inexplicable crashes.

Link to comment

 

 

There are more havok constraints than the ragdoll or ballandsocket constraints . I could use a hinge constraint to have 2-way movement for the grass. This shouldn't be a problem just because havok is mostly used for dangly things it doesn't mean it hasn't other uses. Maybe this even works with the ragdoll constraints if I set the gravity to pull upwards.

Probably would cause a ton of weird inexplicable crashes.

 

What exactly? Setting the gravity to pull upwards? I can tell you for sure it doesn't cause crashes. But we will see if prZ makes the havok grass it probably will work that way because it might produce the best outcome.

Link to comment

 

 

 

There are more havok constraints than the ragdoll or ballandsocket constraints . I could use a hinge constraint to have 2-way movement for the grass. This shouldn't be a problem just because havok is mostly used for dangly things it doesn't mean it hasn't other uses. Maybe this even works with the ragdoll constraints if I set the gravity to pull upwards.

Probably would cause a ton of weird inexplicable crashes.

What exactly? Setting the gravity to pull upwards? I can tell you for sure it doesn't cause crashes. But we will see if prZ makes the havok grass it probably will work that way because it might produce the best outcome.

First, I want to try with rigid body, structured like a wooden sign, if you stand inside the grass it will be pushed to side, if you go away it would return to normal.. since this would look boring I try softbody with physics pulled to above like he said

Link to comment

.. and wind, other air effects, perhaps from dragon wings, when landing -- invisible collision sphere added to skeleton. Spell explosions, dragon shouts -- growing collision sphere.. Really cool mod idea. Wonder if cloud shadows moving across landscape could somehow parallel a trigger for vegetative physics. Wind gusts moving a large invisible non-collision sphere during storms, windy weather, that lightly touch only vegetation. Tornadoes, hurricanes, a flying arrow hitting brush, sword swings disturbing the flora. Wind that even affects the player, slight staggers, push. 

 

.. for HDT, perhaps explore a negative value for gravity. Might even be able to just simulate the effects as large "particles". Nice particle effects mod on Nexus. There are also some great examples of how UnrealEd handles schools of fish as just morphing particles. Not sure how Creation Engine handles that stuff, but UE4 demos on youtube are spectacular. 

Link to comment

Haha my First thought was putting the virtual ground above the mesh because mass is bound to the center of it, ended in a piece of crap..as the first heretic discovered wind is hardcoded in ck, its applied to the grass mesh by a ninode I don't know how its called right now, but it's needed for its animation.. so the solution is just build in havok, create rigid bodys and a few nodes so it will collide with everything on it, for examples dragons, animals, humans and items.. I will wait for skyrim se, maybe they update to havok 2014 so it doesnt make sense to work on it until release.. for spell missile collision I dont know guys, like wtf, if you shoot fireball at clutter it flys away so I think grass will only react to impact, this is not dragonball where you make kamehameha and everything be pushed to side hahaha..btw wirled up dust from impacts would give a nice mod.. guys here are all about " how can I make my females troll penis jiggle for dancing" lol but there's much more havok can do to a game xD I'm a little bit sad/worried about future skyrim modding :/

 

Edit: @ content consumer: even pokemon on gameboy color had grass that acted like collisions, you remember? HAHAHA XD

 

If the grasd got a mass of zero, it wont work with rigidbody right?

What about the speed loss when walk into a object? Is there a way to get rid of this?

Link to comment

@prZ: Well, you got a point...people here look for -and create- the most bombastic ideas I'd ever seen, nonetheless, some of the best projects had been born of rambling topics like this one. Now on topic, I would like to see more basic ideas implemented such as collition for big inanimated bodies (only), as dead dragons, giants, etc; (maybe this is a lot more easy to achieve, dunno), a workaround to get something like this, or as others had said here...wind. Oh god, I can only dream :/

 

Link to comment

As OP mentioned question was about HDT SMP (at least partly) thus havok bullshittery would not be part of it, IE performance is GROUNDBREAKING compared to havok (because bullet).

 

But problem is, yes it would lay flat, as you would need spring constraint to make it stand up (heh) and currently spring constraints are not working in SMP, and i would never even try this with Havok.

 

Also wait if HDT make SMP for SSP.

 

If so they will probably fix the spring constraint while at it and then we have springy grass, through i would throw that idea directly at HDT... if anyone speaks whatever language they speak.

 

 

(Disclaimer, replacing HDT:s gender with they as i m not sure witch it is, as i remember readin from somewhere it being she, but cant confirm / dont remember)

Link to comment

Archived

This topic is now archived and is closed to further replies.

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue. For more information, see our Privacy Policy & Terms of Use