/// <summary> /// Make the mob fall to the ground if it isn't already there /// </summary> private void Knockdown() { if (!isKnockedDown) { isKnockedDown = true; registerObject.SetPassable(false, true); mobSprite.SetToBodyLayer(); SoundManager.PlayNetworkedAtPos(SingletonSOSounds.Instance.Bodyfall, transform.position, sourceObj: gameObject); mobSprite.SetToKnockedDown(true); } }
/// <summary> /// Make the mob fall to the ground if it isn't already there /// </summary> private void Knockdown() { if (!isKnockedDown) { isKnockedDown = true; registerObject.Passable = true; mobSprite.SetToBodyLayer(); SoundManager.PlayNetworkedAtPos("Bodyfall", transform.position, sourceObj: gameObject); mobSprite.SetRotationServer(knockedDownRotation); } }