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

what the title said

Be more specific. Do you want everyone reading to spawn an entity in front of the player on item right click?

 

If you mean a projectile, say so. If you mean a <? extends EntityLivingBase> then say so.

    public static Vec3 getPointUsingAnglesRange(Vec3 start, float yaw, float pitch, float range){
        double coordX = start.xCoord + (double) (-MathHelper.sin(yaw / 180.0F * (float) Math.PI) * MathHelper.cos(pitch / 180.0F * (float) Math.PI) * range);
        double coordY = start.yCoord + (double) (-MathHelper.sin(pitch / 180.0F * (float) Math.PI) * range);
        double coordZ = start.zCoord + (double) (MathHelper.cos(yaw / 180.0F * (float) Math.PI) * MathHelper.cos(pitch / 180.0F * (float) Math.PI) * range);
        return Vec3.createVectorHelper(coordX, coordY, coordZ);
    }

I believe what they may be looking for is something that I was just talking about yesterday. You use and item to right click the ground and like magic a entity appears in front of ya. What I don't know is if it is suppose to be a custom entity or if you want a zombie, or if the entity is a creature, or something like a painting. I do know that VSWE has a video tutorial for that if you want a custom entity in this case its a spaceship. It's for 1.6 but the porting isn't hard. The one thing I got stumped on was MultiMote suggested instead of doing something like.

ship.posX = 0.5;
ship.posY = 1.5;
ship.posZ = 0.5;

 

do:

 

ship.setLocationAndAngles(x + 0.5, y + 1.5, z + 0.5, 0, 0);

 

Again though that's for a spaceship not a mob. Don't know what you are looking for when you say just entity.

 

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.