Jump to content
View in the app

A better way to browse. Learn more.

Forge Forums

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

Featured Replies

Posted

Im playing Custom NPCS on 1.12.

and I want an NPC with his back to the player not to see and attack the player, even though the player is in his AggroRange. Like in a stealth game where the player can sneak close to an NPC as long as the NPC doesnt see the player. The option "MustSeeTarget" doesn't work because he always sees me, no matter if I am behind the NPC or if the NPC is looking directly at me. I think the option only refers to whether there are blocks between the NPC and the player that block the view.

Is it possible to create a field of view for the NPC with scripting, so that the NPC only attacks the player when he is directly looking in the direction of the player?

As an alternative, I thought that the NPC only has a low agrorange (for example 10 blocks) and if the NPC is then attacked by the player or sees the player within these 10 blocks, then the agrorange is increased to 64, so that the NPC does not directly cancel the agro as soon as you are 10 blocks away again (the NPC uses Range attacks). But is there a better solution? 

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

Important Information

By using this site, you agree to our Terms of Use.

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.