I searched but I think what I need wasn't done yet. I'm still new at source programming and was trying to do this command without sucess.
What I need is an script_command that, when you put 2 characters ids(if work with mob unique ids will be even better), those 2 players or 2 mobs start to identify each other as enemy and became able to attack, even if they were from the same guild and group. A little bit like the @duel.
src/map/battle.cpp | 7 +++++++
1 file changed, 7 insertions(+)
diff --git a/src/map/battle.cpp b/src/map/battle.cpp
index bd93370fb..8df9921fe 100644
--- a/src/map/battle.cpp
+++ b/src/map/battle.cpp
@@ -7643,6 +7643,13 @@ int battle_check_target( struct block_list *src, struct block_list *target,int f
if( (s_bl = battle_get_master(src)) == NULL )
s_bl = src;
+ if ( s_bl->type == BL_PC && t_bl->type == BL_PC ) {
+ struct map_session_data *sd = BL_CAST( BL_PC, s_bl );
+ s