Added "set_unique_id" script function.

Minor edit to Perks.cpp.
Added DevXP config to project files.
This commit is contained in:
NovaRain
2019-04-14 07:35:52 +08:00
parent ff4f5d7e73
commit 6791b15af1
9 changed files with 97 additions and 10 deletions
@@ -287,6 +287,7 @@
#define WPN_ANIM_ROCKET_LAUNCHER (0x0A) // (M)
// common object data offsets
#define OBJ_DATA_ID (0x00)
#define OBJ_DATA_TILENUM (0x04)
#define OBJ_DATA_CUR_FRM (0x18) // current frame number
#define OBJ_DATA_ROTATION (0x1C)
+1
View File
@@ -243,6 +243,7 @@
#define set_map_enter_position(tile, elev, rot) sfall_func3("set_map_enter_position", tile, elev, rot)
#define set_object_data(obj, offset, value) sfall_func3("set_object_data", obj, offset, value)
#define set_outline(obj, color) sfall_func2("set_outline", obj, color)
#define set_unique_id(object) sfall_func1("set_unique_id", object)
#define spatial_radius(obj) sfall_func1("spatial_radius", obj)
#define tile_refresh_display sfall_func0("tile_refresh_display")
#define unjam_lock(obj) sfall_func1("unjam_lock", obj)
@@ -472,6 +472,12 @@ Some utility/math functions are available:
> void sfall_func0("art_cache_clear")
- clears the cache of FRM image files loaded into memory
> int sfall_func1("set_unique_id", object)
- assigns an unique ID number to the object and returns it. If an unique ID number has already been assigned to an object, then ID number is returned without reassignment
- to just get the current ID number of an object, use sfall_func2("get_object_data", object, OBJ_DATA_ID)
- unique ID numbers are saved in your savegame, and have a range from 0x10000000 to 0x7FFFFFFF
- there is also an unique ID number range for the player and party members from 18000 to 83535
------------------------
------ MORE INFO -------
------------------------