shields - Page 3

shields

Discuss the source code and development of Spring Engine in general from a technical point of view. Patches go here too.

Moderator: Moderators

User avatar
lurker
Posts: 3842
Joined: 08 Jan 2007, 06:13

Re: shields

Post by lurker »

1v0ry_k1ng wrote:does that mean working small shields next spring rev then?
That requires:
1. A rearrangement of the shield collision detection to make it use the same as units and features.
2. A shield mode that makes it eat attacks rather than blowing them, or makes the unit whose shield is being hit immune to damage.

Unit and feature collisions are detected each frame from the projectile's point of view, using position and movement, but shield collisions are detected by the shield itself, and only use the current position. And a side effect of this change would be to allow these new shapes on the shields.
User avatar
KDR_11k
Game Developer
Posts: 8293
Joined: 25 Jun 2006, 08:44

Re: shields

Post by KDR_11k »

Then again, when you use personal shields you can probably emulate the effect by cancelling the damage of the projectiles instead.
User avatar
1v0ry_k1ng
Posts: 4656
Joined: 10 Mar 2006, 10:24

Re: shields

Post by 1v0ry_k1ng »

lurker wrote:That requires:
1. A rearrangement of the shield collision detection to make it use the same as units and features.
2. A shield mode that makes it eat attacks rather than blowing them, or makes the unit whose shield is being hit immune to damage.
can 1) be done easily?

how would 2) be done?
User avatar
lurker
Posts: 3842
Joined: 08 Jan 2007, 06:13

Re: shields

Post by lurker »

1 isn't horrible. 2 is a couple minutes of coding to add an option for shields to delete projectiles instead of exploding them.
User avatar
REVENGE
Posts: 2382
Joined: 24 Aug 2006, 06:13

Re: shields

Post by REVENGE »

Err sorry, one last question if I may.

So, after enabling ray-trace collision detection in my mod, would my units still be using a hitsphere by default, or just the model wireframe itself? Could I even specify an arbitrary shape (box, cone, etc. I know we had discussion for a patch that would do this)?
User avatar
lurker
Posts: 3842
Joined: 08 Jan 2007, 06:13

Re: shields

Post by lurker »

Your options for the hit surface are: ellipsoid, cylinder, rectangular prism.
User avatar
REVENGE
Posts: 2382
Joined: 24 Aug 2006, 06:13

Re: shields

Post by REVENGE »

lurker wrote:Your options for the hit surface are: ellipsoid, cylinder, rectangular prism.
Too costly to do it based on model mesh?
imbaczek
Posts: 3629
Joined: 22 Aug 2006, 16:19

Re: shields

Post by imbaczek »

very expensive, yes, and not simple.
User avatar
REVENGE
Posts: 2382
Joined: 24 Aug 2006, 06:13

Re: shields

Post by REVENGE »

Ok, but having those three alternatives to the sphere pretty much solves most problems.
Post Reply

Return to “Engine”