summaryrefslogtreecommitdiff
path: root/npc/commands/gender.txt
diff options
context:
space:
mode:
Diffstat (limited to 'npc/commands/gender.txt')
-rw-r--r--npc/commands/gender.txt35
1 files changed, 35 insertions, 0 deletions
diff --git a/npc/commands/gender.txt b/npc/commands/gender.txt
new file mode 100644
index 00000000..b852beb0
--- /dev/null
+++ b/npc/commands/gender.txt
@@ -0,0 +1,35 @@
+// @gender atcommand
+// changes or returns the gender
+
+- script @gender 32767,{
+ end;
+
+OnCall:
+ if (.@atcmd_parameters$[0] == "") {
+ dispbottom("Your current gender is " + genderToString());
+ end;
+ }
+
+ .@desired = stringToGender(.@atcmd_parameters$[0]);
+
+ if (.@desired == Gender) {
+ dispbottom("Your gender is already " + genderToString());
+ } else {
+ Gender = .@desired;
+ dispbottom("Gender changed to " + genderToString());
+ }
+ end;
+
+OnInit:
+ bindatcmd("gender", "@gender::OnCall", 99, 99, false);
+ add_group_command("gender", 40, true, false);
+ add_group_command("gender", 50, true, true);
+ add_group_command("gender", 60, true, true);
+ add_group_command("gender", 80, true, true);
+
+ bindatcmd("changesex", "@gender::OnCall", 99, 99, false);
+ add_group_command("changesex", 40, true, false);
+ add_group_command("changesex", 50, true, true);
+ add_group_command("changesex", 60, true, true);
+ add_group_command("changesex", 80, true, true);
+}