1
0
mirror of https://codeberg.org/tenplus1/mobs_redo.git synced 2025-07-01 07:50:23 +02:00

tweak general_attack

This commit is contained in:
tenplus1
2025-05-15 14:34:38 +01:00
parent f5817061ce
commit c0c4c3ea48
2 changed files with 5 additions and 3 deletions

View File

@ -18,7 +18,7 @@ end
-- global table
mobs = {
mod = "redo", version = "20250511",
mod = "redo", version = "20250515",
spawning_mobs = {}, translate = S,
node_snow = has(core.registered_aliases["mapgen_snow"])
or has("mcl_core:snow") or has("default:snow") or "air",
@ -1692,7 +1692,8 @@ function mob_class:general_attack()
-- remove from list if invisible or unable to attack
if not damage_enabled or self.attack_players == false
or (self.owner and self.type ~= "monster")
or self.owner == objs[n]:get_player_name()
-- or (self.owner and self.type ~= "monster")
or is_invisible(self, objs[n]:get_player_name())
or (self.specific_attack and not check_for("player", self.specific_attack)) then
objs[n] = nil