summaryrefslogtreecommitdiff
path: root/src/map/pc.c
diff options
context:
space:
mode:
authorcelest <celest@54d463be-8e91-2dee-dedb-b68131a5f0ec>2005-02-15 08:55:36 +0000
committercelest <celest@54d463be-8e91-2dee-dedb-b68131a5f0ec>2005-02-15 08:55:36 +0000
commit09af9729fa04300ecb6c98e95962afa22a5c96b3 (patch)
treef93bd8b5dad84155c9dd265a20029ede25283bf9 /src/map/pc.c
parente1eab1687c962cc3bea25cb66981c28be65e6e3b (diff)
downloadhercules-09af9729fa04300ecb6c98e95962afa22a5c96b3.tar.gz
hercules-09af9729fa04300ecb6c98e95962afa22a5c96b3.tar.bz2
hercules-09af9729fa04300ecb6c98e95962afa22a5c96b3.tar.xz
hercules-09af9729fa04300ecb6c98e95962afa22a5c96b3.zip
* Added experimental code to generate a stack dump when it segfaults
git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/branches/stable@1108 54d463be-8e91-2dee-dedb-b68131a5f0ec
Diffstat (limited to 'src/map/pc.c')
-rw-r--r--src/map/pc.c30
1 files changed, 30 insertions, 0 deletions
diff --git a/src/map/pc.c b/src/map/pc.c
index 4c5438d50..8fb4188f8 100644
--- a/src/map/pc.c
+++ b/src/map/pc.c
@@ -706,6 +706,9 @@ int pc_authok(int id, int login_id2, time_t connect_until_time, struct mmo_chars
sd->skilltimerskill[i].timer = -1;
sd->timerskill_count=0;
+ for (i=0; i<MAX_SKILL; i++)
+ sd->blockskill[i]=0;
+
memset(&sd->dev,0,sizeof(struct square));
for(i = 0; i < 5; i++) {
sd->dev.val1[i] = 0;
@@ -1833,6 +1836,33 @@ int pc_skill(struct map_session_data *sd,int id,int level,int flag)
}
/*==========================================
+ *
+ *------------------------------------------
+ */
+int pc_blockskill_end(int tid,unsigned int tick,int id,int data)
+{
+ struct map_session_data *sd;
+
+ nullpo_retr (-1, sd = map_id2sd(id));
+ sd->blockskill[data] = 0;
+
+ return 1;
+}
+void pc_blockskill_start (struct map_session_data *sd, int skillid, int tick)
+{
+ nullpo_retv(sd);
+
+ if (skillid >= 10000 && skillid < 10015)
+ skillid -= 9500;
+ else if (skillid < 1 || skillid > MAX_SKILL)
+ return;
+
+ sd->blockskill[skillid] = 1;
+ add_timer(gettick()+tick,pc_blockskill_end,sd->bl.id,skillid);
+ return;
+}
+
+/*==========================================
* ƒJ?ƒh?“ü
*------------------------------------------
*/