mirror of
https://github.com/sfall-team/sfall.git
synced 2026-07-27 16:52:34 -07:00
Added scripting functions: get/set_flags. This allows, for example, to turn character into a ghost dynamically from script.
This commit is contained in:
@@ -2,7 +2,6 @@
|
||||
#include "..\scripting\headers\define_extra.h"
|
||||
//#include "..\..\..\!SRC\headers\define.h"
|
||||
|
||||
#define it_flags (6)
|
||||
#define CRITTER_IS_DEAD (1)
|
||||
|
||||
variable highlightKey;
|
||||
@@ -10,7 +9,7 @@ variable highlightContainers;
|
||||
|
||||
procedure toggle_highlight_object(variable obj, variable color) begin
|
||||
if obj
|
||||
and (proto_data(obj_pid(obj), it_flags) bwand FLAG_NOHIGHLIGHT) == 0
|
||||
and (get_flags(obj) bwand FLAG_NOHIGHLIGHT) == 0
|
||||
and (color == 0 or not obj_blocking_line(dude_obj, tile_num(obj), BLOCKING_TYPE_SHOOT)) then begin
|
||||
set_outline(obj, color);
|
||||
end
|
||||
|
||||
@@ -207,4 +207,6 @@
|
||||
#define exec_map_update_scripts sfall_func0("exec_map_update_scripts")
|
||||
#define set_outline(obj, color) sfall_func2("set_outline", obj, color)
|
||||
#define get_outline(obj) sfall_func1("get_outline", obj)
|
||||
#define set_flags(obj, color) sfall_func2("set_flags", obj, color)
|
||||
#define get_flags(obj) sfall_func1("get_flags", obj)
|
||||
#define tile_refresh_display sfall_func0("tile_refresh_display")
|
||||
|
||||
Reference in New Issue
Block a user