Facebook Twitter YouTube Frictional Games | Forum | Privacy Policy | Dev Blog | Dev Wiki | Support | Gametee


Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Throw an exploding object?
Apjjm Offline
Is easy to say

Posts: 496
Threads: 18
Joined: Apr 2011
Reputation: 52
#9
RE: Throw an exploding object?

You may be able to configure the entity properties so that it takes damage from impacts (see bottles for how this is done). You can either try issuing a callback on "breaking" the object to create the explosion (see SetEntityCallbackFunc).

As for determining what objects are nearby when the object breaks: You can always create an entity based of block_box with a large spherical mesh for a body and set this mesh entity to be the target entity after the grenade object breaks. Every object that then collides with this mesh can then be effected by the explosion somehow (if you want to be really fancy and apply impulses you may want to consider setting up an octtree to determine relative positions of entities and then applying an impulse along the vector and diminishing the intensity by an inverse square). Particle effects can be defined in the entity settings in the model editor for onbreak too.
(This post was last modified: 03-18-2012, 12:53 AM by Apjjm.)
03-18-2012, 12:51 AM
Find


Messages In This Thread
Throw an exploding object? - by Damascus - 03-17-2012, 08:56 PM
RE: Throw an exploding object? - by SilentStriker - 03-17-2012, 09:21 PM
RE: Throw an exploding object? - by ClayPigeon - 03-17-2012, 09:22 PM
RE: Throw an exploding object? - by Damascus - 03-17-2012, 09:36 PM
RE: Throw an exploding object? - by ClayPigeon - 03-17-2012, 09:39 PM
RE: Throw an exploding object? - by Damascus - 03-17-2012, 10:05 PM
RE: Throw an exploding object? - by SilentStriker - 03-17-2012, 11:14 PM
RE: Throw an exploding object? - by Stepper321 - 03-17-2012, 11:13 PM
RE: Throw an exploding object? - by Apjjm - 03-18-2012, 12:51 AM
RE: Throw an exploding object? - by Damascus - 03-18-2012, 06:31 AM
RE: Throw an exploding object? - by Apjjm - 03-18-2012, 11:47 AM
RE: Throw an exploding object? - by Equil - 03-18-2012, 07:19 AM
RE: Throw an exploding object? - by Acies - 03-18-2012, 07:07 PM
RE: Throw an exploding object? - by Damascus - 03-18-2012, 07:14 PM
RE: Throw an exploding object? - by Apjjm - 03-18-2012, 09:50 PM
RE: Throw an exploding object? - by Damascus - 03-18-2012, 10:29 PM
RE: Throw an exploding object? - by Apjjm - 03-19-2012, 12:35 AM
RE: Throw an exploding object? - by Damascus - 03-19-2012, 01:09 AM
RE: Throw an exploding object? - by Apjjm - 03-19-2012, 01:38 AM
RE: Throw an exploding object? - by Damascus - 03-19-2012, 01:42 AM
RE: Throw an exploding object? - by Apjjm - 03-19-2012, 01:43 AM
RE: Throw an exploding object? - by Damascus - 03-19-2012, 01:59 AM
RE: Throw an exploding object? - by Apjjm - 03-19-2012, 02:07 AM
RE: Throw an exploding object? - by Damascus - 03-19-2012, 02:15 AM
RE: Throw an exploding object? - by Apjjm - 03-19-2012, 02:18 AM



Users browsing this thread: 1 Guest(s)