mirror of
https://github.com/MinecraftForge/MinecraftForge.git
synced 2026-11-22 21:20:12 +00:00
Move spawn fuzz to WorldProvider/WorldType, useful for VoidWorld types.
This commit is contained in:
1 parent
af6b8820d4
commit
a44181a192
3 files changed
+60
-2
No files matched your search
@@ -10,7 +10,26 @@
|
||||
|
||||
public class EntityPlayerMP extends EntityPlayer implements ICrafting
|
||||
{
|
||||
@@ -329,8 +332,27 @@
|
||||
@@ -78,17 +81,10 @@
|
||||
par4ItemInWorldManager.thisPlayerMP = this;
|
||||
this.theItemInWorldManager = par4ItemInWorldManager;
|
||||
this.renderDistance = par1MinecraftServer.getConfigurationManager().getViewDistance();
|
||||
- ChunkCoordinates var5 = par2World.getSpawnPoint();
|
||||
+ ChunkCoordinates var5 = par2World.provider.getRandomizedSpawnPoint();
|
||||
int var6 = var5.posX;
|
||||
int var7 = var5.posZ;
|
||||
int var8 = var5.posY;
|
||||
-
|
||||
- if (!par2World.provider.hasNoSky && par2World.getWorldInfo().getGameType() != EnumGameType.ADVENTURE)
|
||||
- {
|
||||
- var6 += this.rand.nextInt(20) - 10;
|
||||
- var8 = par2World.getTopSolidOrLiquidBlock(var6, var7);
|
||||
- var7 += this.rand.nextInt(20) - 10;
|
||||
- }
|
||||
|
||||
this.setLocationAndAngles((double)var6 + 0.5D, (double)var8, (double)var7 + 0.5D, 0.0F, 0.0F);
|
||||
this.mcServer = par1MinecraftServer;
|
||||
@@ -329,8 +325,27 @@
|
||||
*/
|
||||
public void onDeath(DamageSource par1DamageSource)
|
||||
{
|
||||
|
||||
Reference in new issue
Block a user