Louis T Steinhil Posted May 20, 2024 Group: Members Topic Count: 37 Topics Per Day: 0.01 Content Count: 177 Reputation: 33 Joined: 06/22/13 Last Seen: Saturday at 11:49 PM Share Posted May 20, 2024 Does anyone know how to make the summon teleport or warp as well when you use tele / warp BUILDIN_FUNC(summon) { int _class, timeout=0; const char *str,*event=""; TBL_PC *sd; struct mob_data *md; t_tick tick = gettick(); if (!script_rid2sd(sd)) return SCRIPT_CMD_SUCCESS; str =script_getstr(st,2); _class=script_getnum(st,3); if( script_hasdata(st,4) ) timeout=script_getnum(st,4); if( script_hasdata(st,5) ){ event=script_getstr(st,5); check_event(st, event); } clif_skill_poseffect(&sd->bl,AM_CALLHOMUN,1,sd->bl.x,sd->bl.y,tick); md = mob_once_spawn_sub(&sd->bl, sd->bl.m, sd->bl.x, sd->bl.y, str, _class, event, SZ_SMALL, AI_NONE); if (md) { md->master_id=sd->bl.id; md->special_state.ai = AI_ATTACK; if( md->deletetimer != INVALID_TIMER ) delete_timer(md->deletetimer, mob_timer_delete); md->deletetimer = add_timer(tick+(timeout>0?timeout:60000),mob_timer_delete,md->bl.id,0); mob_spawn (md); //Now it is ready for spawning. clif_specialeffect(&md->bl,EF_ENTRY2,AREA); // sc_start4(NULL,&md->bl, SC_MODECHANGE, 100, 1, 0, MD_AGGRESSIVE, 0, 60000); } script_pushint(st, md->bl.id); return SCRIPT_CMD_SUCCESS; } Quote Link to comment Share on other sites More sharing options...
0 Pride Posted May 20, 2024 Group: Members Topic Count: 1 Topics Per Day: 0.00 Content Count: 42 Reputation: 11 Joined: 11/17/20 Last Seen: October 8, 2024 Share Posted May 20, 2024 1 hour ago, Louis T Steinhil said: Does anyone know how to make the summon teleport or warp as well when you use tele / warp BUILDIN_FUNC(summon) { int _class, timeout=0; const char *str,*event=""; TBL_PC *sd; struct mob_data *md; t_tick tick = gettick(); if (!script_rid2sd(sd)) return SCRIPT_CMD_SUCCESS; str =script_getstr(st,2); _class=script_getnum(st,3); if( script_hasdata(st,4) ) timeout=script_getnum(st,4); if( script_hasdata(st,5) ){ event=script_getstr(st,5); check_event(st, event); } clif_skill_poseffect(&sd->bl,AM_CALLHOMUN,1,sd->bl.x,sd->bl.y,tick); md = mob_once_spawn_sub(&sd->bl, sd->bl.m, sd->bl.x, sd->bl.y, str, _class, event, SZ_SMALL, AI_NONE); if (md) { md->master_id=sd->bl.id; md->special_state.ai = AI_ATTACK; if( md->deletetimer != INVALID_TIMER ) delete_timer(md->deletetimer, mob_timer_delete); md->deletetimer = add_timer(tick+(timeout>0?timeout:60000),mob_timer_delete,md->bl.id,0); mob_spawn (md); //Now it is ready for spawning. clif_specialeffect(&md->bl,EF_ENTRY2,AREA); // sc_start4(NULL,&md->bl, SC_MODECHANGE, 100, 1, 0, MD_AGGRESSIVE, 0, 60000); } script_pushint(st, md->bl.id); return SCRIPT_CMD_SUCCESS; } https://github.com/rathena/rathena/blob/master/conf/battle/monster.conf#L308C1-L308C28 change it to yes Quote Link to comment Share on other sites More sharing options...
0 Louis T Steinhil Posted May 20, 2024 Group: Members Topic Count: 37 Topics Per Day: 0.01 Content Count: 177 Reputation: 33 Joined: 06/22/13 Last Seen: Saturday at 11:49 PM Author Share Posted May 20, 2024 20 minutes ago, Pride said: https://github.com/rathena/rathena/blob/master/conf/battle/monster.conf#L308C1-L308C28 change it to yes Thanks it worked! Quote Link to comment Share on other sites More sharing options...
Question
Louis T Steinhil
Does anyone know how to make the summon teleport or warp as well when you use tele / warp
BUILDIN_FUNC(summon) { int _class, timeout=0; const char *str,*event=""; TBL_PC *sd; struct mob_data *md; t_tick tick = gettick(); if (!script_rid2sd(sd)) return SCRIPT_CMD_SUCCESS; str =script_getstr(st,2); _class=script_getnum(st,3); if( script_hasdata(st,4) ) timeout=script_getnum(st,4); if( script_hasdata(st,5) ){ event=script_getstr(st,5); check_event(st, event); } clif_skill_poseffect(&sd->bl,AM_CALLHOMUN,1,sd->bl.x,sd->bl.y,tick); md = mob_once_spawn_sub(&sd->bl, sd->bl.m, sd->bl.x, sd->bl.y, str, _class, event, SZ_SMALL, AI_NONE); if (md) { md->master_id=sd->bl.id; md->special_state.ai = AI_ATTACK; if( md->deletetimer != INVALID_TIMER ) delete_timer(md->deletetimer, mob_timer_delete); md->deletetimer = add_timer(tick+(timeout>0?timeout:60000),mob_timer_delete,md->bl.id,0); mob_spawn (md); //Now it is ready for spawning. clif_specialeffect(&md->bl,EF_ENTRY2,AREA); // sc_start4(NULL,&md->bl, SC_MODECHANGE, 100, 1, 0, MD_AGGRESSIVE, 0, 60000); } script_pushint(st, md->bl.id); return SCRIPT_CMD_SUCCESS; }
Link to comment
Share on other sites
2 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.