summaryrefslogtreecommitdiff
path: root/npc/guilds/logs.txt
diff options
context:
space:
mode:
Diffstat (limited to 'npc/guilds/logs.txt')
-rw-r--r--npc/guilds/logs.txt131
1 files changed, 131 insertions, 0 deletions
diff --git a/npc/guilds/logs.txt b/npc/guilds/logs.txt
index 1463d5b13..0a1b06058 100644
--- a/npc/guilds/logs.txt
+++ b/npc/guilds/logs.txt
@@ -9,6 +9,7 @@ guilds,47,39,0 script Guild Logs NPC_NO_SPRITE,{
function showRecipe;
function calcRecipe;
function clearRecipe;
+ function GDSkillLearn;
.@gid=getcharid(2);
.@s=0; // How many was displayed, to use next(); if needed
@@ -92,6 +93,7 @@ guilds,47,39,0 script Guild Logs NPC_NO_SPRITE,{
select
l("Do nothing"),
rif(strcharinfo(0) == getguildmaster(.@gid), l("Raise max members")),
+ rif(.@role == GPOS_TREASURER || .@role <= GPOS_VICELEADER, l("Learn individual guild skills")),
l("Learn Alchemy Recipes");
mes "";
@@ -122,6 +124,84 @@ guilds,47,39,0 script Guild Logs NPC_NO_SPRITE,{
}
break;
case 3:
+ mes ".:: " + l("Guild Magic") + " ::.";
+ do
+ {
+ select
+ l("Return"),
+ rif(strcharinfo(0) == getguildmaster(.@gid), l("Increase all stats")),
+ l("Guild Area Regeneration"),
+ l("Guild Area DEF UP"),
+ l("Guild's Battle Plan"),
+ l("Guild Area ATK UP"),
+ l("Guild Area CRIT UP"),
+ l("Guild Area Autorevive"),
+ l("Weapon Maximum Damage"),
+ l("Friendly SP Regeneration");
+
+ mes "";
+ switch (@menu) {
+ case 2:
+ GDSkillLearn(TMW2_GD_INCALL, 2580,
+ l("Guild's Power"),
+ l("Increase all stats from every guild member in area."),
+ 8, 12, 16, 20, 24, 30, 36, 42, 50);
+ break;
+ case 3:
+ GDSkillLearn(TMW2_GD_REGEN, 1740,
+ l("Angel Light"),
+ l("Causes a healing effect in area to guild members."),
+ 4, 6, 9, 12, 15, 20, 25, 30, 35);
+ break;
+ case 4:
+ GDSkillLearn(TMW2_GD_DEFUP, 640,
+ l("Blessing of Defense"),
+ l("Increase defense to all friends in radius."),
+ 3, 5, 7, 9, 11, 14, 17, 20, 25);
+ break;
+ case 5:
+ GDSkillLearn(TMW2_GD_BATTLEPLAN, 1015,
+ l("Battle Plans"),
+ l("Increase STR/INT/DEX in range for all guild allies."),
+ 5, 8, 11, 15, 20, 24, 30, 37, 42);
+ break;
+ case 6:
+ GDSkillLearn(TMW2_GD_ATKUP, 1500,
+ l("Damage Improvement"),
+ l("Increase damage dealt by weapon for all guildies."),
+ 2, 4, 6, 8, 10, 12, 15, 18, 21);
+ break;
+ case 7:
+ GDSkillLearn(TMW2_GD_CRITUP, 1500,
+ l("Critical Fortune"),
+ l("Increase critical chance of all guild allies."),
+ 6, 9, 13, 19, 22, 27, 33, 39, 45);
+ break;
+ case 8:
+ GDSkillLearn(TMW2_GD_AUTOREVIVE, 3000,
+ l("Blessing of Immortality"),
+ l("If a guild mate dies, they will revive. Don't work on self."),
+ 7, 11, 17, 23, 26, 29, 31, 34, 38);
+ break;
+ case 9:
+ GDSkillLearn(TMW2_GDP_MAXPOWER, 3000,
+ l("Maximize Damage"),
+ l("PARTY AND GUILD friends: Weapon always deal max damage."),
+ 1, 5, 10, 15, 20, 25, 30, 35, 40);
+ break;
+ case 10:
+ GDSkillLearn(TMW2_GDP_SPREGEN, 3000,
+ l("Improved MP Regen"),
+ l("PARTY AND GUILD friends: Temporaly regen MP faster."),
+ 5, 10, 15, 22, 28, 32, 37, 41, 44);
+ break;
+ default:
+ break;
+ }
+ } while (@menu != 1);
+ @menu=99;
+ break;
+ case 4:
mes ".:: " + l("Alchemy Recipes") + " ::.";
do {
clearRecipe();
@@ -280,6 +360,57 @@ function hudRecipe {
return 0;
}
+// GDSkillLearn(SKID, cost-per-guild-level, title, desc, lv1, {lv2, lv3...})
+function GDSkillLearn {
+ .@id=getarg(0);
+ .@p=getarg(1);
+ .@t$=getarg(2);
+ .@d$=getarg(3);
+
+ .@gid=getcharid(2);
+ .@gid_lv=getguildlvl(.@gid);
+ .@cur_lv=getskilllv(.@id);
+ .@min_lv=getarg(4+.@cur_lv, -1);
+
+ .@price=.@min_lv*.@p;
+
+ // Max level reached
+ if (.@min_lv < 0)
+ {
+ mesc l("This skill cannot be upgraded further.");
+ next;
+ return 0;
+ }
+
+ // Guild level insuffice
+ if (.@gid_lv < .@min_lv)
+ {
+ mesc l("Guild Level is not enough: @@/@@", .@gid_lv, .@min_lv);
+ next;
+ return 0;
+ }
+
+ mes ".:: "+.@t$+" ::.";
+ mes .@d$;
+ mesc l("The cost for Guild Vault is @@ GP.", format_number(.@price));
+ mesc l("Current Guild Balance: %s GP", format_number($GUILD_BANK[.@gid]));
+ next;
+ select
+ rif($GUILD_BANK[.@gid] >= .@price, l("Upgrade it")),
+ l("Don't upgrade it");
+ mes "";
+ if (@menu == 1 && $GUILD_BANK[.@gid] >= .@price)
+ {
+ $GUILD_BANK[.@gid]-=.@price;
+ // guildskill()?
+ skill .@id, .@cur_lv+1, 0;
+ mesc l("Skill improved"), 2;
+ @menu=99;
+ return 1;
+ }
+ return 0;
+}
+
OnInit:
.distance=2;
end;