Jump to content
Posted 21 November 2012 - 12:55 PM
Posted 21 November 2012 - 12:58 PM
<Sniper|AFK> By model cutting, what are you referring to?
<Space_Man> laser scalpels
<Sniper|AFK> Seemingly that shouldn't be terribly difficult to implement
<Space_Man> human or animal models? there is an important ethical difference
<Sniper|AFK> For the physics system being used, you'd create a new actor or entity to handle the newly created pile of guts or whatever.
<Space_Man> no sane person wants to experiment on human models
<Space_Man> but a cute dog model...
<Sniper|AFK> Let's say you chopped off a leg.
<Sniper|AFK> You'd need to load up the model's verticies, create a clipping plane for the slice, and designate which polygons were affected
<Sniper|AFK> Two new models would need to be created,
<Sniper|AFK> The "hole" in the leg would need to be filled with an appropriate "blood and guts" textured mesh
<Sniper|AFK> You'd probably designate a particle system for the center of the newly created hole, at which point blood gushes out.
* LordHavoc has quit ("Client exiting")
<Sniper|AFK> The physics system would take care of the collision of either mesh.
* LordHavoc (~firstname.lastname@example.org) has joined #darkplaces
* Caleb gives channel operator status to LordHavoc
<Sniper|AFK> Something to that effect.
<Sniper|AFK> Obviously there'd be more to it, but overall, I'd probably code it in those steps.
<Sniper|AFK> As for the actual slicing and filling of the model, I'm sure there are papers around for that.
The game and engine are GPL licensed, so virtually anything can be done with it.
<Spoike1> no, none.
<blendarer> I just want.... model cutting and deforms
<blendarer> and I.. don't know how to do this
<Spoike1> oh, is that all?
<blendarer> suppsidly it's easy
<blendarer> that's all
<Spoike1> aye, it is really easy...
<Spoike1> doing it in realtime in a persistant manner on the other hand...
<Spoike1> especially if you want the severed limb to fall on the ground instead of instantly vanishing in an immersion breaking way
<blendarer> be given an entity and fall on ground like a gib
<blendarer> (doesn't need to be properly min/maxed or anything)
<Spoike1> if you have a mesh and a plane to cut along, you can test the distance from the point, and figure out the fraction and midpoint
<Spoike1> problem is that in an animating mesh, that mid point moves.
<Spoike1> and the plane bends too.
<Spoike1> and the animations kinda expect there to still be an arm or whatever to counter balance the animation's momentum, etc
<blendarer> could still keep the bone there?
<blendarer> (but no verts )
<blendarer> I made a thread here http://forums.xonotic.org/showthread.php?tid=3666 about that
<blendarer> but whatever's simple is fine too, something is better than nothing
<Spoike1> easiest way is to likely build the mesh, figure out the interpolant values, and then generate a completely new mesh from the original mesh. then import animations from the origional model into your new mesh.
<blendarer> if animation can't be done this could just be a death effect which wouldn't be called unless the blow's dmg reduced theirs to less than 0
<blendarer> Spoike1, in the engine?
<Spoike1> using vertex weights to figure out the new midpoint of the lines on the cuts
<blendarer> may I post these things to that thread (so others can read the ideas?)
<Spoike1> do whatever you want, so long as I don't have to stop being lazy.
<blendarer> are there any turtorials on darkplaces I can read to learn how do work with it and maybe do this
Posted 21 November 2012 - 01:28 PM