Jheiar Posted October 22, 2012 Group: Members Topic Count: 13 Topics Per Day: 0.00 Content Count: 33 Reputation: 0 Joined: 09/27/12 Last Seen: December 18, 2012 Share Posted October 22, 2012 How to set this per character not per account? prontera,155,181,5 script Sample 718,{ if( !#Freebies ){ set #Freebies,1; mes "Welcome...this is your gift..."; getitem 607,10; getitem 7539,10; }else{ mes "You have claim the Reward already."; } close; } thanks in advance. Quote Link to comment Share on other sites More sharing options...
Bin4ry Posted October 22, 2012 Group: Members Topic Count: 30 Topics Per Day: 0.01 Content Count: 782 Reputation: 82 Joined: 01/01/12 Last Seen: September 21, 2015 Share Posted October 22, 2012 Remove # in the variable. Quote Link to comment Share on other sites More sharing options...
QQfoolsorellina Posted October 22, 2012 Group: Members Topic Count: 40 Topics Per Day: 0.01 Content Count: 587 Reputation: 105 Joined: 11/19/11 Last Seen: July 7, 2019 Share Posted October 22, 2012 (edited) if( !PC_DIE_COUNTER ){ set PC_DIE_COUNTER,1; mes "Welcome...this is your gift..."; getitem 607,10; getitem 7539,10; }else{ mes "You have claim the Reward already."; } close; } Edited October 22, 2012 by QQfoolsorellina Quote Link to comment Share on other sites More sharing options...
JoWei Posted October 22, 2012 Group: Members Topic Count: 2 Topics Per Day: 0.00 Content Count: 117 Reputation: 18 Joined: 01/06/12 Last Seen: April 1, 2021 Share Posted October 22, 2012 Removing "#" from "Freebies" will define the account permanent variable as character permanent variable. so for every "#Freebies" in code change them for Freebies Quote Link to comment Share on other sites More sharing options...
AnnieRuru Posted October 22, 2012 Group: Members Topic Count: 18 Topics Per Day: 0.00 Content Count: 2044 Reputation: 682 Joined: 10/09/12 Last Seen: December 20, 2020 Share Posted October 22, 2012 (edited) if( !PC_DIE_COUNTER ){ set PC_DIE_COUNTER,1; mes "Welcome...this is your gift..."; getitem 607,10; getitem 7539,10; }else{ mes "You have claim the Reward already."; } close; } WOW .... WAIT ! PC_DIE_COUNTER is use for super novice get extra stats sd->die_counter = pc_readglobalreg(sd,"PC_DIE_COUNTER"); // If a Super Novice has never died and is at least joblv 70, he gets all stats +10 if((sd->class_&MAPID_UPPERMASK) == MAPID_SUPER_NOVICE && sd->die_counter == 0 && sd->status.job_level >= 70){ status->str += 10; status->agi += 10; status->vit += 10; status->int_+= 10; status->dex += 10; status->luk += 10; } if change that, super novice will never get this bonus Edited October 22, 2012 by AnnieRuru Quote Link to comment Share on other sites More sharing options...
Jazz Posted October 22, 2012 Group: Members Topic Count: 17 Topics Per Day: 0.00 Content Count: 90 Reputation: 0 Joined: 09/29/12 Last Seen: July 10, 2020 Share Posted October 22, 2012 thanks for this, solved our problem Quote Link to comment Share on other sites More sharing options...
QQfoolsorellina Posted October 22, 2012 Group: Members Topic Count: 40 Topics Per Day: 0.01 Content Count: 587 Reputation: 105 Joined: 11/19/11 Last Seen: July 7, 2019 Share Posted October 22, 2012 if( !PC_DIE_COUNTER ){ set PC_DIE_COUNTER,1; mes "Welcome...this is your gift..."; getitem 607,10; getitem 7539,10; }else{ mes "You have claim the Reward already."; } close; } WOW .... WAIT ! PC_DIE_COUNTER is use for super novice get extra stats sd->die_counter = pc_readglobalreg(sd,"PC_DIE_COUNTER"); // If a Super Novice has never died and is at least joblv 70, he gets all stats +10 if((sd->class_&MAPID_UPPERMASK) == MAPID_SUPER_NOVICE && sd->die_counter == 0 && sd->status.job_level >= 70){ status->str += 10; status->agi += 10; status->vit += 10; status->int_+= 10; status->dex += 10; status->luk += 10; } if change that, super novice will never get this bonus WOW .... WAIT ! PC_DIE_COUNTER is use for super novice get extra stats just try to not waste permanent character variable if(!BaseExp && !PC_DIE_COUNTER){ getitem ... set BaseExp,1; } Quote Link to comment Share on other sites More sharing options...
Bin4ry Posted October 22, 2012 Group: Members Topic Count: 30 Topics Per Day: 0.01 Content Count: 782 Reputation: 82 Joined: 01/01/12 Last Seen: September 21, 2015 Share Posted October 22, 2012 Not sure if novice die will their EXP return to 0? Quote Link to comment Share on other sites More sharing options...
AnnieRuru Posted October 22, 2012 Group: Members Topic Count: 18 Topics Per Day: 0.00 Content Count: 2044 Reputation: 682 Joined: 10/09/12 Last Seen: December 20, 2020 Share Posted October 22, 2012 (edited) case SL_SUPERNOVICE: case SL_WIZARD: //NOTE: here, 'type' has the value of the associated MAPID, not of the SC_SPIRIT constant. if (sd && !(dstsd && (dstsd->class_&MAPID_UPPERMASK) == type)) { clif_skill_fail(sd,skillid,USESKILL_FAIL_LEVEL,0); break; } if (skillid == SL_SUPERNOVICE && dstsd && dstsd->die_counter && !(rnd()%100)) { //Erase death count 1% of the casts dstsd->die_counter = 0; pc_setglobalreg(dstsd,"PC_DIE_COUNTER", 0); clif_specialeffect(bl, 0x152, AREA); //SC_SPIRIT invokes status_calc_pc for us. } I don't think exp has anything to do with die counter but having super novice soul link will reset the die counter HELLL yeah its time for super novice to spam the healer npc gets super novice soul link to remove death counter Edited October 22, 2012 by AnnieRuru Quote Link to comment Share on other sites More sharing options...
QQfoolsorellina Posted October 23, 2012 Group: Members Topic Count: 40 Topics Per Day: 0.01 Content Count: 587 Reputation: 105 Joined: 11/19/11 Last Seen: July 7, 2019 Share Posted October 23, 2012 (edited) since rAthena removed txt save engine , we can use sql query to check without additional permanent character variable - script abcde -1,{ OnPCLoginEvent: if(BaseLevel==1 && !BaseExp ){ if(!query_sql("SELECT char_id FROM `global_reg_value` WHERE str='PC_DIE_COUNTER' AND char_id = "+getcharid(0),.@cid)){ dispbottom "1st login"; query_sql("INSERT INTO `global_reg_value`(char_id,str,value,type,account_id) VALUES ("+getcharid(0)+",'PC_DIE_COUNTER',0,3,0)"); } } end; } Edited October 23, 2012 by QQfoolsorellina Quote Link to comment Share on other sites More sharing options...
Question
Jheiar
How to set this per character not per account?
prontera,155,181,5 script Sample 718,{
if( !#Freebies ){
set #Freebies,1;
mes "Welcome...this is your gift...";
getitem 607,10;
getitem 7539,10;
}else{
mes "You have claim the Reward already.";
}
close;
}
thanks in advance.
Link to comment
Share on other sites
9 answers to this question
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.