ReGen Chunk in selfmade World
#8
Hi,

function MyOnPlayerRightClick(Player, BlockX, BlockY, BlockZ, BlockFace, CursorX, CursorY, CursorZ) -- See API docs for parameters of all hooks

 local chunkx = math.floor(BlockX / 16)
 local chunkz = math.floor(BlockZ / 16)

 SourceWorld = cRoot:Get():GetWorld(Player:GetWorld():GetName() .. '_backup')
 DestWorld = Player:GetWorld()
 --print(backUpWorld:GetName())

 local ba = cBlockArea()


 local startX = math.floor(chunkx * 16)
 local endX = math.floor(chunkx * 16) + 15
 local startZ = math.floor(chunkz * 16)
 local endZ = math.floor(chunkz * 16) + 15

 local cubo = cCuboid(startX,1,startZ,endX,255,endZ)

 SourceWorld:ChunkStay({{chunkx, chunkz}}, nil,
  function()
    ba:Read(SourceWorld, cubo)
    DestWorld:QueueTask(
      function()
        ba:Write(DestWorld, startX, 2, startZ)
        ba:Clear()
      end
    )
  end
)

end

and my terminal says:

Code:
[20:56:44] cChunk::WriteBlockArea(): unsupported datatype request, can write only types + metas (0x3), requested 0x0. Ignoring.

Whats my fail?
Reply
Thanks given by:


Messages In This Thread
ReGen Chunk in selfmade World - by moiko89 - 12-17-2016, 10:13 PM
RE: ReGen Chunk in selfmade World - by NiLSPACE - 12-17-2016, 10:32 PM
RE: ReGen Chunk in selfmade World - by xoft - 12-17-2016, 10:42 PM
RE: ReGen Chunk in selfmade World - by moiko89 - 05-14-2017, 10:01 PM
RE: ReGen Chunk in selfmade World - by xoft - 05-15-2017, 05:18 AM
RE: ReGen Chunk in selfmade World - by moiko89 - 05-16-2017, 04:16 AM
RE: ReGen Chunk in selfmade World - by xoft - 05-16-2017, 07:41 AM
RE: ReGen Chunk in selfmade World - by moiko89 - 05-17-2017, 05:04 AM
RE: ReGen Chunk in selfmade World - by xoft - 05-17-2017, 07:56 AM



Users browsing this thread: 3 Guest(s)