QcPlayerThrows Class
Players throwing items by hand (a snowball, decision E-427; QcMsg::ThrowItem): the selected item, when it is throwable (QcItemDefinition::throwable), leaves the eyes as its projectile at the item's speed, turned at random by up to its inaccuracy. More...
| Header: | #include <server/projectiles/QcPlayerThrows.h> |
Public Functions
| bool | throwHeld(QcServerClient &client) |
Detailed Description
Every throw uses one item, except in creative mode, and the item cannot be thrown again before its cooldown ends; the server keeps the cooldown, the client only keeps the arm from swinging before it.
Member Function Documentation
bool QcPlayerThrows::throwHeld(QcServerClient &client)
The player of client throws the selected item; returns false when nothing was thrown (not throwable, the cooldown, the projectile limit, a dead or absent player).