summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--npc/003-13/arnea.txt8
-rw-r--r--npc/functions/scoreboards.txt17
2 files changed, 25 insertions, 0 deletions
diff --git a/npc/003-13/arnea.txt b/npc/003-13/arnea.txt
index 084e8b22c..2107bda43 100644
--- a/npc/003-13/arnea.txt
+++ b/npc/003-13/arnea.txt
@@ -40,6 +40,7 @@ L_Manage:
select
l("warp back"),
rif(!'UDTf, l("begin UDT Challenge")),
+ l("UDT Challenge Ranking"),
l("cancel");
switch (@menu)
@@ -72,6 +73,11 @@ L_Manage:
closeclientdialog;
break;
case 3:
+ mesc l("All leaderboards are refreshed hourly."), 1;
+ mesc l("Your current score: @@", UDTRANK), 3;
+ HallOfUDT();
+ break;
+ case 4:
break;
}
close;
@@ -113,6 +119,8 @@ OnGladius:
setunitdata(.@mg, UDT_CRIT, (.@blv/2)+.@luk+('UDTf*2));
'UDTf+=1;
npctalk ("UDT Challenge, wave " + 'UDTf + "!");
+ if ('UDTf > UDTRANK)
+ UDTRANK='UDTf;
end;
OnInit:
diff --git a/npc/functions/scoreboards.txt b/npc/functions/scoreboards.txt
index 3e6b476ab..c6735d1b6 100644
--- a/npc/functions/scoreboards.txt
+++ b/npc/functions/scoreboards.txt
@@ -39,6 +39,7 @@ OnInit:
.@nb = query_sql("select char_name, command from `atcommandlog` ORDER BY atcommand_id DESC LIMIT 15", $@hogm_name$, $@hogm_value$);
.@nb = query_sql("select name, guild_lv from `guild` WHERE `guild_id`!=1 ORDER BY guild_lv DESC LIMIT 5", $@hoguild_name$, $@hoguild_value);
.@nb = query_sql("SELECT c.name, i.value FROM `char_reg_num_db` AS i, `char` AS c WHERE i.key='CRAZYPOINTS' AND i.char_id=c.char_id ORDER BY i.value DESC LIMIT 10", $@cfefe_name$, $@cfefe_value);
+ .@nb = query_sql("SELECT c.name, i.value FROM `char_reg_num_db` AS i, `char` AS c WHERE i.key='UDTRANK' AND i.char_id=c.char_id ORDER BY i.value DESC LIMIT 10", $@udt_name$, $@udt_value);
debugmes "Scoreboards reloaded";
end;
}
@@ -196,6 +197,22 @@ function script HallOfCandor {
return;
}
+function script HallOfUDT {
+ mes "";
+ mes l("##BHall Of UDT Challenge: TOP 10##b");
+ mes("1."+$@udt_name$[0]+" ("+$@udt_value[0]+")");
+ mes("2."+$@udt_name$[1]+" ("+$@udt_value[1]+")");
+ mes("3."+$@udt_name$[2]+" ("+$@udt_value[2]+")");
+ mes("4."+$@udt_name$[3]+" ("+$@udt_value[3]+")");
+ mes("5."+$@udt_name$[4]+" ("+$@udt_value[4]+")");
+ mes("6."+$@udt_name$[5]+" ("+$@udt_value[5]+")");
+ mes("7."+$@udt_name$[6]+" ("+$@udt_value[6]+")");
+ mes("8."+$@udt_name$[7]+" ("+$@udt_value[7]+")");
+ mes("9."+$@udt_name$[8]+" ("+$@udt_value[8]+")");
+ mes("10."+$@udt_name$[9]+" ("+$@udt_value[9]+")");
+ return;
+}
+