Hello, here is my problem,
I want the player of the same sex to be unable to attack target of the same sex.
examble, PLAYER_MALE cant attack another PLAYER_MALE
here is my code in Combat.cpp:
[
Player* playerGetSex = player->getSex();
Target* targetGetSex = target->getSex();
if(playerGetSex == targetGetSex)
{
return RET_YOUMAYNOTATTACKTHISPLAYER;
}
]
That's mainly what i want to do, but it is not working,
I'd like some help with it please!
I want the player of the same sex to be unable to attack target of the same sex.
examble, PLAYER_MALE cant attack another PLAYER_MALE
here is my code in Combat.cpp:
[
Player* playerGetSex = player->getSex();
Target* targetGetSex = target->getSex();
if(playerGetSex == targetGetSex)
{
return RET_YOUMAYNOTATTACKTHISPLAYER;
}
]
That's mainly what i want to do, but it is not working,
I'd like some help with it please!