Jump to content

Recommended Posts

Posted

i am writing a mod that add vehicles that don't need the player to render because it will render its own version of the player. i am using Render Player API but id rather not use it if i didn't have to. I was wondering the possibility of adding a function to the Entity class similar to public boolean shouldRiderSit() that would ask if the rider should be rendered at all. i think it would just require an edit to the entity class to add the function and to the Renderliving class where  at the beginning of its render it would check to see it the entity its riding returns true(or false based on how you name the function) and if it does simply exits the render function.

 

Its just an idea i had, i don't think it would be that hard to implement but i could be wrong.

 

thanks for at least taking the time to read this

Posted

Why not turn the entity invisible?

because at least the potion effect only stops the render of the players body. his armor and in had item are still rendered. unless there is a better way of making the player invisible

Posted

The ability to not render a rider is something I will be needing soon too...

Did I help? Hitting 'Thank You' would be appreciated.

 

Soon, the lost city will rise from the bottom of the ocean, and spread it's technology across Minecraft.

Posted

So the true suggestion here is too make a way to dynamically change the armors texture?

no its more of a way to just not render the entity or telling the game that even tho the entity exists, that he/she/it should not be rendered in world when the entity has mounted an vehicle. in the case of my mod the rendering of the entity is being taken over by the vehicle render because the rider(only players are allowed) will be rendered in a different position that is not possible with the normal player render. I feel this would open up for a massive number of vehicles that were not previously possible like motorcycles where the player is holding the grips of the cycle. or also useful for mods like flans where the plane can roll but the player is still rendered straight up, you could give over the players render to the planes render allowing the player to be rendered at the same roll and pitch as the plane.

Posted

It wouldn't be too difficult to replace the player renderer with one which allows you to disable rendering completely, if certain conditions are met. You don't even need to use reflection, just replace it in the List.

Posted

It wouldn't be too difficult to replace the player renderer with one which allows you to disable rendering completely, if certain conditions are met. You don't even need to use reflection, just replace it in the List.

 

but if you mod the render list wouldn't other entities of that type not be rendered? i did a test in an older version of minecraft(1.4.7) where i added one function to Entity.java and one edit to a function in RenderManager.java and in my test it wound not matter if you had RenderPlayerAPI installed or not because it stops the render before the DoRender function is called. here my proposed code

Entity.Java

	/**
 * used to determine if the rider of this entity should be Rendered. 
 * 
 * @return false the Rider of this entity will not be Rendered
 */
public boolean shouldRiderRender()
{
	return true;
}

 

RenderManager.java

	
public void renderEntityWithPosYaw(Entity par1Entity, double par2, double par4, double par6, float par8, float par9)
{
               //Added code starts here
               //if the entity is riding another entity and that entity.shouldRiderRender returns false 
               //the rider render will be skipped
	if(par1Entity.ridingEntity != null && !par1Entity.ridingEntity.shouldRiderRender())
	{
		return;
	}
               //Added code ends here

//the rest of the function

I am how ever going to look into better non-base class modding ways of doing this. but for now this is what im proposing.

 

Posted

ivegot an easy solution.

 

ModelBipedMain, used in PlayerRenderer returns the current player model used.

 

you could use following :

 

modelBipedMain.bipedHead.showmodel == false;

 

do that for every part of the player.

remember to  .showmodel== true; as a default, so when the player un mounts the bike, it will bee visible again.

this does not allow you though to acces the model of armor, as they are private fields :/

so bike riding would have to happen without armor.

or you can find a way around this :)

Posted

It wouldn't be too difficult to replace the player renderer with one which allows you to disable rendering completely, if certain conditions are met. You don't even need to use reflection, just replace it in the List.

but if you mod the render list wouldn't other entities of that type not be rendered?

 

No? You will choose what conditions to call the original render function - it will only not render if you make it not render.

Posted

ivegot an easy solution.

 

ModelBipedMain, used in PlayerRenderer returns the current player model used.

 

you could use following :

 

modelBipedMain.bipedHead.showmodel == false;

 

do that for every part of the player.

remember to  .showmodel== true; as a default, so when the player un mounts the bike, it will bee visible again.

this does not allow you though to acces the model of armor, as they are private fields :/

so bike riding would have to happen without armor.

or you can find a way around this :)

 

if you are talking about something you do with PlayerRender API im trying to remove the need for it because if you look at how the How the API works, lets just take the function renderPlayer in your RenderPlayerBase file. in the code that calls your renderPlayer function it looks for any other registered renderPlayer Functions and runs a loop to call all of them now the way i currently unrender the player is by in my renderPlayer function i just return if a case is true.

	
        @Override
