ID:806202
Jun 9 2012, 8:11 am
|
|||||||
Resolved
| |||||||
For the Features how about adding some beams in the game and beam battles.
|
Jun 9 2012, 8:17 am
|
|
How is a beam different than other projectiles?
|
I believe a beam refers to a projectile that makes a continuous line to the target. Such as a laser, force lightning, or whatever. Crossing the path of the beam would subject the crosser to effects and may or may not "break" the beam. Maybe useful for traps?
|
If it wasn't BYOND, it'd probably be easy to just send a stream of colliding particles. I'm not totally sure how fast this kind of ray works, but this is as simple as it gets off the top of my head:
proc/is_dense(atom/o) |
If you want the beam to be instant, you can use the library's mob.line_of_sight proc which traces a ray to the target. If the mob has line of sight to their target, the beam hits. If they don't, it doesn't. You'd just need to create the graphical effect.
If you want the beam to move gradually, I'd use the /projectile object and give it a graphical trail. If you want the beam to be persistent (walking into it from the side hurts you), I'm not sure how I'd handle it, but you could probably use /projectile objects too. |
Forum_account resolved issue with message:
I added the /missile object, which is a kind of projectile that is used to create visual effects only. It travels at a constant speed towards its target and doesn't bump anything. The Shoot Arrow ability in the sample game uses this to create its graphical effect. |