476 Sets the team name of the specified gear. The gear can be a hedgehog or grave. |
476 Sets the team name of the specified gear. The gear can be a hedgehog or grave. |
477 |
477 |
478 === `GetHogClan(gearUid)` === |
478 === `GetHogClan(gearUid)` === |
479 Returns the clan ID of the specified hedgehog gear. |
479 Returns the clan ID of the specified hedgehog gear. |
480 |
480 |
|
481 === `GetHogLevel(gearUid)` === |
|
482 Returns the bot level ranging from `0` to `5`. `1` is the strongest bot level and `5` is the weakest one (this is the reverse of what players see). `0` is for human player. |
|
483 |
|
484 === `SetHogLevel(gearUid, level)` === |
|
485 Sets the bot level from 0 to 5. `1` is the strongest bot level and `5` is the weakest one (this is the reverse of what players see). `0` means human player. |
|
486 |
481 === `GetEffect(gearUid, effect)` === |
487 === `GetEffect(gearUid, effect)` === |
482 Returns the state of given effect for the given hedgehog gear. |
488 Returns the state of given effect for the given hedgehog gear. |
483 |
489 |
484 See `SetEffect` for further details. |
490 See `SetEffect` for further details. |
485 |
491 |
529 |
535 |
530 Example: |
536 Example: |
531 <code lang="lua">GetAmmoTimer(CurrentHedgehog, amGrenade) |
537 <code lang="lua">GetAmmoTimer(CurrentHedgehog, amGrenade) |
532 -- May return 1000, 2000, 3000, 4000 or 5000</code> |
538 -- May return 1000, 2000, 3000, 4000 or 5000</code> |
533 |
539 |
534 === `GetHogLevel(gearUid)` === |
|
535 Returns the bot level ranging from `0` to `5`. `1` is the strongest bot level and `5` is the weakest one (this is the reverse of what players see). `0` is for human player. |
|
536 |
|
537 === `SetHogLevel(gearUid, level)` === |
|
538 Sets the bot level from 0 to 5. `1` is the strongest bot level and `5` is the weakest one (this is the reverse of what players see). `0` means human player. |
|
539 |
|
540 === `HealHog(gearUid, healthBoost[, showMessage[, tint]])` (0.9.24) === |
540 === `HealHog(gearUid, healthBoost[, showMessage[, tint]])` (0.9.24) === |
541 Convenience function to increase the health of a hedgehog with default visual effects. |
541 Convenience function to increase the health of a hedgehog with default visual effects. |
542 |
542 |
543 Specifically, this increases the health of the hedgehog gear with the given ID `gearUid` by `healthBoost`, displays some healing particles at the hedgehog and shows the health increae as a message. This is similar to the behavour after taking a health crate, or getting a health boost from vampirism. |
543 Specifically, this increases the health of the hedgehog gear with the given ID `gearUid` by `healthBoost`, displays some healing particles at the hedgehog and shows the health increae as a message. This is similar to the behavour after taking a health crate, or getting a health boost from vampirism. |
544 |
544 |
577 === `IsHogLocal(gearUid)` (0.9.23) === |
577 === `IsHogLocal(gearUid)` (0.9.23) === |
578 Returns `true` if the specified hedgehog gear is controlled by a human player on the computer on which Hedgewars runs on (i.e. not over a computer over the network). Also returns `true` if the hog is a member of any of the local clans. Returns `false` otherwise. Returns `nil` if `gearUid` is invalid. |
578 Returns `true` if the specified hedgehog gear is controlled by a human player on the computer on which Hedgewars runs on (i.e. not over a computer over the network). Also returns `true` if the hog is a member of any of the local clans. Returns `false` otherwise. Returns `nil` if `gearUid` is invalid. |
579 |
579 |
580 This is perfect to hide certain captions like weapon messages from enemy eyes. |
580 This is perfect to hide certain captions like weapon messages from enemy eyes. |
581 |
581 |
582 == Functions for gear actions == |
582 == Special gear actions == |
583 === `GetFollowGear()` === |
583 === `GetFollowGear()` === |
584 Returns the uid of the gear that is currently being followed. |
584 Returns the uid of the gear that is currently being followed. |
585 |
585 |
586 === `FollowGear(gearUid)` === |
586 === `FollowGear(gearUid)` === |
587 Makes the game client follow the specifiec gear (if it exists). Does not work for visual gears. |
587 Makes the game client follow the specifiec gear (if it exists). Does not work for visual gears. |