public void renderPlayer(EntityPlayer entityplayer, double d, double d1, double d2, float f, float f2)
{
	if (entityplayer.ridingEntity != null && isRidingVechicle(entityplayer))
	{
		return;
	}
	else
	{
		super.renderPlayer(entityplayer, d, d1, d2, f, f2);	
	}

}

this works if great if there is not another RenderPlayerAPI Mod installed but if there is and it Has a RenderPlayer Function then it will just screw up the My Render because the Player will be Rendered once my way(on a tron LightCycle) and again probably sitting with his/ her body stuck in the front of the bike.  So unless There is a better way of doing this(i am open to suggestions) im stuck using a method to not render the player that doesn't really work well in a bunch of cases.

Posted

http://www.minecraftforum.net/topic/1688664-151-sspsmpwin-a-cape-v83-rpg-inventory-mod-3d-items-jewelery-capes-and-much-more/

 

 

thats what i did without any baseclass editing.

custom armor models, capes rendered to the player, other models rendered to him, a new inventory, all without baseclass editing.

only problem is that is incompatible with any mod that does edit the player renderer.

Smartmoving does not do that.

Mine Little Pony does.

 

So bascily, all you need to do is catch an instance of RenderPlayer, use the field ModelBipedMain, and set your player 'invisible'.

as i told before, you can't acces the aror model fields, because they are private fields :/

i really wouldnt know any other ways of doing what you need, and in my opinion, the easiest to get, without using any api or editing baseclasses. You could even set it so the player cant mount the vehicle if he wears armor, or you can just unrender the entire armor sets by bypassing and itercepting the model renderer and anihilate the renderer (a hack, basicly). i did the same thing for custom armor, but rendered stuff with it , instead of removing stuff :)

Posted

Wrap the rendering instance to your need, I'm too lazy to research it but pseudo code:

public class RenderWrapper extends Render{
private Render wrappedRenderer;
public static List<Class<? extends Entity>> norend = new ArrayList();
static{
norend.add(yourEntity.class);
}

public RenderWrapper(Render r){
wrappedRender = r
}

public void doRender(Entity e, //Otros parameters){
if(e.isRiding && !norend.containse(e.entityRidden.getClass()))
wrappedRender.doRender(e, other parameters);
}
}

