I want to spawn a player like entity just for decoration.
Basically, how can I clone a player's name and skin to spawn an fake player?
I have tried FakePlayerFactory by using a online player GameProfile, but I got the notification "[Server thread/WARN]: Fetching addPacket for removed entity"
Also if I try to use a new GameProfile to get a new FakePlayer, game will crash...
I have tried to read the code with fml and forge, but I still feel confused with some words.
My basic understanding now is minecraft first calculate the noise which will determine the 2D pattern of the landscape(is it? It's just a speculation),
then populate,
and then decorate.
It seems that the chunk provider and biome implements at the "populate" stage.... but what about the actual stage that minecraft fill the 2d pattern with the block(like stone...dirt)? Is it in the "populate" stage? If it's in "populate" stage, who(what class) is actually filling the block? Or I miss some stages?
For example, I want the to make a mod that set the world gen border. If any biome is already exceeding the border range, the beside biome will be ocean biome so that the world will all end with ocean.
BTW, I try to find the actual "fill block" event, but there are just some events like biome decoration or biome population. I'm not very sure about the usage of these events....
Please post your code using pastebin, and post entire classes (including your Strength class) - it is much more readable.
According to your console log, you are trying to recover some value on both the server and the client, and you can see how the client is always trying to recover 5 whereas the server is trying to recover 10. This is because the server and client tend to have different motion values, not to mention strict equality is very difficult to achieve with floating point values.
Anyway, long story short: ONLY update values on the SERVER, never* the client.
Also, do not use static variables such as "Status.timer++;" bad idea.
I reconstruct these classes for a while and they are work now.(Even though I don't know what's exactly going on......orz) But thanks a lot!
BTW, any suggestion for timer update?
I have seen some mods, like iguana tweak, which implement these kind of things(to not calculate every livingupdate cycle) by making a tick handler to handle key tick... (well.. the code of iguana tweak is too tough for me to really understand now)
if(inflictor instanceof EntityPlayerMP)
System.out.println("catch attack event. mp fires this event. Now mp strength is "+playerSt.getCurrent());
if (inflictor instanceof EntityPlayerMP)
System.out.println("catch attack event. sp fires this event. Now sp strength is " +playerSt.getCurrent());
if(player.getHeldItem()!=null)
{
//TODO make this '20' and '10' dynamic
if(playerSt.getCurrent() <= 20 )
{
0
Hi, can I reproduce this mod introduction in a Chinese Minecraft forum?(www.mcbbs.net)
It will keep the download link and the link of this page.
Basically, it's just translated into Chinese.
Also I will create a zh_CN.lang:
tile.blockModelCitizen.name=模型放置器
0
Fantastic..
I think it would be really popular for modpack makers.
Would you mind me to introduce this post into a Chinese forum?
It will keep your curseforge link.
0
Thanks a lot!
Then I will try to extends EntityLiving.....
0
Have anyone been familiar with it?
I want to spawn a player like entity just for decoration.
Basically, how can I clone a player's name and skin to spawn an fake player?
I have tried FakePlayerFactory by using a online player GameProfile, but I got the notification "[Server thread/WARN]: Fetching addPacket for removed entity"
Also if I try to use a new GameProfile to get a new FakePlayer, game will crash...
0
Anybody is familiar with the world gen process?
I have tried to read the code with fml and forge, but I still feel confused with some words.
My basic understanding now is minecraft first calculate the noise which will determine the 2D pattern of the landscape(is it? It's just a speculation),
then populate,
and then decorate.
It seems that the chunk provider and biome implements at the "populate" stage.... but what about the actual stage that minecraft fill the 2d pattern with the block(like stone...dirt)? Is it in the "populate" stage? If it's in "populate" stage, who(what class) is actually filling the block? Or I miss some stages?
For example, I want the to make a mod that set the world gen border. If any biome is already exceeding the border range, the beside biome will be ocean biome so that the world will all end with ocean.
BTW, I try to find the actual "fill block" event, but there are just some events like biome decoration or biome population. I'm not very sure about the usage of these events....
0
WOW!! How did you work it out!
I have similar problem for binding block texture.
The register is here
https://github.com/ci010/Vending/blob/master/[1.8]Vending/src/main/java/info/jbcs/minecraft/vending/client/ClientProxy.java
The block have 16 metablock(0-15)
The blockstates
https://github.com/ci010/Vending/blob/master/[1.8]Vending/src/main/resources/assets/vending/blockstates/vendingMachine.json
and the model
https://github.com/ci010/Vending/blob/master/[1.8]Vending/src/main/resources/assets/vending/models/block/vendingMachine.json
My forge version is 1.8-11.14.3.1450
Any sugguestion? Or did I have any misunderstanding on these?
Thank a lot.
BTW, what's your final version looks like?
Maybe it will inspire me.
0
Wow! That's right! I even forget the case of multiplayer...
I think the modular method is a good idea and I will try it. Thanks a lot again.
0
I reconstruct these classes for a while and they are work now.(Even though I don't know what's exactly going on......orz) But thanks a lot!
BTW, any suggestion for timer update?
I have seen some mods, like iguana tweak, which implement these kind of things(to not calculate every livingupdate cycle) by making a tick handler to handle key tick... (well.. the code of iguana tweak is too tough for me to really understand now)
0
I'm still a little bit confused about the mechanic of the dataWatcher.
I have these code
It works for the single player. I write the gui part as this tutorial has.
I print the string on screen by
The string on screen show the correct value of the prop. But when I get the prop value in my attack event:
It just doesn't work. Both sp and mp get 0 value..... I don't know why....
Here is a part of console:
[19:09:38] [Server thread/INFO] [STDOUT]: [net.ci010.attributesmod.handler.CommonHandler:LivingUpdate:196]: try to recover 10
[19:09:39] [Client thread/INFO] [STDOUT]: [net.ci010.attributesmod.handler.CommonHandler:LivingUpdate:202]: try to recover 5
[19:09:39] [Server thread/INFO] [STDOUT]: [net.ci010.attributesmod.handler.CommonHandler:LivingUpdate:196]: try to recover 10
[19:09:39] [Server thread/INFO] [STDOUT]: [net.ci010.attributesmod.handler.CommonHandler:attackEvent:132]: catch attack event. mp fires this event. Now mp strength is 0
[19:09:39] [Server thread/INFO] [STDOUT]: [net.ci010.attributesmod.handler.CommonHandler:attackEvent:134]: catch attack event. sp fires this event. Now sp strength is 0
[19:09:39] [Server thread/INFO] [STDOUT]: [net.ci010.attributesmod.handler.CommonHandler:attackEvent:155]: canceled lower than 10 (0
[19:09:40] [Client thread/INFO] [STDOUT]: [net.ci010.attributesmod.handler.CommonHandler:LivingUpdate:202]: try to recover 5
[19:09:40] [Server thread/INFO] [STDOUT]: [net.ci010.attributesmod.handler.CommonHandler:LivingUpdate:202]: try to recover 5
[19:09:41] [Client thread/INFO] [STDOUT]: [net.ci010.attributesmod.handler.CommonHandler:LivingUpdate:202]: try to recover 5
[19:09:41] [Server thread/INFO] [STDOUT]: [net.ci010.attributesmod.handler.CommonHandler:LivingUpdate:196]: try to recover 10
[19:09:42] [Server thread/INFO] [STDOUT]: [net.ci010.attributesmod.handler.CommonHandler:attackEvent:132]: catch attack event. mp fires this event. Now mp strength is 0
[19:09:42] [Server thread/INFO] [STDOUT]: [net.ci010.attributesmod.handler.CommonHandler:attackEvent:134]: catch attack event. sp fires this event. Now sp strength is 0
[19:09:42] [Server thread/INFO] [STDOUT]: [net.ci010.attributesmod.handler.CommonHandler:attackEvent:155]: canceled lower than 10 (0
[19:09:42] [Client thread/INFO] [STDOUT]: [net.ci010.attributesmod.handler.CommonHandler:LivingUpdate:202]: try to recover 5
[19:09:42] [Server thread/INFO] [STDOUT]: [net.ci010.attributesmod.handler.CommonHandler:LivingUpdate:196]: try to recover 10
[19:09:43] [Client thread/INFO] [STDOUT]: [net.ci010.attributesmod.handler.CommonHandler:LivingUpdate:196]: try to recover 10
[19:09:43] [Server thread/INFO] [STDOUT]: [net.ci010.attributesmod.handler.CommonHandler:attackEvent:132]: catch attack event. mp fires this event. Now mp strength is 0
[19:09:43] [Server thread/INFO] [STDOUT]: [net.ci010.attributesmod.handler.CommonHandler:attackEvent:134]: catch attack event. sp fires this event. Now sp strength is 0
[19:09:43] [Server thread/INFO] [STDOUT]: [net.ci010.attributesmod.handler.CommonHandler:attackEvent:155]: canceled lower than 10 (0
[19:09:43] [Server thread/INFO] [STDOUT]: [net.ci010.attributesmod.handler.CommonHandler:LivingUpdate:202]: try to recover 5
[19:09:44] [Client thread/INFO] [STDOUT]: [net.ci010.attributesmod.handler.CommonHandler:LivingUpdate:202]: try to recover 5
[19:09:44] [Server thread/INFO] [STDOUT]: [net.ci010.attributesmod.handler.CommonHandler:attackEvent:132]: catch attack event. mp fires this event. Now mp strength is 0
[19:09:44] [Server thread/INFO] [STDOUT]: [net.ci010.attributesmod.handler.CommonHandler:attackEvent:134]: catch attack event. sp fires this event. Now sp strength is 0
[19:09:44] [Server thread/INFO] [STDOUT]: [net.ci010.attributesmod.handler.CommonHandler:attackEvent:155]: canceled lower than 10 (0
[19:09:44] [Server thread/INFO] [STDOUT]: [net.ci010.attributesmod.handler.CommonHandler:LivingUpdate:196]: try to recover 10
[19:09:45] [Client thread/INFO] [STDOUT]: [net.ci010.attributesmod.handler.CommonHandler:LivingUpdate:202]: try to recover 5
[19:09:45] [Server thread/INFO] [STDOUT]: [net.ci010.attributesmod.handler.CommonHandler:attackEvent:132]: catch attack event. mp fires this event. Now mp strength is 0
[19:09:45] [Server thread/INFO] [STDOUT]: [net.ci010.attributesmod.handler.CommonHandler:attackEvent:134]: catch attack event. sp fires this event. Now sp strength is 0
[19:09:45] [Server thread/INFO] [STDOUT]: [net.ci010.attributesmod.handler.CommonHandler:attackEvent:155]: canceled lower than 10 (0
[19:09:46] [Client thread/INFO] [STDOUT]: [net.ci010.attributesmod.handler.CommonHandler:LivingUpdate:202]: try to recover 5
[19:09:46] [Client thread/INFO] [STDOUT]: [net.ci010.attributesmod.handler.CommonHandler:LivingUpdate:196]: try to recover 10
[19:09:47] [Server thread/INFO] [STDOUT]: [net.ci010.attributesmod.handler.CommonHandler:LivingUpdate:196]: try to recover 10
[19:09:47] [Server thread/INFO] [STDOUT]: [net.ci010.attributesmod.handler.CommonHandler:attackEvent:132]: catch attack event. mp fires this event. Now mp strength is 0
[19:09:47] [Server thread/INFO] [STDOUT]: [net.ci010.attributesmod.handler.CommonHandler:attackEvent:134]: catch attack event. sp fires this event. Now sp strength is 0
[19:09:47] [Server thread/INFO] [STDOUT]: [net.ci010.attributesmod.handler.CommonHandler:attackEvent:155]: canceled lower than 10 (0
[19:09:47] [Client thread/INFO] [STDOUT]: [net.ci010.attributesmod.handler.CommonHandler:LivingUpdate:202]: try to recover 5
[19:09:48] [Server thread/INFO] [STDOUT]: [net.ci010.attributesmod.handler.CommonHandler:LivingUpdate:202]: try to recover 5
[19:09:48] [Client thread/INFO] [STDOUT]: [net.ci010.attributesmod.handler.CommonHandler:LivingUpdate:202]: try to recover 5
[19:09:49] [Server thread/INFO] [STDOUT]: [net.ci010.attributesmod.handler.CommonHandler:attackEvent:132]: catch attack event. mp fires this event. Now mp strength is 0
[19:09:49] [Server thread/INFO] [STDOUT]: [net.ci010.attributesmod.handler.CommonHandler:attackEvent:134]: catch attack event. sp fires this event. Now sp strength is 0
[19:09:49] [Server thread/INFO] [STDOUT]: [net.ci010.attributesmod.handler.CommonHandler:attackEvent:155]: canceled lower than 10 (0
[19:09:49] [Server thread/INFO] [STDOUT]: [net.ci010.attributesmod.handler.CommonHandler:LivingUpdate:196]: try to recover 10
[19:09:49] [Client thread/INFO] [STDOUT]: [net.ci010.attributesmod.handler.CommonHandler:LivingUpdate:202]: try to recover 5
[19:09:50] [Server thread/INFO] [STDOUT]: [net.ci010.attributesmod.handler.CommonHandler:LivingUpdate:202]: try to recover 5
[19:09:50] [Server thread/INFO] [STDOUT]: [net.ci010.attributesmod.handler.CommonHandler:attackEvent:132]: catch attack event. mp fires this event. Now mp strength is 0
[19:09:50] [Server thread/INFO] [STDOUT]: [net.ci010.attributesmod.handler.CommonHandler:attackEvent:134]: catch attack event. sp fires this event. Now sp strength is 0
[19:09:50] [Server thread/INFO] [STDOUT]: [net.ci010.attributesmod.handler.CommonHandler:attackEvent:155]: canceled lower than 10 (0
[19:09:50] [Client thread/INFO] [STDOUT]: [net.ci010.attributesmod.handler.CommonHandler:LivingUpdate:202]: try to recover 5
[19:09:51] [Server thread/INFO] [STDOUT]: [net.ci010.attributesmod.handler.CommonHandler:LivingUpdate:196]: try to recover 10
[19:09:51] [Server thread/INFO] [STDOUT]: [net.ci010.attributesmod.handler.CommonHandler:attackEvent:132]: catch attack event. mp fires this event. Now mp strength is 0
[19:09:51] [Server thread/INFO] [STDOUT]: [net.ci010.attributesmod.handler.CommonHandler:attackEvent:134]: catch attack event. sp fires this event. Now sp strength is 0
[19:09:51] [Server thread/INFO] [STDOUT]: [net.ci010.attributesmod.handler.CommonHandler:attackEvent:155]: canceled lower than 10 (0
[19:09:51] [Client thread/INFO] [STDOUT]: [net.ci010.attributesmod.handler.CommonHandler:LivingUpdate:202]: try to recover 5
[19:09:52] [Server thread/INFO] [STDOUT]: [net.ci010.attributesmod.handler.CommonHandler:LivingUpdate:196]: try to recover 10
[19:09:52] [Client thread/INFO] [STDOUT]: [net.ci010.attributesmod.handler.CommonHandler:LivingUpdate:202]: try to recover 5
0
I'm little confused about the IExtendedEntityProperties, or we can say the mechanic of minecraft's properties.
Does it run over the ram when minecraft normal running and save as NBT when minecraft closing?
Or running in some other ways?
Also about the packet, is that means after you register a packet, the minecraft will manage when the packet should be sent?
If a mod have a function changing the exp of player, do we need a extra packet to syn the exp again?
0
Is there any way to let the RWG mod generate with in a range?
I mean I want the world's bound that ends with infinite ocean.....
0
Or maybe we should see the shader doesn't compatible with these new blocks?
0
Also does mcpatcher works on this mod?
0
But thank you anyway.
0
ofFastMath:false
Do I need to get rid of it? or just ignore it