summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorgumi <git@gumi.ca>2020-04-25 14:45:24 -0400
committergumi <git@gumi.ca>2020-04-25 14:55:38 -0400
commit1f2cdf0efd7543b50fcd6e04df495e82e860d6de (patch)
tree94a04e087253f510499816b876ecb42d72cb4444
parentdb2fa04439ded43b55ca2e7fdc3509ac2041c9fd (diff)
downloadevol-hercules-1f2cdf0efd7543b50fcd6e04df495e82e860d6de.tar.gz
evol-hercules-1f2cdf0efd7543b50fcd6e04df495e82e860d6de.tar.bz2
evol-hercules-1f2cdf0efd7543b50fcd6e04df495e82e860d6de.tar.xz
evol-hercules-1f2cdf0efd7543b50fcd6e04df495e82e860d6de.zip
expose the GENDER enum to the script engine
-rw-r--r--src/emap/script.c8
1 files changed, 8 insertions, 0 deletions
diff --git a/src/emap/script.c b/src/emap/script.c
index 236461b..00d26e6 100644
--- a/src/emap/script.c
+++ b/src/emap/script.c
@@ -17,6 +17,8 @@
#include "plugins/HPMHooking.h"
+#include "ecommon/enum/gender.h"
+
#include "emap/script.h"
#include "emap/map.h"
#include "emap/data/itemd.h"
@@ -88,6 +90,12 @@ void escript_hardcoded_constants_pre(void)
{
script->constdb_comment("Evol constants");
script->set_constant("MAX_SLOTS", MAX_SLOTS, false, false);
+
+ // genders: for use with the Sex param
+ script->set_constant("Gender", SP_SEX, true, false);
+ script->set_constant("GENDER_FEMALE", GENDER_FEMALE, false, false);
+ script->set_constant("GENDER_MALE", GENDER_MALE, false, false);
+ script->set_constant("GENDER_NONBINARY", GENDER_NONBINARY, false, false);
script->constdb_comment(NULL);
eskill_addskill_conststants();
}