Commit Graph

43 Commits

Author SHA1 Message Date
sys4-fr 0f92ce7b10 Réduit les messages de la console. 2018-09-02 18:43:08 +02:00
Wuzzy 860358bcd1 Fix accidental using of global variable “all” 2016-08-11 18:24:22 +02:00
Wuzzy e1a72e8206 Add playereffects.has_effect_type 2016-08-11 18:23:30 +02:00
Wuzzy fb04c57da9 Remove commented out lines 2015-02-08 01:19:22 +01:00
Wuzzy 14612701ab Fix another leaking variable 2015-02-08 01:14:09 +01:00
Wuzzy 22e10bf31a Fix leaked local variable 2015-02-08 01:01:03 +01:00
Wuzzy 87699ab3b2 New effect type: repeating effects 2014-07-19 00:59:19 +02:00
Wuzzy 82291549c4 Cleanup settings, disable examples by default 2014-07-18 07:31:01 +02:00
Wuzzy 5461e148e5 Less log file spam 2014-07-17 18:44:15 +02:00
Wuzzy 1397ba542f Remove buggy get_passed_effect_time 2014-07-17 18:38:29 +02:00
Wuzzy a97ddfd942 Add API functions to get the current effect time 2014-07-17 18:36:06 +02:00
Wuzzy 5bc2ba600c Slight performance improvements 2014-07-17 18:06:49 +02:00
Wuzzy a942264256 Further performance optimizations 2014-07-17 17:42:31 +02:00
Wuzzy dcc930c499 Rewrite the way HUD IDs are handled 2014-07-17 17:06:06 +02:00
Wuzzy 54b18385c8 Add “player” argument to the cancel callback 2014-07-17 16:07:44 +02:00
Wuzzy 418cf9f365 Recolor HUD text for effects you keep on death
The color is a light purple.
2014-07-15 00:50:31 +02:00
Wuzzy c400ac1ed9 Add cancel_on_death parameter for effect types.
This optional parameter controls wheather the effect shall be cancelled
when the player dies. By default, this is true.
2014-07-15 00:38:01 +02:00
Wuzzy 7a411df76e Rename 1st param of register func for consistency 2014-07-15 00:12:05 +02:00
Wuzzy 735dce5a7b Fix effect cancelling after applying 2014-07-14 19:06:10 +02:00
Wuzzy 4ef959c78e Make apply_effect_type return effect_id on success 2014-07-14 18:13:31 +02:00
Wuzzy 1dd5c5527a Check for correct player in apply_effect_type 2014-07-14 18:10:31 +02:00
Wuzzy 15daa210c4 Add effect failure
The apply function of effects can return false, in that case, the effect
is not applied
2014-07-14 17:55:48 +02:00
Wuzzy 21f053270f Add effect metadata
Effect metadata is a means to store additional user-defined data for the effect,
which can be reused when the cancel function of the effect is called.
This commit also adds a new example (blind) to demonstrate usage of that.
2014-07-14 17:28:51 +02:00
Wuzzy a91e4c79ce Add autosave functionality 2014-07-14 00:43:16 +02:00
Wuzzy 3f2a23889f Clean up debug and log messages 2014-07-13 22:09:57 +02:00
Wuzzy 85fbd146b1 Add support for hidden effects
Hidden effects are effects which are not exposed to the player’s HUD.
2014-07-13 22:07:04 +02:00
Wuzzy bf50528228 Add setting use_hud, used to control player HUDs 2014-07-13 21:57:45 +02:00
Wuzzy 25fcabc095 Add playereffects.cancel_effect_type 2014-07-13 21:27:59 +02:00
Wuzzy 58af48a055 Show 20 effects at max on the screen
This has been done to avoid having on_globalstep calling hud_update so often.
2014-07-07 10:55:18 +02:00
Wuzzy 050be27a3b Add stresstest example use globalstep less often 2014-07-07 10:39:21 +02:00
Wuzzy bbc90ad630 Add support for HUD icons; improve HUD alignment 2014-07-07 09:38:55 +02:00
Wuzzy 49dafa6425 Clean up dead code 2014-07-06 23:17:53 +02:00
Wuzzy 812c15c9dd Show duration on first HUD add 2014-07-06 22:52:40 +02:00
Wuzzy 33c50c81ac Save status into playereffects.mt on shutdown
The file is stored in the world path. It is loaded again when the server starts again.
If the file does not exist, playereffects starts with an empty set of effects.
2014-07-06 21:16:25 +02:00
Wuzzy 8309b61769 Remove playereffects.hudids 2014-07-06 20:22:27 +02:00
Wuzzy c796ef7876 Move examples to its own file; it is not loaded 2014-07-06 18:37:32 +02:00
Wuzzy c62e857564 Add new example effect: grant fly privilege 2014-07-06 18:30:32 +02:00
Wuzzy e6d96f119a Implement HUD timers and a proper effect list 2014-07-06 18:04:29 +02:00
Wuzzy b6b3ac82ce on_joinplayer workaround 2014-07-06 16:07:00 +02:00
Wuzzy 4c1d480f82 Add basic player join and leave handling 2014-07-06 08:01:09 +02:00
Wuzzy 1b7d45532d New debug message 2014-07-06 05:25:56 +02:00
Wuzzy c4cf35a50b Fix alignment 2014-07-06 05:18:48 +02:00
Wuzzy 0672f80a55 Initial commit
The basic stuff works now
2014-07-06 01:04:03 +02:00