From faa3058518956162835142ea3acf9122e7cc6410 Mon Sep 17 00:00:00 2001 From: Nirad Date: Thu, 15 Nov 2012 01:12:06 -0500 Subject: [PATCH] Add int BlockId usefull for the AddObjectVehiclePacket --- Chraft/World/Blocks/Physics/BaseFallingPhysics.cs | 9 ++------- Chraft/World/Blocks/Physics/IBlockPhysics.cs | 2 +- 2 files changed, 3 insertions(+), 8 deletions(-) diff --git a/Chraft/World/Blocks/Physics/BaseFallingPhysics.cs b/Chraft/World/Blocks/Physics/BaseFallingPhysics.cs index d70933cf..b1e9579f 100644 --- a/Chraft/World/Blocks/Physics/BaseFallingPhysics.cs +++ b/Chraft/World/Blocks/Physics/BaseFallingPhysics.cs @@ -36,14 +36,9 @@ protected BaseFallingPhysics(WorldManager world, AbsWorldCoords pos) World = world; Position = pos; EntityId = world.Server.AllocateEntity(); - - CreateEntityPacket entity = new CreateEntityPacket { EntityId = EntityId }; - World.Server.SendPacketToNearbyPlayers(World, - UniversalCoords.FromAbsWorld(Position), - entity); } - public virtual void Start() + public virtual void Start(int blockId) { if (IsPlaying) return; @@ -51,7 +46,7 @@ public virtual void Start() { EntityId = EntityId, Type = Type, - FireBallThrowerEid = 0, + FireBallThrowerEid = blockId,//TODO Block data here ??? X = Position.X, Y = Position.Y, Z = Position.Z diff --git a/Chraft/World/Blocks/Physics/IBlockPhysics.cs b/Chraft/World/Blocks/Physics/IBlockPhysics.cs index 408fa404..bfb0fda8 100644 --- a/Chraft/World/Blocks/Physics/IBlockPhysics.cs +++ b/Chraft/World/Blocks/Physics/IBlockPhysics.cs @@ -19,7 +19,7 @@ namespace Chraft.World.Blocks.Physics { interface IBlockPhysics { - void Start(); + void Start(int blockId); void Simulate(); void Stop(bool forceStop = false); }