{

Using client proxy of course

public void postInit(FMLPostInitializationEvent e){
Rederplayer r = RenderingRegistry.renderList.get(playerrender);
RenderingRegistry.renderList.remove(r);
RenderingRegistry.registerEntityRender(EntityPlayer.class,new RenderWrapper(r);//super pseudo
}

No Asm reflection(I think), base edits.

I think its my java of the variables.

Posted

It wraps.... not replaces. Meaning you can wrap the wrapper...and if someone replaces the render before it those changes are kept. The problem is if some blundersome programmer replaces or wraps out of order (forced invisibility is a top priority, so should be done last)

I think its my java of the variables.

Posted

but remember we always will have asm.

whats asm?

java byte code manipulating, basicly u can edify classes on runtime, adding, remove or event editing things take a look at asm tutorial on the forg wiki, code chickens core and nei src, also bukkit forge src

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...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Announcements



  • Recently Browsing

    • No registered users viewing this page.
  • Posts

    • New users at Temureceive a 40 Off discount on orders over 40 Off Use the code [acx318439] during checkout to get TemuDiscount 40 Off For New Users. You n save 40 Off off your first order with the Promo Code available for a limited time only. Extra 30% off for new and existing customers + Up to $40 Off % off & more. Temu Promo Codes for New users- [acx318439] Temudiscount code for New customers- [acx318439] Temu $40 Off Promo Code- [acx318439] what are Temu codes- acx318439 does Temu give you $40 Off - [acx318439] Yes Verified Temu Promo Code january 2025- {acx318439} TemuNew customer offer {acx318439} Temudiscount codejanuary 2025 {acx318439} 40 off Promo Code Temu {acx318439} Temu 40% off any order {acx318439} 40 dollar off Temu code {acx318439} TemuCoupon $40 Off off for New customers There are a number of discounts and deals shoppers n take advantage of with the Teemu Coupon Bundle [acx318439]. TemuCoupon $40 Off off for New customers [acx318439] will save you $40 Off on your order. To get a discount, click on the item to purchase and enter the code. You n think of it as a supercharged savings pack for all your shopping needs Temu Promo Code 80% off – [acx318439] Free Temu codes 50% off – [acx318439] TemuCoupon $40 Off off – [acx318439] Temu buy to get ₱39 – [acx318439] Temu 129 coupon bundle – [acx318439] Temu buy 3 to get €99 – [acx318439] Exclusive $40 Off Off TemuDiscount Code Temu $40 Off Off Promo Code : (acx318439) Temu Discount Code $40 Off Bundle acx318439) acx318439 Temu $40 Off off Promo Code for Exsting users : acx318439) Temu Promo Code $40 Off off Temu 40 Off coupon code (acx318439) will save you 40 Off on your order. To get a discount, click on the item to purchase and enter the code. Yes, Temu offers 40 Off Coupon Code “acx318439” for Existing Customers.  You can get a 40 Off bonus plus 30% off any purchase at Temu with the 40 Off Coupon Bundle at Temu if you sign up with the referral code [acx318439] and make a first purchase of $40 Off or more. Temu Promo Code 40 off-{acx318439} Temu Promo Code -{acx318439} Temu Promo Code $40 Off off-{acx318439} kubonus code -{acx318439} Get ready to unlock a world of savings with our free Temu UK coupons! We’ve got you covered with a wide range of Temu UK coupon code options that will help you maximize your shopping experience.30% Off Temu UK Coupons, Promo Codes + 25% Cash Back [ acx318439]   Yes, Temu offers 40 off coupon code {acx318439} for first-time users. You can get a $40 bonus plus 40% off any purchase at Temu with the $40 Coupon Bundle if you sign up with the referral code [acx318439] and make a first purchase of $40 or more. If you are who wish to join Temu, then you should use this exclusive TemuCoupon code 40 off (acx318439) and get 40 off on your purchase with Temu. You can get a 40% discount with TemuCoupon code {acx318439}. This exclusive offer is for existing customers and can be used for a 40 reduction on your total purchase. Enter coupon code {acx318439} at checkout to avail of the discount. You can use the code {acx318439} to get a 40 off TemuCoupon as a new customer. Apply this TemuCoupon code $40 off (acx318439) to get a $40 discount on your shopping with Temu. If you’re a first-time user and looking for a TemuCoupon code $40 first time user(acx318439) then using this code will give you a flat $40 Off and a 90% discount on your Temu shopping.     •    acx318439: Enjoy flat 40% off on your first Temu order.     •    acx318439: Download the Temu app and get an additional 40% off.     •    acx318439: Celebrate spring with up to 90% discount on selected items.     •    acx318439: Score up to 90% off on clearance items.     •    acx318439: Beat the heat with hot summer savings of up to 90% off.     •    acx318439: Temu UK Coupon Code to 40% off on Appliances at Temu. How to Apply Temu Coupon Code? Using the TemuCoupon code $40 off is a breeze. All you need to do is follow these simple steps:     1    Visit the Temu website or app and browse through the vast collection of products.     2    Once you’ve added the items you wish to purchase to your cart, proceed to the checkout page.     3    During the checkout process, you’ll be prompted to enter a coupon code or promo code.     4    Type in the coupon code: [acx318439] and click “Apply.”     5    Voila! You’ll instantly see the $40 discount reflected in your total purchase amount. Temu New User Coupon: Up To 90% OFF For Existing Customers Temu Existing customer’s coupon codes are designed just for new customers, offering the biggest discounts 90% and the best deals currently available on Temu. To maximize your savings, download the Temu app and apply our Temu new user coupon during checkout.     •    acx318439: New users can get up to 80% extra off.     •    acx318439: Get a massive 40% off your first order!     •    acx318439: Get 20% off on your first order; no minimum spending required.     •    acx318439: Take an extra 15% off your first order on top of existing discounts.     •    acx318439: Temu UK Enjoy a 40% discount on your entire first purchase.  
    • New users at Temureceive a 40 Off discount on orders over 40 Off Use the code [acx318439] during checkout to get TemuDiscount 40 Off For New Users. You n save 40 Off off your first order with the Promo Code available for a limited time only. Extra 30% off for new and existing customers + Up to $40 Off % off & more. Temu Promo Codes for New users- [acx318439] Temudiscount code for New customers- [acx318439] Temu $40 Off Promo Code- [acx318439] what are Temu codes- acx318439 does Temu give you $40 Off - [acx318439] Yes Verified Temu Promo Code january 2025- {acx318439} TemuNew customer offer {acx318439} Temudiscount codejanuary 2025 {acx318439} 40 off Promo Code Temu {acx318439} Temu 40% off any order {acx318439} 40 dollar off Temu code {acx318439} TemuCoupon $40 Off off for New customers There are a number of discounts and deals shoppers n take advantage of with the Teemu Coupon Bundle [acx318439]. TemuCoupon $40 Off off for New customers [acx318439] will save you $40 Off on your order. To get a discount, click on the item to purchase and enter the code. You n think of it as a supercharged savings pack for all your shopping needs Temu Promo Code 80% off – [acx318439] Free Temu codes 50% off – [acx318439] TemuCoupon $40 Off off – [acx318439] Temu buy to get ₱39 – [acx318439] Temu 129 coupon bundle – [acx318439] Temu buy 3 to get €99 – [acx318439] Exclusive $40 Off Off TemuDiscount Code Temu $40 Off Off Promo Code : (acx318439) Temu Discount Code $40 Off Bundle acx318439) acx318439 Temu $40 Off off Promo Code for Exsting users : acx318439) Temu Promo Code $40 Off off Temu 40 Off coupon code (acx318439) will save you 40 Off on your order. To get a discount, click on the item to purchase and enter the code. Yes, Temu offers 40 Off Coupon Code “acx318439” for Existing Customers.  You can get a 40 Off bonus plus 30% off any purchase at Temu with the 40 Off Coupon Bundle at Temu if you sign up with the referral code [acx318439] and make a first purchase of $40 Off or more. Temu Promo Code 40 off-{acx318439} Temu Promo Code -{acx318439} Temu Promo Code $40 Off off-{acx318439} kubonus code -{acx318439} Get ready to unlock a world of savings with our free Temu UK coupons! We’ve got you covered with a wide range of Temu UK coupon code options that will help you maximize your shopping experience.30% Off Temu UK Coupons, Promo Codes + 25% Cash Back [ acx318439]   Yes, Temu offers 40 off coupon code {acx318439} for first-time users. You can get a $40 bonus plus 40% off any purchase at Temu with the $40 Coupon Bundle if you sign up with the referral code [acx318439] and make a first purchase of $40 or more. If you are who wish to join Temu, then you should use this exclusive TemuCoupon code 40 off (acx318439) and get 40 off on your purchase with Temu. You can get a 40% discount with TemuCoupon code {acx318439}. This exclusive offer is for existing customers and can be used for a 40 reduction on your total purchase. Enter coupon code {acx318439} at checkout to avail of the discount. You can use the code {acx318439} to get a 40 off TemuCoupon as a new customer. Apply this TemuCoupon code $40 off (acx318439) to get a $40 discount on your shopping with Temu. If you’re a first-time user and looking for a TemuCoupon code $40 first time user(acx318439) then using this code will give you a flat $40 Off and a 90% discount on your Temu shopping.     •    acx318439: Enjoy flat 40% off on your first Temu order.     •    acx318439: Download the Temu app and get an additional 40% off.     •    acx318439: Celebrate spring with up to 90% discount on selected items.     •    acx318439: Score up to 90% off on clearance items.     •    acx318439: Beat the heat with hot summer savings of up to 90% off.     •    acx318439: Temu UK Coupon Code to 40% off on Appliances at Temu. How to Apply Temu Coupon Code? Using the TemuCoupon code $40 off is a breeze. All you need to do is follow these simple steps:     1    Visit the Temu website or app and browse through the vast collection of products.     2    Once you’ve added the items you wish to purchase to your cart, proceed to the checkout page.     3    During the checkout process, you’ll be prompted to enter a coupon code or promo code.     4    Type in the coupon code: [acx318439] and click “Apply.”     5    Voila! You’ll instantly see the $40 discount reflected in your total purchase amount. Temu New User Coupon: Up To 90% OFF For Existing Customers Temu Existing customer’s coupon codes are designed just for new customers, offering the biggest discounts 90% and the best deals currently available on Temu. To maximize your savings, download the Temu app and apply our Temu new user coupon during checkout.     •    acx318439: New users can get up to 80% extra off.     •    acx318439: Get a massive 40% off your first order!     •    acx318439: Get 20% off on your first order; no minimum spending required.     •    acx318439: Take an extra 15% off your first order on top of existing discounts.     •    acx318439: Temu UK Enjoy a 40% discount on your entire first purchase.  
    • New users at Temureceive a 40 Off discount on orders over 40 Off Use the code [acx318439] during checkout to get TemuDiscount 40 Off For New Users. You n save 40 Off off your first order with the Promo Code available for a limited time only. Extra 30% off for new and existing customers + Up to $40 Off % off & more. Temu Promo Codes for New users- [acx318439] Temudiscount code for New customers- [acx318439] Temu $40 Off Promo Code- [acx318439] what are Temu codes- acx318439 does Temu give you $40 Off - [acx318439] Yes Verified Temu Promo Code january 2025- {acx318439} TemuNew customer offer {acx318439} Temudiscount codejanuary 2025 {acx318439} 40 off Promo Code Temu {acx318439} Temu 40% off any order {acx318439} 40 dollar off Temu code {acx318439} TemuCoupon $40 Off off for New customers There are a number of discounts and deals shoppers n take advantage of with the Teemu Coupon Bundle [acx318439]. TemuCoupon $40 Off off for New customers [acx318439] will save you $40 Off on your order. To get a discount, click on the item to purchase and enter the code. You n think of it as a supercharged savings pack for all your shopping needs Temu Promo Code 80% off – [acx318439] Free Temu codes 50% off – [acx318439] TemuCoupon $40 Off off – [acx318439] Temu buy to get ₱39 – [acx318439] Temu 129 coupon bundle – [acx318439] Temu buy 3 to get €99 – [acx318439] Exclusive $40 Off Off TemuDiscount Code Temu $40 Off Off Promo Code : (acx318439) Temu Discount Code $40 Off Bundle acx318439) acx318439 Temu $40 Off off Promo Code for Exsting users : acx318439) Temu Promo Code $40 Off off Temu 40 Off coupon code (acx318439) will save you 40 Off on your order. To get a discount, click on the item to purchase and enter the code. Yes, Temu offers 40 Off Coupon Code “acx318439” for Existing Customers.  You can get a 40 Off bonus plus 30% off any purchase at Temu with the 40 Off Coupon Bundle at Temu if you sign up with the referral code [acx318439] and make a first purchase of $40 Off or more. Temu Promo Code 40 off-{acx318439} Temu Promo Code -{acx318439} Temu Promo Code $40 Off off-{acx318439} kubonus code -{acx318439} Get ready to unlock a world of savings with our free Temu UK coupons! We’ve got you covered with a wide range of Temu UK coupon code options that will help you maximize your shopping experience.30% Off Temu UK Coupons, Promo Codes + 25% Cash Back [ acx318439]   Yes, Temu offers 40 off coupon code {acx318439} for first-time users. You can get a $40 bonus plus 40% off any purchase at Temu with the $40 Coupon Bundle if you sign up with the referral code [acx318439] and make a first purchase of $40 or more. If you are who wish to join Temu, then you should use this exclusive TemuCoupon code 40 off (acx318439) and get 40 off on your purchase with Temu. You can get a 40% discount with TemuCoupon code {acx318439}. This exclusive offer is for existing customers and can be used for a 40 reduction on your total purchase. Enter coupon code {acx318439} at checkout to avail of the discount. You can use the code {acx318439} to get a 40 off TemuCoupon as a new customer. Apply this TemuCoupon code $40 off (acx318439) to get a $40 discount on your shopping with Temu. If you’re a first-time user and looking for a TemuCoupon code $40 first time user(acx318439) then using this code will give you a flat $40 Off and a 90% discount on your Temu shopping.     •    acx318439: Enjoy flat 40% off on your first Temu order.     •    acx318439: Download the Temu app and get an additional 40% off.     •    acx318439: Celebrate spring with up to 90% discount on selected items.     •    acx318439: Score up to 90% off on clearance items.     •    acx318439: Beat the heat with hot summer savings of up to 90% off.     •    acx318439: Temu UK Coupon Code to 40% off on Appliances at Temu. How to Apply Temu Coupon Code? Using the TemuCoupon code $40 off is a breeze. All you need to do is follow these simple steps:     1    Visit the Temu website or app and browse through the vast collection of products.     2    Once you’ve added the items you wish to purchase to your cart, proceed to the checkout page.     3    During the checkout process, you’ll be prompted to enter a coupon code or promo code.     4    Type in the coupon code: [acx318439] and click “Apply.”     5    Voila! You’ll instantly see the $40 discount reflected in your total purchase amount. Temu New User Coupon: Up To 90% OFF For Existing Customers Temu Existing customer’s coupon codes are designed just for new customers, offering the biggest discounts 90% and the best deals currently available on Temu. To maximize your savings, download the Temu app and apply our Temu new user coupon during checkout.     •    acx318439: New users can get up to 80% extra off.     •    acx318439: Get a massive 40% off your first order!     •    acx318439: Get 20% off on your first order; no minimum spending required.     •    acx318439: Take an extra 15% off your first order on top of existing discounts.     •    acx318439: Temu UK Enjoy a 40% discount on your entire first purchase.  
    • It is an issue with Pixelmon - maybe report it to the creators
    • Please read the FAQ (https://forums.minecraftforge.net/topic/125488-rules-and-frequently-asked-questions-faq/) and post logs as described there for further help.  
  • Topics

×
×
  • Create New...

Important Information

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