n3ySkie Posted February 18, 2019 Group: Members Topic Count: 20 Topics Per Day: 0.01 Content Count: 51 Reputation: 2 Joined: 07/28/14 Last Seen: 20 hours ago Share Posted February 18, 2019 good day im requesting a GVG SPECTATOR THAT'S WORKING this one its not working. the .patch file prontera,153,178,4 script GvGPvP Watcher 414,{ if ( select ( "go to pvp", "spectator" ) == 1 ) warp "pvp_y_2-1",0,0; else { pcblockchat getcharid(3), 1; pcblockattack getcharid(3), 1; setoption 0x40, 1; warp "pvp_y_2-1",0,0; } end; OnPCLogoutEvent: setoption 0x40, 0; end; } pvp_y_2-1 mapflag pvp pcblockattack_pcblockchat_20140107.patch Quote Link to comment Share on other sites More sharing options...
0 Haruka Mayumi Posted February 18, 2019 Group: Members Topic Count: 9 Topics Per Day: 0.00 Content Count: 485 Reputation: 271 Joined: 06/13/17 Last Seen: Monday at 10:43 AM Share Posted February 18, 2019 The patch still using Session Data instead of Unit Data. it's not updated. Quote Link to comment Share on other sites More sharing options...
0 n3ySkie Posted February 18, 2019 Group: Members Topic Count: 20 Topics Per Day: 0.01 Content Count: 51 Reputation: 2 Joined: 07/28/14 Last Seen: 20 hours ago Author Share Posted February 18, 2019 so there's no fix to it? we need to wait for someone to update it? Quote Link to comment Share on other sites More sharing options...
0 AnnieRuru Posted February 18, 2019 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 February 18, 2019 (edited) yeah its too old, needs a complete revamp ... src/custom/script.inc | 20 ++++++++++++++++++++ src/custom/script_def.inc | 3 +++ src/map/clif.cpp | 2 +- src/map/pc.cpp | 2 +- src/map/pc.hpp | 2 ++ 5 files changed, 27 insertions(+), 2 deletions(-) diff --git a/src/custom/script.inc b/src/custom/script.inc index 839b990cb..0e8751707 100644 --- a/src/custom/script.inc +++ b/src/custom/script.inc @@ -17,3 +17,23 @@ // script_pushint(st,1); // return 0; //} + +BUILDIN_FUNC(pcblockchat) { + struct map_session_data *sd = map_id2sd( script_getnum(st,2) ); + if ( !sd ) { + ShowWarning( "buildin_pcblockchat: Couldn't find RID '%d'\n", script_getnum(st,2) ); + return SCRIPT_CMD_FAILURE; + } + sd->state.blockedchat = script_getnum(st,3) > 0; + return SCRIPT_CMD_SUCCESS; +} + +BUILDIN_FUNC(pcblockattack) { + struct map_session_data *sd = map_id2sd( script_getnum(st,2) ); + if ( !sd ) { + ShowWarning( "buildin_pcblockattack: Couldn't find RID '%d'\n", script_getnum(st,2) ); + return SCRIPT_CMD_FAILURE; + } + sd->state.blockedattack = script_getnum(st,3) > 0; + return SCRIPT_CMD_SUCCESS; +} diff --git a/src/custom/script_def.inc b/src/custom/script_def.inc index 886399273..63e683e82 100644 --- a/src/custom/script_def.inc +++ b/src/custom/script_def.inc @@ -9,3 +9,6 @@ **/ //BUILDIN_DEF(example,""), + +BUILDIN_DEF(pcblockchat,"ii"), +BUILDIN_DEF(pcblockattack,"ii"), diff --git a/src/map/clif.cpp b/src/map/clif.cpp index 72a596a25..d8631a6fc 100644 --- a/src/map/clif.cpp +++ b/src/map/clif.cpp @@ -10110,7 +10110,7 @@ static bool clif_process_message(struct map_session_data* sd, bool whisperFormat if( is_atcommand( fd, sd, out_message, 1 ) ) return false; - if (sd->sc.cant.chat) + if (sd->sc.cant.chat || sd->state.blockedchat) return false; //no "chatting" while muted. if( battle_config.min_chat_delay ) { //[Skotlex] diff --git a/src/map/pc.cpp b/src/map/pc.cpp index 5aace7ecb..7a9bce86e 100755 --- a/src/map/pc.cpp +++ b/src/map/pc.cpp @@ -9106,7 +9106,7 @@ bool pc_candrop(struct map_session_data *sd, struct item *item) bool pc_can_attack( struct map_session_data *sd, int target_id ) { nullpo_retr(false, sd); - if( pc_is90overweight(sd) || pc_isridingwug(sd) ) + if( pc_is90overweight(sd) || pc_isridingwug(sd) || sd->state.blockedattack ) return false; if( sd->sc.data[SC_BASILICA] || diff --git a/src/map/pc.hpp b/src/map/pc.hpp index ea5465bc8..9bcc01a88 100644 --- a/src/map/pc.hpp +++ b/src/map/pc.hpp @@ -256,6 +256,8 @@ struct map_session_data { unsigned int night :1; //Holds whether or not the player currently has the SI_NIGHT effect on. [Skotlex] unsigned int using_fake_npc :1; unsigned int rewarp :1; //Signals that a player should warp as soon as he is done loading a map. [Skotlex] + unsigned int blockedattack : 1; + unsigned int blockedchat : 1; unsigned int killer : 1; unsigned int killable : 1; unsigned int doridori : 1; prontera,153,178,4 script GvGPvP Watcher 414,{ if ( select ( "go to pvp", "spectator" ) == 2 ) { pcblockchat getcharid(3), true; pcblockattack getcharid(3), true; pcblockskill getcharid(3), true; setoption Option_Invisible, true; } warp "pvp_y_2-1",0,0; end; OnPCLogoutEvent: setoption Option_Invisible, false; end; } pvp_y_2-1 mapflag pvp pvp_y_2-1 mapflag nowarp pvp_y_2-1 mapflag nowarpto pvp_y_2-1 mapflag nosave SavePoint btw rathena developer still didn't do anything about that pull request ...https://github.com/rathena/rathena/pull/3209 Edited February 18, 2019 by AnnieRuru Quote Link to comment Share on other sites More sharing options...
0 n3ySkie Posted February 18, 2019 Group: Members Topic Count: 20 Topics Per Day: 0.01 Content Count: 51 Reputation: 2 Joined: 07/28/14 Last Seen: 20 hours ago Author Share Posted February 18, 2019 (edited) annie how about the cell block if someone hide on that cell then the player cant forward because there's a invi player there. BTW its working. emotion is my probleim can emote inside the map i wonder how to disabled it. Cell Block Also can forward. Edited February 18, 2019 by Emonizer08 wrong Quote Link to comment Share on other sites More sharing options...
0 AnnieRuru Posted February 18, 2019 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 February 18, 2019 1. cell blocking ... already said there ..https://rathena.org/board/topic/118069-war-event-watcher-request/?do=findComment&comment=356824 change "official_cell_stack_limit" then "@reloadbattleconf" 2. for emotion ... not going to do this openly ... want to start concentrate more on hercules ... so hope you can get someone else to help, or buy this mod Quote Link to comment Share on other sites More sharing options...
Question
n3ySkie
good day im requesting a GVG SPECTATOR THAT'S WORKING
this one its not working. the .patch file
pcblockattack_pcblockchat_20140107.patch
Link to comment
Share on other sites
5 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.