summaryrefslogtreecommitdiff
path: root/npc/other/Global_Functions.txt
diff options
context:
space:
mode:
authorLupus <Lupus@54d463be-8e91-2dee-dedb-b68131a5f0ec>2006-06-11 06:51:38 +0000
committerLupus <Lupus@54d463be-8e91-2dee-dedb-b68131a5f0ec>2006-06-11 06:51:38 +0000
commit859b7db3e221b7d74eee7ce176e8c411f635f61d (patch)
treed34c76f404816ace48f902be9a0a1fd6bfa90f57 /npc/other/Global_Functions.txt
parent139975b43ca2e325add8d09a917b36e43716046e (diff)
downloadhercules-859b7db3e221b7d74eee7ce176e8c411f635f61d.tar.gz
hercules-859b7db3e221b7d74eee7ce176e8c411f635f61d.tar.bz2
hercules-859b7db3e221b7d74eee7ce176e8c411f635f61d.tar.xz
hercules-859b7db3e221b7d74eee7ce176e8c411f635f61d.zip
Completed full save/restore of Quest Skills on the REBIRTHING 8)
git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@7089 54d463be-8e91-2dee-dedb-b68131a5f0ec
Diffstat (limited to 'npc/other/Global_Functions.txt')
-rw-r--r--npc/other/Global_Functions.txt14
1 files changed, 8 insertions, 6 deletions
diff --git a/npc/other/Global_Functions.txt b/npc/other/Global_Functions.txt
index 31aa68fbe..559e13266 100644
--- a/npc/other/Global_Functions.txt
+++ b/npc/other/Global_Functions.txt
@@ -3,7 +3,7 @@
//===== By: ==================================================
//= Lupus, kobra_k88
//===== Current Version: =====================================
-//= 1.91
+//= 2.0
//===== Compatible With: =====================================
//= eAthena 1.0
//===== Description: =========================================
@@ -21,6 +21,7 @@
//= 1.8 Added Job Vars clear for Extended classes: TK,SL,SG [Lupus]
//= 1.9 Added "F_ClearGarbage" func that clears outdated, wasted variables [Lupus]
//= 1.91 Added "F_SaveQuestSkills","F_Load?Skills" functions [Lupus]
+//= 2.0 Fixed F_Save/LoadQuestSkills functions. Had to split in into 2 vars [Lupus]
//============================================================
@@ -71,7 +72,7 @@ function script F_ClearGarbage {
if(nif_q_done) {set nif_q_done,0; set MISC_QUEST,MISC_QUEST | 64;}
if(MORGEN >= 2) {set MISC_QUEST,MISC_QUEST | 4; set MORGEN,0;}
set nif_t,0;
- //set QSK1,0; set QSK2,0; set QSK3,0; set QSK4,0;
+ set QSK1,0; set QSK2,0; set QSK3,0; set QSK4,0;
return;
}
@@ -417,14 +418,14 @@ function script getJobName {
// *** Function "F_SaveQuestSkills": Store learnt quest skills
//////////////////////////////////////////////////////////////////////////////////
function script F_SaveQuestSkills {
- set ADV_QSK,0;
+ set ADV_QSK,0; set ADV_QSK2,0;
//1st classes quest skills
for(set @i, 0; @i < 14; set @i, @i + 1){
if(getskilllv(144+@i)) set ADV_QSK,ADV_QSK|pow(2,@i);
}
//2nd classes quest skills
for(set @i, 0; @i < 19; set @i, @i + 1){
- if(getskilllv(1001+@i)) set ADV_QSK,ADV_QSK|pow(2,14+@i);
+ if(getskilllv(1001+@i)) set ADV_QSK2,ADV_QSK2|pow(2,@i);
}
return;
}
@@ -437,6 +438,7 @@ function script F_Load1Skills {
for(set @i, 0; @i < 14; set @i, @i + 1){
if(ADV_QSK|pow(2,@i) == ADV_QSK) skill 144+@i,1,0;
}
+ set ADV_QSK,0; //Clear var
return;
}
@@ -446,8 +448,8 @@ function script F_Load1Skills {
function script F_Load2Skills {
//2nd classes quest skills
for(set @i, 0; @i < 19; set @i, @i + 1){
- if(ADV_QSK|pow(2,14+@i) == ADV_QSK) skill 1001+@i,1,0;
+ if(ADV_QSK2|pow(2,@i) == ADV_QSK2) skill 1001+@i,1,0;
}
- set ADV_QSK,0; //Clear var
+ set ADV_QSK2,0; //Clear var
return;
} \ No newline at end of file