Jump to content

Angelmelody

Members
  • Content Count

    772
  • Joined

  • Last visited

  • Days Won

    23

Everything posted by Angelmelody

  1. I'd like to suggest a new unit type mob_mvp (mob has mvp exp), hope devs agree
  2. Already done in our wiki . http://herc.ws/wiki/Instancing
  3. try warp has_instance( "map" ), x,y;
  4. try this, inside guild.c int guild_invite(struct map_session_data *sd, struct map_session_data *tsd) { struct guild *g; int i; nullpo_ret(sd); g=sd->guild; if(tsd==NULL || g==NULL) return 0; if( (i=guild->getposition(g,sd))<0 || !(g->position[i].mode&0x0001) ) return 0; //Invite permission. if(!battle_config.invite_request_check) { if (tsd->party_invite > 0 || tsd->trade_partner || tsd->adopt_invite) { //checking if there no other invitation pending clif->guild_inviteack(sd,0); return 0; } } if (!tsd->fd) { //You can't invite someone who has already disconnected. clif->guild_inviteack(sd,1); return 0; }+ if(mapreg_readreg( add_str( "$@inviteflag" ) )==1){+ clif->message(sd->fd, "Can't invite people now!");+ return 0;+ } if(tsd->status.guild_id>0 || tsd->guild_invite>0 || ((iMap->agit_flag || iMap->agit2_flag) && map[tsd->bl.m].flag.gvg_castle)) { //Can't invite people inside castles. [Skotlex] clif->guild_inviteack(sd,0); return 0; } //search an empty spot in guild ARR_FIND( 0, g->max_member, i, g->member[i].account_id == 0 ); if(i==g->max_member){ clif->guild_inviteack(sd,3); return 0; } tsd->guild_invite=sd->status.guild_id; tsd->guild_invite_account=sd->status.account_id; clif->guild_invite(tsd,g); return 0;} $@inviteflag = 1 ----> Can't invite people - script asdfjkl -1,{end;OnInit: if(gettime(3) >0 || gettime(2) > 25 ) end;OnClock0: set $@inviteflag,1; end;OnClock0026: set $@inviteflag,0; end;}
  5. I conceive a simple idea , but not sure whether it work or not function script resetcastle { setarray .@maps$[0],"aldeg_cas01","aldeg_cas02","aldeg_cas03","aldeg_cas04","aldeg_cas05"; setarray .@maps$[5],"gefg_cas01","gefg_cas02","gefg_cas03","gefg_cas04","gefg_cas05"; setarray .@maps$[10],"payg_cas01","payg_cas02","payg_cas03","payg_cas04","payg_cas05"; setarray .@maps$[15],"prtg_cas01","prtg_cas02","prtg_cas03","prtg_cas04","prtg_cas05"; for( set .@i, 0; .@i <= 19; set .@i, .@i+1 ) SetCastleData .@maps$[.@i],1,0;}
  6. you can refer to example Old_Violet_Box(617) in item_db and item_group.conf
  7. Still error.j.jpg the npc work for me , I think your client was not stable
  8. Are you using my script on a Hercules server? 1325 statpoint can be distributed as the pic , its over 210
  9. Why not use the emergency call skill ?
  10. function script checkstatepoint { // only for pre-re mode for(.@j=13;.@j<=18;.@j++){ set .@temp,readparam(.@j); if (.@temp < 2 ) continue; set .@size,.@temp/10 + (.@temp %10 ?1:0); for(.@i=1;.@i<=.@size;.@i++){ if( .@temp > (.@i*10+1) ) set .@tp,.@tp + (.@i+1)* 10; else set .@tp,.@tp + (.@i+1) * (.@temp -((.@i-1)*10 +2)+1); } } set .@tp,.@tp+StatusPoint; return .@tp}- script asdf12345 -1,{OnPCLoginEvent: if( Upper==1 && BaseLevel==99 && callfunc("checkstatepoint") > 1325){ resetstatus; set StatusPoint,1325 }end;} I m not sure how many statepoint the baselevel 99 2nd job (T) has , you can modify 1325 to correct number edit: fix bug
  11. here set .@map$,strcharinfo(3);
  12. - script asdf -1,{OnNPCKillEvent: for(;.@i<.size;.@i++){ if(killedrid== .cm[.@i]){ set .@f,1; break; } } if(!.@f) end; set .@pid,getcharid(1); if(!.@pid)end; set .@map$,strcharinfo(3); getpartymember .@pid,2; getpartymember .@pid,1; for (; .@j < $@partymembercount; .@j++) { if(isloggedin($@partymemberaid[.@j],$@partymembercid[.@j]) && attachrid($@partymemberaid[.@j]) && .@map$==strcharinfo(3) && HP ){ set #CASHPOINTS,#CASHPOINTS+.rp[.@i]; announce "kill mob ["+getmonsterinfo(.cm[.@i],0)+"], get Party Points : "+.rp[.@i],bc_self,0x00FF00; } }end;OnInit: setarray .cm[0],1514,1096; setarray .rp[0],20,50; set .size, getarraysize(.cm);}
  13. getmapmobs was merged into mobcount in early revision replace all getmapmobs("this") with mobcount("this","")
  14. I have tried the below two code snippet , Both crashes the map server, Who can teach me how to use it properly? 1 setmapflag "prontera",mf_zone; 2 setmapflag "prontera",mf_zone,Normal;
  15. I m confused, the mf_restrict was already dropped since the map zone system implemented http://herc.ws/board/topic/302-introducing-hercules-map-zone-database/ The mf_restrict (restrict) was dropped.
  16. Haha ~ , forgot to put array variable to save the select output
  17. maybe... not test removemapflag .7_map$,mf_zone;
  18. you are right , there is a more simple way to check if(query_sql ("select column from `table`")) dispbottom "exist"; else dispbottom "not exist"; }
  19. if(query_sql("select count(name) from syscolumns where id=(select id from sysobjects where name='table name')and name='column name'")){ }else{ }
  20. I think your request require a source mod. try this pc.c inside the pc_insert_card() function int csc;//add this declaration find // remember the card id to insert nameid = sd->status.inventory[idx_card].nameid; add after for(i=0;i<sd->inventory_data[idx_equip]->slot;i++){ if(nameid == sd->status.inventory[idx_equip].card[i]) csc++; } if(csc>=2) return 0
  21. I was trying to use HPM but failed #include <stdio.h>#include <string.h>#include "../common/HPMi.h"#include "../map/script.h"#include "../map/pc.h"HPExport struct hplugin_info pinfo = { "groupid2name", // Plugin name SERVER_TYPE_MAP,// Which server types this plugin works with? "1.0", // Plugin version HPM_VERSION, // HPM Version (don't change, macro is automatically updated)};BUILDIN(groupid2name){ TBL_PC* sd; sd = script->rid2sd(st); if( sd == NULL ) return true; script_pushstrcopy(st,pc_group_get_name(sd->group)); return true;}HPExport void plugin_init (void){ clif = GET_SYMBOL("clif"); script = GET_SYMBOL("script"); if( HPMi->addScript != NULL ) { HPMi->addScript("groupid2name","",BUILDIN_A(groupid2name)); }} I got compiling erro msg 1> Creating library ..pluginsgroupid2name.lib and object ..pluginsgroupid2name.exp1>groupid2name.obj : error LNK2019: unresolved external symbol _pc_group_get_name referenced in function _buildin_groupid2name1>..pluginsgroupid2name.dll : fatal error LNK1120: 1 unresolved externals========== Rebuild All: 0 succeeded, 1 failed, 0 skipped ========== Who can teach me how to fix that erro ?thanks..
  22. +OnMinute0:+ if(gettime(3)%2) end;KoEActualStart: The event will automatically start every 2hrs(2:00.. 4:00.. 6:00..8:00...)
  23. The client mistook item id10000+ for pet egg you can try 20000+
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.