void main(){
void self = getlocalvar("self");
void Pindex = getentityproperty(self, "playerindex");
void Players = getplayerproperty(Pindex, "entity");
int Faceentity = getentityproperty(self, "facing");
int Pface = getentityproperty(Players, "facing");
if(Pface==1){
changeentityproperty(self, "facing", 2);
changeentityproperty(Players, "facing", 1);
}
if(Pface==2){
changeentityproperty(self, "facing", 1);
changeentityproperty(Players, "facing", 2);
}
}