summaryrefslogtreecommitdiff
path: root/npc
diff options
context:
space:
mode:
authorJesusaves <cpntb1@ymail.com>2021-05-24 23:40:12 -0300
committerJesusaves <cpntb1@ymail.com>2021-05-24 23:40:12 -0300
commit6e6d7c558e80866e53454048608abae093eefcfe (patch)
tree7574ab793cea2f544343a54ac3656498b7d39390 /npc
parent226072b5fc269e2e1565d2e616938d6d11a36607 (diff)
downloadserverdata-6e6d7c558e80866e53454048608abae093eefcfe.tar.gz
serverdata-6e6d7c558e80866e53454048608abae093eefcfe.tar.bz2
serverdata-6e6d7c558e80866e53454048608abae093eefcfe.tar.xz
serverdata-6e6d7c558e80866e53454048608abae093eefcfe.zip
Upgrade Mirror Lake rules, and force-equip the Mirror Lake Armor
Diffstat (limited to 'npc')
-rw-r--r--npc/functions/hub.txt30
1 files changed, 26 insertions, 4 deletions
diff --git a/npc/functions/hub.txt b/npc/functions/hub.txt
index f9987f9b5..382fb21d7 100644
--- a/npc/functions/hub.txt
+++ b/npc/functions/hub.txt
@@ -26,17 +26,29 @@ function script HUB_Login {
if (getvaultid()) {
.@gto=get_byte(##00_INFO, 3);
.@mlp=get_nibble(##00_INFO, 5);
- if (.@gto == $WID) {
+ // Work only on new chars, or chars which cleared Tulimshar.
+ if (.@gto == $WID &&
+ (!getq(General_Narrator) ||
+ (getq(General_Narrator) && BaseLevel > 20)))
+ {
// Warp to the proper Mirror Lake
switch (.@mlp) {
- case 1: warp "018-7-1", 90, 47; break;
- default: warp "014-4", 28, 31; break;
+ case 1: warp "018-7-1", 90, 47; LOCATION$ = "LoF"; break;
+ default: warp "014-4", 28, 31; LOCATION$ = "LoF"; break;
}
// Send debug information
debugmes("Vault User %d moved to lake %d.", getvaultid(), .@mlp);
- // FIXME: Handle new user (non-native) accounts
+ // Handle new user (non-native) accounts
+ if (!getq(General_Narrator)) {
+ getitembound MirrorLakeArmor, 1, 4;
+ equip(MirrorLakeArmor);
+ TUTORIAL=true;
+ //BaseLevel = get_byte(##00_INFO, 0) + 1;
+ // TODO: Display quick tutorial
+ dispbottom l("Mirror Lake : Obtain help with %s.", b("@info"));
+ }
// Unset the target lake/world
set_byte(##00_INFO, 0, 3);
@@ -261,6 +273,16 @@ function script HUB_Logout {
"MLTO", 0);
##VAULT_EXP=0;
api_send(API_FLUSHVAULT, .@api$);
+ // Destroy temporary characters
+ if (countitem(MirrorLakeArmor)) {
+ delitem MirrorLakeArmor, countitem(MirrorLakeArmor);
+ clearitem();
+ resetlvl(2);
+ resetstatus();
+ resetskill();
+ warp "000-0", 22, 24;
+ debugmes("Vault User %d reset!", getvaultid());
+ }
}
}