Format:
missile(Type, Start, End)
Args:
Type: An object prototype or icon file.
Start: The starting location.
End: The ending location.
Send a missile of the given Type between two locations. The effect is purely visual. When Type is an object, its icon is used for the missile.
Example:
missile(/obj/fireball, usr, loc)
--
That's the entry from the DM Reference. The way I'd do it, is I'd have an object and icon that represented my spell, and then a verb for the player to cast the spell. When the player casted the spell, I'd determine if it cast successfully or not, if so, display the missile using the missleproc, and then do damage.
The missile proc, as it says above, is purely vissible, there's no need to determine if the missile proc itself hits anything.
1
2
In response to Merick12
|
|
In response to Merick12
|
|
Merick12 wrote:
Ok I looked and I dont understand It gives you an example right in the help file: missile(/obj/fireball, usr, loc) If you want to make like a fireball attack, for missle to work, you are going to need to make a fireball object first. obj/Magic/Fireball After that, you are going to want to make some sort of verb or something that you are going to use, to allow the player to fire off the fireball. mob/verb/Fireball(mob/M in oview(6)) // Ok this will make a verb, which you can call on a mob in oview(6) of the player I should add missle() is a pretty bad way to do spells. |
In response to Trinkit
|
|
What if I what the spell to be cast on any obj or mob that a player clicks on
|
In response to Revenant Jesus
|
|
What would you say is the best for magic spells?
|
1
2
You can't do this with a obj though, so you are going to either have to use turfs for portals, or go with a different direction.