Kerby64
    Preparing search index...

    VoxelEngine class manages the voxel world, including chunk generation and rendering. It handles the loading of chunks within a specified render distance from the player. It uses compute shaders for efficient chunk generation and updates the scene with the generated chunks.

    Index

    Constructors

    Properties

    renderDistance: 12

    Accessors

    • get worldType(): | {
          map: (
              | "bedrock"
              | "jukebox"
              | "debug"
              | "debug2"
              | "water"
              | "diamond_ore"
              | "gold_ore"
              | "redstone_ore"
              | "coal_ore"
              | "emerald_ore"
              | "lapis_ore"
              | "iron_ore"
              | "oak_leaves"
              | "oak_log"
              | "oak_planks"
              | "tnt"
              | "bookshelf"
              | "coal_block"
              | "hay_block"
              | "crafting_table"
              | "dirt"
              | "stone"
              | "glass"
              | "obsidian"
              | "grass_block"
              | "sand"
              | "gravel"
              | "clay"
              | "snow"
              | "ice"
              | "cobblestone"
              | "stone_bricks"
              | "bricks"
              | "glowstone"
              | "furnace"
              | "pumpkin"
              | "carved_pumpkin"
          )[];
          type: "flat";
      }
      | { type: "normal" }

      Returns
          | {
              map: (
                  | "bedrock"
                  | "jukebox"
                  | "debug"
                  | "debug2"
                  | "water"
                  | "diamond_ore"
                  | "gold_ore"
                  | "redstone_ore"
                  | "coal_ore"
                  | "emerald_ore"
                  | "lapis_ore"
                  | "iron_ore"
                  | "oak_leaves"
                  | "oak_log"
                  | "oak_planks"
                  | "tnt"
                  | "bookshelf"
                  | "coal_block"
                  | "hay_block"
                  | "crafting_table"
                  | "dirt"
                  | "stone"
                  | "glass"
                  | "obsidian"
                  | "grass_block"
                  | "sand"
                  | "gravel"
                  | "clay"
                  | "snow"
                  | "ice"
                  | "cobblestone"
                  | "stone_bricks"
                  | "bricks"
                  | "glowstone"
                  | "furnace"
                  | "pumpkin"
                  | "carved_pumpkin"
              )[];
              type: "flat";
          }
          | { type: "normal" }

    • set worldType(
          worldtype:
              | {
                  map: (
                      | "bedrock"
                      | "jukebox"
                      | "debug"
                      | "debug2"
                      | "water"
                      | "diamond_ore"
                      | "gold_ore"
                      | "redstone_ore"
                      | "coal_ore"
                      | "emerald_ore"
                      | "lapis_ore"
                      | "iron_ore"
                      | "oak_leaves"
                      | "oak_log"
                      | "oak_planks"
                      | "tnt"
                      | "bookshelf"
                      | "coal_block"
                      | "hay_block"
                      | "crafting_table"
                      | "dirt"
                      | "stone"
                      | "glass"
                      | "obsidian"
                      | "grass_block"
                      | "sand"
                      | "gravel"
                      | "clay"
                      | "snow"
                      | "ice"
                      | "cobblestone"
                      | "stone_bricks"
                      | "bricks"
                      | "glowstone"
                      | "furnace"
                      | "pumpkin"
                      | "carved_pumpkin"
                  )[];
                  type: "flat";
              }
              | { type: "normal" },
      ): void

      Parameters

      • worldtype:
            | {
                map: (
                    | "bedrock"
                    | "jukebox"
                    | "debug"
                    | "debug2"
                    | "water"
                    | "diamond_ore"
                    | "gold_ore"
                    | "redstone_ore"
                    | "coal_ore"
                    | "emerald_ore"
                    | "lapis_ore"
                    | "iron_ore"
                    | "oak_leaves"
                    | "oak_log"
                    | "oak_planks"
                    | "tnt"
                    | "bookshelf"
                    | "coal_block"
                    | "hay_block"
                    | "crafting_table"
                    | "dirt"
                    | "stone"
                    | "glass"
                    | "obsidian"
                    | "grass_block"
                    | "sand"
                    | "gravel"
                    | "clay"
                    | "snow"
                    | "ice"
                    | "cobblestone"
                    | "stone_bricks"
                    | "bricks"
                    | "glowstone"
                    | "furnace"
                    | "pumpkin"
                    | "carved_pumpkin"
                )[];
                type: "flat";
            }
            | { type: "normal" }

      Returns void

    Methods

    • Parameters

      • x: number
      • z: number

      Returns number

    • Parameters

      • playerPosition: Vector3

      Returns void