From 772e0b2424215a39c7291f67c311768ed685989a Mon Sep 17 00:00:00 2001 From: Vicious Date: Sat, 25 Mar 2006 00:11:33 +0000 Subject: a bit more const work for valkyrie git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@5742 54d463be-8e91-2dee-dedb-b68131a5f0ec --- npc/cities/valkyrie.txt | 21 ++++++++++++--------- 1 file changed, 12 insertions(+), 9 deletions(-) (limited to 'npc/cities') diff --git a/npc/cities/valkyrie.txt b/npc/cities/valkyrie.txt index 89b5ed294..7f56c89c2 100644 --- a/npc/cities/valkyrie.txt +++ b/npc/cities/valkyrie.txt @@ -333,9 +333,10 @@ function script F_ToHigh { if(@fjob == Job_Champion) set @fjob,Job_High_Priest; if(@fjob == Job_Professor) set @fjob,Job_High_Wizard; - if(Class == 3977+getarg(0)) goto L_WELCOME; //3rd Job - if(Class >= Job_Lord_Knight) goto L_ALREADY; //already advanced class - if(Class == Job_Novice_High && @fjob == 3977+getarg(2)) goto L_GETHIGH; //High Novice -> High XXXX + set @jobdiff, Job_Novice_High - 24; + if(Class == @jobdiff+getarg(0)) goto L_WELCOME; //3rd Job + if(Class >= Job_Lord_Knight && Class <= Job_Paladin2) goto L_ALREADY; //already advanced class + if(Class == Job_Novice_High && @fjob == @jobdiff+getarg(2)) goto L_GETHIGH; //High Novice -> High XXXX if(Class == Job_Novice_High) mes "Hello, Novice High! If you are going to became a "+getarg(1)+", then go visit your very first job teacher."; if(Class == Job_Novice_High) close; return; //this char doesn't want to get HIGH class @@ -423,10 +424,11 @@ L_ALREADY: //getarg(2) - 3rd Job ID //getarg(3) - 3rd Job Name function script F_Rebirth { + set @jobdiff, Job_Novice_High - 24; mes "["+getarg(3)+"]"; if(Upper == 2) goto L_BABY; //Baby Class - skip it - if(Class >= Job_Lord_Knight) goto L_ALREADY; //already advanced class - if(Class == (3977+getarg(0)) && ADVJOB == (3977+getarg(2))) goto L_GET3RD; //Hight XXXX -> 3rd Job + if(Class >= Job_Lord_Knight && Class <= Job_Paladin2) goto L_ALREADY; //already advanced class + if(Class == (@jobdiff+getarg(0)) && ADVJOB == (@jobdiff+getarg(2))) goto L_GET3RD; //Hight XXXX -> 3rd Job mes "Go talk to either Valhallana or one of my collegues..."; emotion e_sry; close; @@ -490,15 +492,16 @@ L_BABY: //getarg(3) - 3rd Job Name //getarg(4) - NPC Name function script F_BlockHigh { + set @jobdiff, Job_Novice_High - 24; if(Upper != 1) return; //This func should interact with Advanced classes only mes "["+getarg(4)+"]"; - if(Class == (3977+getarg(0)) && ADVJOB == (3977+getarg(2))) goto L_RIGHTHIGH; - if(Class == (3977+getarg(2))) goto L_RIGHT3RD; - if(Class >= Job_Lord_Knight) goto L_ALREADY3RD; //already advanced class, but from wrong guild + if(Class == (@jobdiff+getarg(0)) && ADVJOB == (@jobdiff+getarg(2))) goto L_RIGHTHIGH; + if(Class == (@jobdiff+getarg(2))) goto L_RIGHT3RD; + if(Class >= Job_Lord_Knight && Class <= Job_Paladin2) goto L_ALREADY3RD; //already advanced class, but from wrong guild //this player is a High Novice if(Class == Job_Novice_High) mes "Hello, Novice High! If you are going to became a "+getarg(1)+", then go visit your very first job teacher."; //this player has 1st advanced job, but from wrong guild - if(Class == (3977+getarg(0))) mes "A "+getarg(1)+"?"; + if(Class == (@jobdiff+getarg(0))) mes "A "+getarg(1)+"?"; if(Class != Job_Novice_High) mes "Rumors say only Valhallana knows your way..."; emotion e_sry; close; -- cgit v1.2.3-70-g09d2