View unanswered posts | View active topics It is currently Thu Jan 02, 2025 10:10 pm



Reply to topic  [ 6 posts ] 
 Breaching Charge 
Author Message

Joined: Mon Aug 16, 2010 12:16 pm
Posts: 4
Reply with quote
Post Breaching Charge
Hi everyone just a quick question which might be really stupid, but i don't know to much about modding cortex yet. Is it possible to make a shaped charge that blasts in a certain direction?

Thanks for your time.


Wed Oct 20, 2010 5:29 am
Profile
User avatar

Joined: Wed Feb 17, 2010 12:07 am
Posts: 1545
Location: That small peaceful place called Hell.
Reply with quote
Post Re: Breaching Charge
You could make it gib an AEmitter that emits in the desired direction, although it wouldn't be able to gib the other way either..

Lua might be the way to go.


Wed Oct 20, 2010 6:01 am
Profile
User avatar

Joined: Sun Jul 13, 2008 9:57 am
Posts: 4886
Location: some compy
Reply with quote
Post Re: Breaching Charge
Lua is definitely the way to go with these kinds of things for simplicity, but you could possibly do it with an MOSR gib that has an attached AEmitter, I remember something about them inheriting rotation. It's been a while, though, clearly. Shaped charges are easy, timed shaped charges are kind of different but with a bit of sparkle magic they're simple enough.

That said:

    Step 1: Create your "charge". You'll probably want to use a TDExplosive because it'll mean you can throw them around and they're the game's base bomb anyway.

    Step 2: Script the charge to detect when it's coming into contact with the terrain (you'll probably want to use a ray of a set length (just larger than the radius of the charge))

    Step 3: Make the script trigger a change in state to a countdown mode, and make it set a variable to an angle in direction of contact. You'll probably want to pin it at this point.

    Step 4: When the timer hits 5 seconds or whatever, create an AEmitter that shoots an explosion at Angle 0, and rotate it to the angle of the contact point using the variable you set before, then add it to MovableMan. Gib the charge into some cool particles here. If you make the charge hittable with a low gibwoundlimit it could add a tactical possibility to disarm a set charge by shooting it.

    Step 5: Marvel at your work.

I don't have time for implementation, sorry. Planted explosives are rad though (God the vanilla C4 needs to be reworked ;-;)


Wed Oct 20, 2010 7:20 am
Profile WWW

Joined: Mon Aug 16, 2010 12:16 pm
Posts: 4
Reply with quote
Post Re: Breaching Charge
Wow thanks heaps Geti that spelt it out rather well :)

Thank you to Coop you set me on the right track so in the meantime between yours and Geti's post i did some reaserch and now i mostly know what he was talking about.

To true the vanilla C4 doesn't cut it (way to CPU intensive with the fire, for me at least). Nor the explosive charge really. So i am on a quest to make my own, plus bombs are way cool!

Blow ♥♥♥♥ up!! :D

With some luck i may be back with some sort of mod to post if its any good, but that will probably be a century later knowing the countless nooby hurtles that lay ahead haha.


Wed Oct 20, 2010 9:44 am
Profile
Data Realms Elite
Data Realms Elite
User avatar

Joined: Fri Jul 03, 2009 11:05 am
Posts: 3878
Reply with quote
Post Re: Breaching Charge
Hey, I could have some use for a breaching charge too. Please post it when it's ready.

I beg of you.


Wed Oct 20, 2010 5:10 pm
Profile
User avatar

Joined: Sun Jul 13, 2008 9:57 am
Posts: 4886
Location: some compy
Reply with quote
Post Re: Breaching Charge
spike wrote:
Wow thanks heaps Geti that spelt it out rather well :)
No worries, good luck.

Oh yeah, just because there's not much information on how to use it you can preset the direction an AEmitter emits from with
Code:
EmissionAngle = Matrix
   AngleDegrees = whatever angle you want to use in degrees here
with correct indentation of course.


Wed Oct 20, 2010 7:44 pm
Profile WWW
Display posts from previous:  Sort by  
Reply to topic   [ 6 posts ] 

Who is online

Users browsing this forum: No registered users


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group.
Designed by STSoftware for PTF.
[ Time : 0.037s | 13 Queries | GZIP : Off ]