Hey to all,
I have been racking my magnificent manly brain for the past few days, trying to create a dynamic shader which has a small 'hotzone' when interacted with something, but no matter what I do, non of it applies into something workable.
Here is the first example of what I mean of sorts:
http://www.youtube.com/watch?v=Y6k1uk6jl64
And now, here is EXACTLY what I'm talking about - KILLER TURTLES FROM SPACE:
[ame]
http://www.youtube.com/watch?v=MMFfVfzthP0&feature=related[/ame]http://irrlicht.sourceforge.net/phpBB2/viewtopic.php?t=38544&postdays=0&postorder=asc&start=30
The only idea I had as my last resort was opening up UDK, and taking a peek at the HUD-Damage Material and how it worked, hoping to apply it to a 3RD person invisible mesh and have it interact as the buffer for the final mesh.
However, the material is pretty simple, doesn't have a Custom HLSL, and is just a bunch of Alphas and Rotations nodes stacked under a simple scheme, which didn't help me in understanding how damage in relation to position works since I can't find the offset base that indicates or tells me from which direction the damage is coming in the first place (they might be using Cascade? Wouldn't make sense for resource management however).
Anyone has tips in that regard?
EDIT: Anyone knows where the 'Shield' effect for the vehicles in the games are? I would like analyze how the structure is setup.
Other Links:
http://forums.epicgames.com/showthread.php?t=794150http://forums.epicgames.com/showthread.php?t=794750
Replies
Nice, thank you for the information, this should come in handy!
Thanks for the tip, but the author for some reason is MIA, even the author for the second video is MIA. I guess they don't bother with dirty peasants like me after they achieve the status of Elite (aka, Developers who don't sleep).
Other then that, still hoping for the best, going to test Haid's idea.
(I dont really know Kismet, but if you can spawn meshes and get the hit point it should be possible.)
http://udn.epicgames.com/Three/KismetReference.html
Using UDK as a base look in the "takeDamage" function of the actor class. Included in that is a vector for hit location.
So for your player class using this material you're creating you can have a hook in the takeDamage portion that specifies something like
You'll also some sort of timeout value like the damage amount or some other basic value for how long the effect stays on.
In the shader you can transform the incoming world vector from hit location to a tangent or UV vector with the Transform node. You can use the x and y position as the incoming coordinates for a texture coordinate node linked to an alpha for your shield hit effect, or even an entire sub-set of the material that defines shield behaviour. The caveat with that texture is it will need to have a small area in the center of the map that is active while the rest is black. This way when it is offset by the hit behaviour it won't look strange when the texture tiles.
You can then alter the value of that texture by say subtracting the value of a sine node with a time input clamped between 0 and 1.
A simpler method would be to create a shield hit effect in cascade, that looks like the bubble shield hotspot you want, then hook in the spawn code using the previously mentioned hitvector from the takedamage routine.
I did something somewhat similar for projectile reflection in this mod:
video here
[ame]http://www.youtube.com/watch?v=2i0qhG8Pux0[/ame]
You can see the rocket bouncebacks leave a little pulse ring. Its a super simple cascade effect
heres the code behind that bit
The fun part is that last bit of SpawnEmitter where I have "none" you can put a variable pointing to the actor that took the damage, so the shield hit travels with them.
Hope thats all followable and makes sense.
The particle method I KNOW will work, while the material method I THINK will work.. ::)
Edit: BTW the "shield" effects on the vehicles are a simple overlay when they're being hit with the specific damagetype of the altfire linkgun.
code is in UTVehicle.UC at around line 3540.
The material area in question is in M_VH_ALL_Axon_Base. Look in the Emissive section for Veh_OverlayColor.
Still going to need some script hooks for the full effect though.
Actually, that could be problematic, but that also could be useful for other ideas I have, thanks mate!
Haha, most likely you WILL get it before me, I'm swamped in work and was hoping to learn a quick shader effect or two for gameplay, emphsis on 'Quick' here, but considering on how bad I am in Kismet, I most likely will not getting that anytime soon.
Thanks for the help though, much appreciated.
I actually did, but couldn't see anything special other then it being softbody and everything about it was 'automatic', any tips on what I should be looking out for?
Wow, thanks alot for all the input there, mind you, I'm really crap at anything else other then shaders and particles, but this is gold, should help me get started on the right path!
Abit of a general question, but did they change the names for half of the stuff in the damage and projectile area for the Kismet? I just tried a dry-run and nothing comes up, also, the stuff which I think should be working isn't accepting 'stuff' such as materials any tips about that?
If you want to go the particle effect route, which might be the easiest and potentially only way to go without coding something, you can use kismet to spawn a particle of your shield hit type, then use the attach to actor kismet node to attach said spawned particle to the target. Basically machinima it up, but to use dynamic hit detection and response you very well may have to get your hands dirty and learn some Uscript.
Also the meat cube, if I remember right, is handled by physical material definitions. Also a code linked to art thing.
You are in the technical realm now. not everything is GUI based here.
Ihe good news is its not that hard of a language. Its like Java or C#.. actually its rediculously close to C#, so much so that I wondered if MS patterend that language on Uscript.