├── app
├── .gitignore
├── src
│ └── main
│ │ ├── res
│ │ ├── values
│ │ │ ├── strings.xml
│ │ │ ├── attrs.xml
│ │ │ └── themes.xml
│ │ ├── mipmap-hdpi
│ │ │ └── ic_launcher_adaptive_fore.png
│ │ ├── mipmap-mdpi
│ │ │ └── ic_launcher_adaptive_fore.png
│ │ ├── mipmap-xhdpi
│ │ │ └── ic_launcher_adaptive_fore.png
│ │ ├── mipmap-xxhdpi
│ │ │ └── ic_launcher_adaptive_fore.png
│ │ ├── mipmap-xxxhdpi
│ │ │ └── ic_launcher_adaptive_fore.png
│ │ ├── xml
│ │ │ ├── backup_rules.xml
│ │ │ └── data_extraction_rules.xml
│ │ ├── mipmap-anydpi-v26
│ │ │ └── ic_launcher.xml
│ │ ├── values-v31
│ │ │ └── themes.xml
│ │ └── values-v27
│ │ │ └── themes.xml
│ │ └── AndroidManifest.xml
├── proguard-rules.pro
└── build.gradle
├── settings.gradle
├── gradle
└── wrapper
│ ├── gradle-wrapper.jar
│ └── gradle-wrapper.properties
├── core
├── src
│ ├── main
│ │ ├── resources
│ │ │ ├── Textures
│ │ │ │ ├── gear.png
│ │ │ │ ├── moon.png
│ │ │ │ ├── moon.xcf
│ │ │ │ ├── plus.png
│ │ │ │ ├── sun.png
│ │ │ │ ├── sun.xcf
│ │ │ │ ├── cursor.png
│ │ │ │ ├── flight.png
│ │ │ │ ├── ground.png
│ │ │ │ ├── minus.png
│ │ │ │ ├── range.png
│ │ │ │ ├── trash.png
│ │ │ │ ├── airplane.png
│ │ │ │ ├── arrowdown.png
│ │ │ │ ├── arrowjump.png
│ │ │ │ ├── arrowleft.png
│ │ │ │ ├── arrowup.png
│ │ │ │ ├── font-apex.png
│ │ │ │ ├── settings.png
│ │ │ │ ├── arrowright.png
│ │ │ │ ├── arrowdown-full.png
│ │ │ │ ├── arrowjump-full.png
│ │ │ │ ├── arrowleft-full.png
│ │ │ │ ├── arrowup-full.png
│ │ │ │ ├── font-default.png
│ │ │ │ ├── range-filled.png
│ │ │ │ ├── arrowright-full.png
│ │ │ │ ├── arrowdown.svg
│ │ │ │ ├── arrowleft.svg
│ │ │ │ ├── arrowright.svg
│ │ │ │ ├── arrowdown-full.svg
│ │ │ │ ├── arrowup.svg
│ │ │ │ ├── arrowleft-full.svg
│ │ │ │ ├── arrowright-full.svg
│ │ │ │ ├── arrowup-full.svg
│ │ │ │ ├── flight.svg
│ │ │ │ ├── arrowjump.svg
│ │ │ │ ├── arrowjump-full.svg
│ │ │ │ ├── minus.svg
│ │ │ │ ├── range.svg
│ │ │ │ └── plus.svg
│ │ │ ├── ialonsplash.png
│ │ │ ├── ialon-theme
│ │ │ │ ├── bed.png
│ │ │ │ ├── books.png
│ │ │ │ ├── bricks.png
│ │ │ │ ├── dirt.png
│ │ │ │ ├── dummy.png
│ │ │ │ ├── grass.png
│ │ │ │ ├── grass.xcf
│ │ │ │ ├── gravel.png
│ │ │ │ ├── lava.png
│ │ │ │ ├── metal1.png
│ │ │ │ ├── metal2.png
│ │ │ │ ├── metal3.png
│ │ │ │ ├── metal4.png
│ │ │ │ ├── metal5.png
│ │ │ │ ├── oven.png
│ │ │ │ ├── paving.png
│ │ │ │ ├── rail.png
│ │ │ │ ├── rock.png
│ │ │ │ ├── sand.png
│ │ │ │ ├── sand3.png
│ │ │ │ ├── scale.png
│ │ │ │ ├── slate.png
│ │ │ │ ├── snow.png
│ │ │ │ ├── water.png
│ │ │ │ ├── water2.png
│ │ │ │ ├── water3.png
│ │ │ │ ├── water3.xcf
│ │ │ │ ├── water4.png
│ │ │ │ ├── water4.xcf
│ │ │ │ ├── water5.png
│ │ │ │ ├── water5.xcf
│ │ │ │ ├── water6.png
│ │ │ │ ├── window.png
│ │ │ │ ├── drawers.png
│ │ │ │ ├── oak_log.png
│ │ │ │ ├── tile_red.png
│ │ │ │ ├── bedpillow.png
│ │ │ │ ├── birch_log.png
│ │ │ │ ├── cobblestone.png
│ │ │ │ ├── color_black.png
│ │ │ │ ├── color_blue.png
│ │ │ │ ├── color_cyan.png
│ │ │ │ ├── color_green.png
│ │ │ │ ├── color_red.png
│ │ │ │ ├── color_red2.png
│ │ │ │ ├── color_rose.png
│ │ │ │ ├── grass_snow.png
│ │ │ │ ├── item_grass.png
│ │ │ │ ├── oak_leaves.png
│ │ │ │ ├── oak_planks.png
│ │ │ │ ├── rail_curved.png
│ │ │ │ ├── rail_curved.xcf
│ │ │ │ ├── rail_slope.png
│ │ │ │ ├── spruce_log.png
│ │ │ │ ├── test_multi.png
│ │ │ │ ├── water-debug.png
│ │ │ │ ├── white_light.png
│ │ │ │ ├── birch_leaves.png
│ │ │ │ ├── birch_planks.png
│ │ │ │ ├── color_magenta.png
│ │ │ │ ├── color_orange.png
│ │ │ │ ├── color_yellow.png
│ │ │ │ ├── item_seaweed.png
│ │ │ │ ├── palm_tree_log.png
│ │ │ │ ├── spruce_leaves.png
│ │ │ │ ├── spruce_planks.png
│ │ │ │ ├── stone_bricks.png
│ │ │ │ ├── stone_bricks2.png
│ │ │ │ ├── stone_bricks3.png
│ │ │ │ ├── water-normal.png
│ │ │ │ ├── palm_tree_leaves.png
│ │ │ │ ├── palm_tree_planks.png
│ │ │ │ ├── mossy_cobblestone.png
│ │ │ │ ├── mossy_stone_bricks.png
│ │ │ │ ├── water_still.j3m
│ │ │ │ ├── water.j3m
│ │ │ │ └── water_still.bak
│ │ │ ├── Models
│ │ │ │ └── Wagon
│ │ │ │ │ ├── wagon.j3o
│ │ │ │ │ ├── wagon.png
│ │ │ │ │ ├── wagon.blend
│ │ │ │ │ ├── wagon.uv.png
│ │ │ │ │ ├── wagon.texture.xcf
│ │ │ │ │ └── wagon.mtl
│ │ │ ├── Blocks
│ │ │ │ ├── Themes
│ │ │ │ │ ├── faithful
│ │ │ │ │ │ ├── dirt.png
│ │ │ │ │ │ ├── grass.png
│ │ │ │ │ │ ├── rock.png
│ │ │ │ │ │ ├── sand.png
│ │ │ │ │ │ ├── snow.png
│ │ │ │ │ │ ├── bricks.png
│ │ │ │ │ │ ├── gravel.png
│ │ │ │ │ │ ├── oak_log.png
│ │ │ │ │ │ ├── birch_log.png
│ │ │ │ │ │ ├── grass_snow.png
│ │ │ │ │ │ ├── oak_planks.png
│ │ │ │ │ │ ├── spruce_log.png
│ │ │ │ │ │ ├── birch_planks.png
│ │ │ │ │ │ ├── cobblestone.png
│ │ │ │ │ │ ├── stone_bricks.png
│ │ │ │ │ │ ├── palm_tree_log.png
│ │ │ │ │ │ ├── spruce_planks.png
│ │ │ │ │ │ ├── mossy_cobblestone.png
│ │ │ │ │ │ ├── palm_tree_planks.png
│ │ │ │ │ │ ├── mossy_stone_bricks.png
│ │ │ │ │ │ ├── water.j3m
│ │ │ │ │ │ └── water_still.j3m
│ │ │ │ │ └── default-bak
│ │ │ │ │ │ ├── dirt.png
│ │ │ │ │ │ ├── rock.png
│ │ │ │ │ │ ├── sand.png
│ │ │ │ │ │ ├── snow.png
│ │ │ │ │ │ ├── bricks.png
│ │ │ │ │ │ ├── grass.png
│ │ │ │ │ │ ├── gravel.png
│ │ │ │ │ │ ├── oak_log.png
│ │ │ │ │ │ ├── water.png
│ │ │ │ │ │ ├── window.png
│ │ │ │ │ │ ├── birch_log.png
│ │ │ │ │ │ ├── birch_leaves.png
│ │ │ │ │ │ ├── birch_planks.png
│ │ │ │ │ │ ├── cobblestone.png
│ │ │ │ │ │ ├── dirt-normal.png
│ │ │ │ │ │ ├── grass-normal.png
│ │ │ │ │ │ ├── grass_snow.png
│ │ │ │ │ │ ├── oak_leaves.png
│ │ │ │ │ │ ├── oak_planks.png
│ │ │ │ │ │ ├── rock-normal.png
│ │ │ │ │ │ ├── sand-normal.png
│ │ │ │ │ │ ├── snow-normal.png
│ │ │ │ │ │ ├── spruce_log.png
│ │ │ │ │ │ ├── stone_bricks.png
│ │ │ │ │ │ ├── water-normal.png
│ │ │ │ │ │ ├── bricks-normal.png
│ │ │ │ │ │ ├── dirt-parallax.png
│ │ │ │ │ │ ├── grass-overlay.png
│ │ │ │ │ │ ├── grass-parallax.png
│ │ │ │ │ │ ├── gravel-normal.png
│ │ │ │ │ │ ├── oak_log-normal.png
│ │ │ │ │ │ ├── palm_tree_log.png
│ │ │ │ │ │ ├── rock-parallax.png
│ │ │ │ │ │ ├── sand-parallax.png
│ │ │ │ │ │ ├── snow-parallax.png
│ │ │ │ │ │ ├── spruce_leaves.png
│ │ │ │ │ │ ├── spruce_planks.png
│ │ │ │ │ │ ├── birch_log-normal.png
│ │ │ │ │ │ ├── bricks-parallax.png
│ │ │ │ │ │ ├── grass_snow-normal.png
│ │ │ │ │ │ ├── gravel-parallax.png
│ │ │ │ │ │ ├── mossy_cobblestone.png
│ │ │ │ │ │ ├── oak_log-parallax.png
│ │ │ │ │ │ ├── oak_planks-normal.png
│ │ │ │ │ │ ├── palm_tree_leaves.png
│ │ │ │ │ │ ├── palm_tree_planks.png
│ │ │ │ │ │ ├── spruce_log-normal.png
│ │ │ │ │ │ ├── white_cube_light.png
│ │ │ │ │ │ ├── birch_log-parallax.png
│ │ │ │ │ │ ├── birch_planks-normal.png
│ │ │ │ │ │ ├── cobblestone-normal.png
│ │ │ │ │ │ ├── grass_snow-parallax.png
│ │ │ │ │ │ ├── mossy_stone_bricks.png
│ │ │ │ │ │ ├── oak_planks-parallax.png
│ │ │ │ │ │ ├── spruce_log-parallax.png
│ │ │ │ │ │ ├── stone_bricks-normal.png
│ │ │ │ │ │ ├── birch_planks-parallax.png
│ │ │ │ │ │ ├── cobblestone-parallax.png
│ │ │ │ │ │ ├── palm_tree_log-normal.png
│ │ │ │ │ │ ├── palm_tree_log-parallax.png
│ │ │ │ │ │ ├── spruce_planks-normal.png
│ │ │ │ │ │ ├── spruce_planks-parallax.png
│ │ │ │ │ │ ├── stone_bricks-parallax.png
│ │ │ │ │ │ ├── mossy_cobblestone-normal.png
│ │ │ │ │ │ ├── palm_tree_planks-normal.png
│ │ │ │ │ │ ├── mossy_cobblestone-parallax.png
│ │ │ │ │ │ ├── mossy_stone_bricks-normal.png
│ │ │ │ │ │ ├── mossy_stone_bricks-parallax.png
│ │ │ │ │ │ ├── palm_tree_planks-parallax.png
│ │ │ │ │ │ ├── window.j3m
│ │ │ │ │ │ ├── birch_leaves.j3m
│ │ │ │ │ │ ├── oak_leaves-bak.j3m
│ │ │ │ │ │ ├── spruce_leaves.j3m
│ │ │ │ │ │ ├── palm_tree_leaves.j3m
│ │ │ │ │ │ ├── grass.j3m
│ │ │ │ │ │ ├── water.j3m
│ │ │ │ │ │ └── water_still.j3m
│ │ │ │ ├── Materials
│ │ │ │ │ └── default-block.j3m
│ │ │ │ ├── Shaders
│ │ │ │ │ ├── BlendFunctions.glsllib
│ │ │ │ │ ├── Unshaded.vert
│ │ │ │ │ ├── Unshaded.frag
│ │ │ │ │ └── Ialon.frag
│ │ │ │ └── MatDefs
│ │ │ │ │ └── FluidDepth.j3md
│ │ │ ├── blocks.proto
│ │ │ └── logback.xml
│ │ └── java
│ │ │ ├── org
│ │ │ └── delaunois
│ │ │ │ └── ialon
│ │ │ │ ├── EmptyNode.java
│ │ │ │ ├── fastnoise
│ │ │ │ ├── GradientPerturb.java
│ │ │ │ ├── LayerMask.java
│ │ │ │ └── Main.java
│ │ │ │ ├── PlayerListener.java
│ │ │ │ ├── TerrainGenerator.java
│ │ │ │ ├── EmptyGenerator.java
│ │ │ │ ├── WaterLevel.java
│ │ │ │ ├── state
│ │ │ │ ├── ChunkManagerState.java
│ │ │ │ ├── ChunkPagerState.java
│ │ │ │ ├── PhysicsChunkPagerState.java
│ │ │ │ ├── WireframeState.java
│ │ │ │ ├── ChunkSaverState.java
│ │ │ │ ├── ChunkLiquidManagerState.java
│ │ │ │ ├── SettingsValue.java
│ │ │ │ ├── AxesDebugState.java
│ │ │ │ ├── MoonState.java
│ │ │ │ └── WagonState.java
│ │ │ │ ├── control
│ │ │ │ ├── CamFollowSpatialControl.java
│ │ │ │ ├── SpatialFollowCamControl.java
│ │ │ │ └── MoonControl.java
│ │ │ │ ├── InputActionManager.java
│ │ │ │ ├── RotationHelper.java
│ │ │ │ ├── FlatTerrainGenerator.java
│ │ │ │ ├── ui
│ │ │ │ └── UiHelper.java
│ │ │ │ └── IalonShapeSet.java
│ │ │ └── com
│ │ │ └── rvandoosselaer
│ │ │ └── blocks
│ │ │ ├── ChunkGenerator.java
│ │ │ ├── ChunkManagerListener.java
│ │ │ ├── ChunkRepository.java
│ │ │ ├── ChunkResolver.java
│ │ │ ├── BlocksTheme.java
│ │ │ ├── serialize
│ │ │ ├── BlockDTO.java
│ │ │ └── BlockDefinition.java
│ │ │ ├── ChunkManagerState.java
│ │ │ ├── ChunkMeshGenerator.java
│ │ │ ├── FlatTerrainGenerator.java
│ │ │ ├── DirectIntBuffer.java
│ │ │ ├── TypeIds.java
│ │ │ ├── ChunkCache.java
│ │ │ ├── DirectVector2fBuffer.java
│ │ │ ├── DirectVector4fBuffer.java
│ │ │ ├── DirectVector3fBuffer.java
│ │ │ ├── Direction.java
│ │ │ └── ChunkMesh.java
│ └── test
│ │ ├── resources
│ │ ├── scenery
│ │ │ ├── water-ut1
│ │ │ │ ├── expected.zblock
│ │ │ │ └── chunk_0_0_0.zblock
│ │ │ ├── water-ut2
│ │ │ │ ├── expected.zblock
│ │ │ │ └── chunk_0_0_0.zblock
│ │ │ ├── water-ut3
│ │ │ │ ├── expected.zblock
│ │ │ │ └── chunk_0_0_0.zblock
│ │ │ ├── water-ut4
│ │ │ │ ├── expected.zblock
│ │ │ │ └── chunk_0_0_0.zblock
│ │ │ ├── chunkpager
│ │ │ │ └── chunk_0_0_0.zblock
│ │ │ ├── wedge-all
│ │ │ │ └── chunk_0_0_0.zblock
│ │ │ ├── wedge-all2
│ │ │ │ ├── chunk_0_0_0.zblock
│ │ │ │ └── chunk_0_1_0.zblock
│ │ │ ├── modelviewer
│ │ │ │ └── chunk_0_0_0.zblock
│ │ │ └── wedge-single
│ │ │ │ └── chunk_0_0_0.zblock
│ │ └── logback-test.xml
│ │ └── java
│ │ └── org
│ │ └── delaunois
│ │ └── ialon
│ │ ├── WaterTest.java
│ │ ├── BlockSelectionStateTest.java
│ │ └── ChunkManagerTest.java
└── build.gradle
├── .gitignore
├── desktop
├── build.gradle
└── src
│ └── main
│ └── java
│ └── org
│ └── delaunois
│ └── ialon
│ └── DesktopLauncher.java
├── .github
└── workflows
│ ├── gradle.yml
│ └── sonar.yml
├── gradle.properties
└── gradlew.bat
/app/.gitignore:
--------------------------------------------------------------------------------
1 | /build
--------------------------------------------------------------------------------
/settings.gradle:
--------------------------------------------------------------------------------
1 | include ':app', ':core', ':desktop'
2 | rootProject.name = "Ialon"
--------------------------------------------------------------------------------
/app/src/main/res/values/strings.xml:
--------------------------------------------------------------------------------
1 |
2 | Ialon
3 |
--------------------------------------------------------------------------------
/gradle/wrapper/gradle-wrapper.jar:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/gradle/wrapper/gradle-wrapper.jar
--------------------------------------------------------------------------------
/core/src/main/resources/Textures/gear.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/Textures/gear.png
--------------------------------------------------------------------------------
/core/src/main/resources/Textures/moon.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/Textures/moon.png
--------------------------------------------------------------------------------
/core/src/main/resources/Textures/moon.xcf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/Textures/moon.xcf
--------------------------------------------------------------------------------
/core/src/main/resources/Textures/plus.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/Textures/plus.png
--------------------------------------------------------------------------------
/core/src/main/resources/Textures/sun.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/Textures/sun.png
--------------------------------------------------------------------------------
/core/src/main/resources/Textures/sun.xcf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/Textures/sun.xcf
--------------------------------------------------------------------------------
/core/src/main/resources/ialonsplash.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/ialonsplash.png
--------------------------------------------------------------------------------
/core/src/main/resources/Textures/cursor.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/Textures/cursor.png
--------------------------------------------------------------------------------
/core/src/main/resources/Textures/flight.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/Textures/flight.png
--------------------------------------------------------------------------------
/core/src/main/resources/Textures/ground.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/Textures/ground.png
--------------------------------------------------------------------------------
/core/src/main/resources/Textures/minus.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/Textures/minus.png
--------------------------------------------------------------------------------
/core/src/main/resources/Textures/range.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/Textures/range.png
--------------------------------------------------------------------------------
/core/src/main/resources/Textures/trash.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/Textures/trash.png
--------------------------------------------------------------------------------
/core/src/main/resources/ialon-theme/bed.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/ialon-theme/bed.png
--------------------------------------------------------------------------------
/core/src/main/resources/Models/Wagon/wagon.j3o:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/Models/Wagon/wagon.j3o
--------------------------------------------------------------------------------
/core/src/main/resources/Models/Wagon/wagon.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/Models/Wagon/wagon.png
--------------------------------------------------------------------------------
/core/src/main/resources/Textures/airplane.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/Textures/airplane.png
--------------------------------------------------------------------------------
/core/src/main/resources/Textures/arrowdown.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/Textures/arrowdown.png
--------------------------------------------------------------------------------
/core/src/main/resources/Textures/arrowjump.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/Textures/arrowjump.png
--------------------------------------------------------------------------------
/core/src/main/resources/Textures/arrowleft.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/Textures/arrowleft.png
--------------------------------------------------------------------------------
/core/src/main/resources/Textures/arrowup.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/Textures/arrowup.png
--------------------------------------------------------------------------------
/core/src/main/resources/Textures/font-apex.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/Textures/font-apex.png
--------------------------------------------------------------------------------
/core/src/main/resources/Textures/settings.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/Textures/settings.png
--------------------------------------------------------------------------------
/core/src/main/resources/ialon-theme/books.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/ialon-theme/books.png
--------------------------------------------------------------------------------
/core/src/main/resources/ialon-theme/bricks.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/ialon-theme/bricks.png
--------------------------------------------------------------------------------
/core/src/main/resources/ialon-theme/dirt.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/ialon-theme/dirt.png
--------------------------------------------------------------------------------
/core/src/main/resources/ialon-theme/dummy.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/ialon-theme/dummy.png
--------------------------------------------------------------------------------
/core/src/main/resources/ialon-theme/grass.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/ialon-theme/grass.png
--------------------------------------------------------------------------------
/core/src/main/resources/ialon-theme/grass.xcf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/ialon-theme/grass.xcf
--------------------------------------------------------------------------------
/core/src/main/resources/ialon-theme/gravel.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/ialon-theme/gravel.png
--------------------------------------------------------------------------------
/core/src/main/resources/ialon-theme/lava.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/ialon-theme/lava.png
--------------------------------------------------------------------------------
/core/src/main/resources/ialon-theme/metal1.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/ialon-theme/metal1.png
--------------------------------------------------------------------------------
/core/src/main/resources/ialon-theme/metal2.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/ialon-theme/metal2.png
--------------------------------------------------------------------------------
/core/src/main/resources/ialon-theme/metal3.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/ialon-theme/metal3.png
--------------------------------------------------------------------------------
/core/src/main/resources/ialon-theme/metal4.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/ialon-theme/metal4.png
--------------------------------------------------------------------------------
/core/src/main/resources/ialon-theme/metal5.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/ialon-theme/metal5.png
--------------------------------------------------------------------------------
/core/src/main/resources/ialon-theme/oven.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/ialon-theme/oven.png
--------------------------------------------------------------------------------
/core/src/main/resources/ialon-theme/paving.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/ialon-theme/paving.png
--------------------------------------------------------------------------------
/core/src/main/resources/ialon-theme/rail.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/ialon-theme/rail.png
--------------------------------------------------------------------------------
/core/src/main/resources/ialon-theme/rock.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/ialon-theme/rock.png
--------------------------------------------------------------------------------
/core/src/main/resources/ialon-theme/sand.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/ialon-theme/sand.png
--------------------------------------------------------------------------------
/core/src/main/resources/ialon-theme/sand3.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/ialon-theme/sand3.png
--------------------------------------------------------------------------------
/core/src/main/resources/ialon-theme/scale.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/ialon-theme/scale.png
--------------------------------------------------------------------------------
/core/src/main/resources/ialon-theme/slate.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/ialon-theme/slate.png
--------------------------------------------------------------------------------
/core/src/main/resources/ialon-theme/snow.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/ialon-theme/snow.png
--------------------------------------------------------------------------------
/core/src/main/resources/ialon-theme/water.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/ialon-theme/water.png
--------------------------------------------------------------------------------
/core/src/main/resources/ialon-theme/water2.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/ialon-theme/water2.png
--------------------------------------------------------------------------------
/core/src/main/resources/ialon-theme/water3.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/ialon-theme/water3.png
--------------------------------------------------------------------------------
/core/src/main/resources/ialon-theme/water3.xcf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/ialon-theme/water3.xcf
--------------------------------------------------------------------------------
/core/src/main/resources/ialon-theme/water4.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/ialon-theme/water4.png
--------------------------------------------------------------------------------
/core/src/main/resources/ialon-theme/water4.xcf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/ialon-theme/water4.xcf
--------------------------------------------------------------------------------
/core/src/main/resources/ialon-theme/water5.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/ialon-theme/water5.png
--------------------------------------------------------------------------------
/core/src/main/resources/ialon-theme/water5.xcf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/ialon-theme/water5.xcf
--------------------------------------------------------------------------------
/core/src/main/resources/ialon-theme/water6.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/ialon-theme/water6.png
--------------------------------------------------------------------------------
/core/src/main/resources/ialon-theme/window.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/ialon-theme/window.png
--------------------------------------------------------------------------------
/core/src/main/resources/Models/Wagon/wagon.blend:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/Models/Wagon/wagon.blend
--------------------------------------------------------------------------------
/core/src/main/resources/Textures/arrowright.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/Textures/arrowright.png
--------------------------------------------------------------------------------
/core/src/main/resources/ialon-theme/drawers.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/ialon-theme/drawers.png
--------------------------------------------------------------------------------
/core/src/main/resources/ialon-theme/oak_log.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/ialon-theme/oak_log.png
--------------------------------------------------------------------------------
/core/src/main/resources/ialon-theme/tile_red.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/ialon-theme/tile_red.png
--------------------------------------------------------------------------------
/core/src/main/resources/Models/Wagon/wagon.uv.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/Models/Wagon/wagon.uv.png
--------------------------------------------------------------------------------
/core/src/main/resources/Textures/arrowdown-full.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/Textures/arrowdown-full.png
--------------------------------------------------------------------------------
/core/src/main/resources/Textures/arrowjump-full.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/Textures/arrowjump-full.png
--------------------------------------------------------------------------------
/core/src/main/resources/Textures/arrowleft-full.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/Textures/arrowleft-full.png
--------------------------------------------------------------------------------
/core/src/main/resources/Textures/arrowup-full.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/Textures/arrowup-full.png
--------------------------------------------------------------------------------
/core/src/main/resources/Textures/font-default.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/Textures/font-default.png
--------------------------------------------------------------------------------
/core/src/main/resources/Textures/range-filled.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/Textures/range-filled.png
--------------------------------------------------------------------------------
/core/src/main/resources/ialon-theme/bedpillow.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/ialon-theme/bedpillow.png
--------------------------------------------------------------------------------
/core/src/main/resources/ialon-theme/birch_log.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/ialon-theme/birch_log.png
--------------------------------------------------------------------------------
/core/src/main/resources/ialon-theme/cobblestone.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/ialon-theme/cobblestone.png
--------------------------------------------------------------------------------
/core/src/main/resources/ialon-theme/color_black.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/ialon-theme/color_black.png
--------------------------------------------------------------------------------
/core/src/main/resources/ialon-theme/color_blue.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/ialon-theme/color_blue.png
--------------------------------------------------------------------------------
/core/src/main/resources/ialon-theme/color_cyan.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/ialon-theme/color_cyan.png
--------------------------------------------------------------------------------
/core/src/main/resources/ialon-theme/color_green.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/ialon-theme/color_green.png
--------------------------------------------------------------------------------
/core/src/main/resources/ialon-theme/color_red.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/ialon-theme/color_red.png
--------------------------------------------------------------------------------
/core/src/main/resources/ialon-theme/color_red2.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/ialon-theme/color_red2.png
--------------------------------------------------------------------------------
/core/src/main/resources/ialon-theme/color_rose.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/ialon-theme/color_rose.png
--------------------------------------------------------------------------------
/core/src/main/resources/ialon-theme/grass_snow.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/ialon-theme/grass_snow.png
--------------------------------------------------------------------------------
/core/src/main/resources/ialon-theme/item_grass.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/ialon-theme/item_grass.png
--------------------------------------------------------------------------------
/core/src/main/resources/ialon-theme/oak_leaves.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/ialon-theme/oak_leaves.png
--------------------------------------------------------------------------------
/core/src/main/resources/ialon-theme/oak_planks.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/ialon-theme/oak_planks.png
--------------------------------------------------------------------------------
/core/src/main/resources/ialon-theme/rail_curved.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/ialon-theme/rail_curved.png
--------------------------------------------------------------------------------
/core/src/main/resources/ialon-theme/rail_curved.xcf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/ialon-theme/rail_curved.xcf
--------------------------------------------------------------------------------
/core/src/main/resources/ialon-theme/rail_slope.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/ialon-theme/rail_slope.png
--------------------------------------------------------------------------------
/core/src/main/resources/ialon-theme/spruce_log.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/ialon-theme/spruce_log.png
--------------------------------------------------------------------------------
/core/src/main/resources/ialon-theme/test_multi.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/ialon-theme/test_multi.png
--------------------------------------------------------------------------------
/core/src/main/resources/ialon-theme/water-debug.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/ialon-theme/water-debug.png
--------------------------------------------------------------------------------
/core/src/main/resources/ialon-theme/white_light.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/ialon-theme/white_light.png
--------------------------------------------------------------------------------
/core/src/main/resources/Textures/arrowright-full.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/Textures/arrowright-full.png
--------------------------------------------------------------------------------
/core/src/main/resources/ialon-theme/birch_leaves.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/ialon-theme/birch_leaves.png
--------------------------------------------------------------------------------
/core/src/main/resources/ialon-theme/birch_planks.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/ialon-theme/birch_planks.png
--------------------------------------------------------------------------------
/core/src/main/resources/ialon-theme/color_magenta.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/ialon-theme/color_magenta.png
--------------------------------------------------------------------------------
/core/src/main/resources/ialon-theme/color_orange.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/ialon-theme/color_orange.png
--------------------------------------------------------------------------------
/core/src/main/resources/ialon-theme/color_yellow.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/ialon-theme/color_yellow.png
--------------------------------------------------------------------------------
/core/src/main/resources/ialon-theme/item_seaweed.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/ialon-theme/item_seaweed.png
--------------------------------------------------------------------------------
/core/src/main/resources/ialon-theme/palm_tree_log.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/ialon-theme/palm_tree_log.png
--------------------------------------------------------------------------------
/core/src/main/resources/ialon-theme/spruce_leaves.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/ialon-theme/spruce_leaves.png
--------------------------------------------------------------------------------
/core/src/main/resources/ialon-theme/spruce_planks.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/ialon-theme/spruce_planks.png
--------------------------------------------------------------------------------
/core/src/main/resources/ialon-theme/stone_bricks.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/ialon-theme/stone_bricks.png
--------------------------------------------------------------------------------
/core/src/main/resources/ialon-theme/stone_bricks2.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/ialon-theme/stone_bricks2.png
--------------------------------------------------------------------------------
/core/src/main/resources/ialon-theme/stone_bricks3.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/ialon-theme/stone_bricks3.png
--------------------------------------------------------------------------------
/core/src/main/resources/ialon-theme/water-normal.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/ialon-theme/water-normal.png
--------------------------------------------------------------------------------
/core/src/main/resources/Blocks/Themes/faithful/dirt.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/Blocks/Themes/faithful/dirt.png
--------------------------------------------------------------------------------
/core/src/main/resources/Blocks/Themes/faithful/grass.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/Blocks/Themes/faithful/grass.png
--------------------------------------------------------------------------------
/core/src/main/resources/Blocks/Themes/faithful/rock.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/Blocks/Themes/faithful/rock.png
--------------------------------------------------------------------------------
/core/src/main/resources/Blocks/Themes/faithful/sand.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/Blocks/Themes/faithful/sand.png
--------------------------------------------------------------------------------
/core/src/main/resources/Blocks/Themes/faithful/snow.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/Blocks/Themes/faithful/snow.png
--------------------------------------------------------------------------------
/core/src/main/resources/Models/Wagon/wagon.texture.xcf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/Models/Wagon/wagon.texture.xcf
--------------------------------------------------------------------------------
/core/src/main/resources/ialon-theme/palm_tree_leaves.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/ialon-theme/palm_tree_leaves.png
--------------------------------------------------------------------------------
/core/src/main/resources/ialon-theme/palm_tree_planks.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/ialon-theme/palm_tree_planks.png
--------------------------------------------------------------------------------
/app/src/main/res/mipmap-hdpi/ic_launcher_adaptive_fore.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/app/src/main/res/mipmap-hdpi/ic_launcher_adaptive_fore.png
--------------------------------------------------------------------------------
/app/src/main/res/mipmap-mdpi/ic_launcher_adaptive_fore.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/app/src/main/res/mipmap-mdpi/ic_launcher_adaptive_fore.png
--------------------------------------------------------------------------------
/core/src/main/resources/Blocks/Themes/default-bak/dirt.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/Blocks/Themes/default-bak/dirt.png
--------------------------------------------------------------------------------
/core/src/main/resources/Blocks/Themes/default-bak/rock.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/Blocks/Themes/default-bak/rock.png
--------------------------------------------------------------------------------
/core/src/main/resources/Blocks/Themes/default-bak/sand.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/Blocks/Themes/default-bak/sand.png
--------------------------------------------------------------------------------
/core/src/main/resources/Blocks/Themes/default-bak/snow.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/Blocks/Themes/default-bak/snow.png
--------------------------------------------------------------------------------
/core/src/main/resources/Blocks/Themes/faithful/bricks.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/Blocks/Themes/faithful/bricks.png
--------------------------------------------------------------------------------
/core/src/main/resources/Blocks/Themes/faithful/gravel.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/Blocks/Themes/faithful/gravel.png
--------------------------------------------------------------------------------
/core/src/main/resources/Blocks/Themes/faithful/oak_log.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/Blocks/Themes/faithful/oak_log.png
--------------------------------------------------------------------------------
/core/src/main/resources/ialon-theme/mossy_cobblestone.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/ialon-theme/mossy_cobblestone.png
--------------------------------------------------------------------------------
/core/src/main/resources/ialon-theme/mossy_stone_bricks.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/ialon-theme/mossy_stone_bricks.png
--------------------------------------------------------------------------------
/core/src/test/resources/scenery/water-ut1/expected.zblock:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/test/resources/scenery/water-ut1/expected.zblock
--------------------------------------------------------------------------------
/core/src/test/resources/scenery/water-ut2/expected.zblock:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/test/resources/scenery/water-ut2/expected.zblock
--------------------------------------------------------------------------------
/core/src/test/resources/scenery/water-ut3/expected.zblock:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/test/resources/scenery/water-ut3/expected.zblock
--------------------------------------------------------------------------------
/core/src/test/resources/scenery/water-ut4/expected.zblock:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/test/resources/scenery/water-ut4/expected.zblock
--------------------------------------------------------------------------------
/app/src/main/res/mipmap-xhdpi/ic_launcher_adaptive_fore.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/app/src/main/res/mipmap-xhdpi/ic_launcher_adaptive_fore.png
--------------------------------------------------------------------------------
/app/src/main/res/mipmap-xxhdpi/ic_launcher_adaptive_fore.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/app/src/main/res/mipmap-xxhdpi/ic_launcher_adaptive_fore.png
--------------------------------------------------------------------------------
/app/src/main/res/mipmap-xxxhdpi/ic_launcher_adaptive_fore.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/app/src/main/res/mipmap-xxxhdpi/ic_launcher_adaptive_fore.png
--------------------------------------------------------------------------------
/core/src/main/resources/Blocks/Themes/default-bak/bricks.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/Blocks/Themes/default-bak/bricks.png
--------------------------------------------------------------------------------
/core/src/main/resources/Blocks/Themes/default-bak/grass.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/Blocks/Themes/default-bak/grass.png
--------------------------------------------------------------------------------
/core/src/main/resources/Blocks/Themes/default-bak/gravel.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/Blocks/Themes/default-bak/gravel.png
--------------------------------------------------------------------------------
/core/src/main/resources/Blocks/Themes/default-bak/oak_log.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/Blocks/Themes/default-bak/oak_log.png
--------------------------------------------------------------------------------
/core/src/main/resources/Blocks/Themes/default-bak/water.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/Blocks/Themes/default-bak/water.png
--------------------------------------------------------------------------------
/core/src/main/resources/Blocks/Themes/default-bak/window.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/Blocks/Themes/default-bak/window.png
--------------------------------------------------------------------------------
/core/src/main/resources/Blocks/Themes/faithful/birch_log.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/Blocks/Themes/faithful/birch_log.png
--------------------------------------------------------------------------------
/core/src/main/resources/Blocks/Themes/faithful/grass_snow.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/Blocks/Themes/faithful/grass_snow.png
--------------------------------------------------------------------------------
/core/src/main/resources/Blocks/Themes/faithful/oak_planks.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/Blocks/Themes/faithful/oak_planks.png
--------------------------------------------------------------------------------
/core/src/main/resources/Blocks/Themes/faithful/spruce_log.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/Blocks/Themes/faithful/spruce_log.png
--------------------------------------------------------------------------------
/core/src/test/resources/scenery/chunkpager/chunk_0_0_0.zblock:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/test/resources/scenery/chunkpager/chunk_0_0_0.zblock
--------------------------------------------------------------------------------
/core/src/test/resources/scenery/water-ut1/chunk_0_0_0.zblock:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/test/resources/scenery/water-ut1/chunk_0_0_0.zblock
--------------------------------------------------------------------------------
/core/src/test/resources/scenery/water-ut2/chunk_0_0_0.zblock:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/test/resources/scenery/water-ut2/chunk_0_0_0.zblock
--------------------------------------------------------------------------------
/core/src/test/resources/scenery/water-ut3/chunk_0_0_0.zblock:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/test/resources/scenery/water-ut3/chunk_0_0_0.zblock
--------------------------------------------------------------------------------
/core/src/test/resources/scenery/water-ut4/chunk_0_0_0.zblock:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/test/resources/scenery/water-ut4/chunk_0_0_0.zblock
--------------------------------------------------------------------------------
/core/src/test/resources/scenery/wedge-all/chunk_0_0_0.zblock:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/test/resources/scenery/wedge-all/chunk_0_0_0.zblock
--------------------------------------------------------------------------------
/core/src/test/resources/scenery/wedge-all2/chunk_0_0_0.zblock:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/test/resources/scenery/wedge-all2/chunk_0_0_0.zblock
--------------------------------------------------------------------------------
/core/src/test/resources/scenery/wedge-all2/chunk_0_1_0.zblock:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/test/resources/scenery/wedge-all2/chunk_0_1_0.zblock
--------------------------------------------------------------------------------
/core/src/main/java/org/delaunois/ialon/EmptyNode.java:
--------------------------------------------------------------------------------
1 | package org.delaunois.ialon;
2 |
3 | import com.jme3.scene.Node;
4 |
5 | public class EmptyNode extends Node {}
6 |
--------------------------------------------------------------------------------
/core/src/main/resources/Blocks/Themes/default-bak/birch_log.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/Blocks/Themes/default-bak/birch_log.png
--------------------------------------------------------------------------------
/core/src/main/resources/Blocks/Themes/faithful/birch_planks.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/Blocks/Themes/faithful/birch_planks.png
--------------------------------------------------------------------------------
/core/src/main/resources/Blocks/Themes/faithful/cobblestone.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/Blocks/Themes/faithful/cobblestone.png
--------------------------------------------------------------------------------
/core/src/main/resources/Blocks/Themes/faithful/stone_bricks.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/Blocks/Themes/faithful/stone_bricks.png
--------------------------------------------------------------------------------
/core/src/test/resources/scenery/modelviewer/chunk_0_0_0.zblock:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/test/resources/scenery/modelviewer/chunk_0_0_0.zblock
--------------------------------------------------------------------------------
/core/src/test/resources/scenery/wedge-single/chunk_0_0_0.zblock:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/test/resources/scenery/wedge-single/chunk_0_0_0.zblock
--------------------------------------------------------------------------------
/app/src/main/res/xml/backup_rules.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
--------------------------------------------------------------------------------
/core/src/main/resources/Blocks/Themes/default-bak/birch_leaves.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/Blocks/Themes/default-bak/birch_leaves.png
--------------------------------------------------------------------------------
/core/src/main/resources/Blocks/Themes/default-bak/birch_planks.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/Blocks/Themes/default-bak/birch_planks.png
--------------------------------------------------------------------------------
/core/src/main/resources/Blocks/Themes/default-bak/cobblestone.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/Blocks/Themes/default-bak/cobblestone.png
--------------------------------------------------------------------------------
/core/src/main/resources/Blocks/Themes/default-bak/dirt-normal.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/Blocks/Themes/default-bak/dirt-normal.png
--------------------------------------------------------------------------------
/core/src/main/resources/Blocks/Themes/default-bak/grass-normal.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/Blocks/Themes/default-bak/grass-normal.png
--------------------------------------------------------------------------------
/core/src/main/resources/Blocks/Themes/default-bak/grass_snow.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/Blocks/Themes/default-bak/grass_snow.png
--------------------------------------------------------------------------------
/core/src/main/resources/Blocks/Themes/default-bak/oak_leaves.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/Blocks/Themes/default-bak/oak_leaves.png
--------------------------------------------------------------------------------
/core/src/main/resources/Blocks/Themes/default-bak/oak_planks.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/Blocks/Themes/default-bak/oak_planks.png
--------------------------------------------------------------------------------
/core/src/main/resources/Blocks/Themes/default-bak/rock-normal.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/Blocks/Themes/default-bak/rock-normal.png
--------------------------------------------------------------------------------
/core/src/main/resources/Blocks/Themes/default-bak/sand-normal.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/Blocks/Themes/default-bak/sand-normal.png
--------------------------------------------------------------------------------
/core/src/main/resources/Blocks/Themes/default-bak/snow-normal.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/Blocks/Themes/default-bak/snow-normal.png
--------------------------------------------------------------------------------
/core/src/main/resources/Blocks/Themes/default-bak/spruce_log.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/Blocks/Themes/default-bak/spruce_log.png
--------------------------------------------------------------------------------
/core/src/main/resources/Blocks/Themes/default-bak/stone_bricks.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/Blocks/Themes/default-bak/stone_bricks.png
--------------------------------------------------------------------------------
/core/src/main/resources/Blocks/Themes/default-bak/water-normal.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/Blocks/Themes/default-bak/water-normal.png
--------------------------------------------------------------------------------
/core/src/main/resources/Blocks/Themes/faithful/palm_tree_log.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/Blocks/Themes/faithful/palm_tree_log.png
--------------------------------------------------------------------------------
/core/src/main/resources/Blocks/Themes/faithful/spruce_planks.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/Blocks/Themes/faithful/spruce_planks.png
--------------------------------------------------------------------------------
/core/src/main/java/org/delaunois/ialon/fastnoise/GradientPerturb.java:
--------------------------------------------------------------------------------
1 | package org.delaunois.ialon.fastnoise;
2 |
3 | public enum GradientPerturb {
4 | Off, On, Fractal
5 | }
6 |
--------------------------------------------------------------------------------
/core/src/main/resources/Blocks/Themes/default-bak/bricks-normal.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/Blocks/Themes/default-bak/bricks-normal.png
--------------------------------------------------------------------------------
/core/src/main/resources/Blocks/Themes/default-bak/dirt-parallax.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/Blocks/Themes/default-bak/dirt-parallax.png
--------------------------------------------------------------------------------
/core/src/main/resources/Blocks/Themes/default-bak/grass-overlay.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/Blocks/Themes/default-bak/grass-overlay.png
--------------------------------------------------------------------------------
/core/src/main/resources/Blocks/Themes/default-bak/grass-parallax.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/Blocks/Themes/default-bak/grass-parallax.png
--------------------------------------------------------------------------------
/core/src/main/resources/Blocks/Themes/default-bak/gravel-normal.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/Blocks/Themes/default-bak/gravel-normal.png
--------------------------------------------------------------------------------
/core/src/main/resources/Blocks/Themes/default-bak/oak_log-normal.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/Blocks/Themes/default-bak/oak_log-normal.png
--------------------------------------------------------------------------------
/core/src/main/resources/Blocks/Themes/default-bak/palm_tree_log.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/Blocks/Themes/default-bak/palm_tree_log.png
--------------------------------------------------------------------------------
/core/src/main/resources/Blocks/Themes/default-bak/rock-parallax.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/Blocks/Themes/default-bak/rock-parallax.png
--------------------------------------------------------------------------------
/core/src/main/resources/Blocks/Themes/default-bak/sand-parallax.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/Blocks/Themes/default-bak/sand-parallax.png
--------------------------------------------------------------------------------
/core/src/main/resources/Blocks/Themes/default-bak/snow-parallax.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/Blocks/Themes/default-bak/snow-parallax.png
--------------------------------------------------------------------------------
/core/src/main/resources/Blocks/Themes/default-bak/spruce_leaves.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/Blocks/Themes/default-bak/spruce_leaves.png
--------------------------------------------------------------------------------
/core/src/main/resources/Blocks/Themes/default-bak/spruce_planks.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/Blocks/Themes/default-bak/spruce_planks.png
--------------------------------------------------------------------------------
/core/src/main/resources/Blocks/Themes/faithful/mossy_cobblestone.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/Blocks/Themes/faithful/mossy_cobblestone.png
--------------------------------------------------------------------------------
/core/src/main/resources/Blocks/Themes/faithful/palm_tree_planks.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/Blocks/Themes/faithful/palm_tree_planks.png
--------------------------------------------------------------------------------
/core/src/main/resources/Blocks/Themes/default-bak/birch_log-normal.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/Blocks/Themes/default-bak/birch_log-normal.png
--------------------------------------------------------------------------------
/core/src/main/resources/Blocks/Themes/default-bak/bricks-parallax.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/Blocks/Themes/default-bak/bricks-parallax.png
--------------------------------------------------------------------------------
/core/src/main/resources/Blocks/Themes/default-bak/grass_snow-normal.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/Blocks/Themes/default-bak/grass_snow-normal.png
--------------------------------------------------------------------------------
/core/src/main/resources/Blocks/Themes/default-bak/gravel-parallax.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/Blocks/Themes/default-bak/gravel-parallax.png
--------------------------------------------------------------------------------
/core/src/main/resources/Blocks/Themes/default-bak/mossy_cobblestone.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/Blocks/Themes/default-bak/mossy_cobblestone.png
--------------------------------------------------------------------------------
/core/src/main/resources/Blocks/Themes/default-bak/oak_log-parallax.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/Blocks/Themes/default-bak/oak_log-parallax.png
--------------------------------------------------------------------------------
/core/src/main/resources/Blocks/Themes/default-bak/oak_planks-normal.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/Blocks/Themes/default-bak/oak_planks-normal.png
--------------------------------------------------------------------------------
/core/src/main/resources/Blocks/Themes/default-bak/palm_tree_leaves.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/Blocks/Themes/default-bak/palm_tree_leaves.png
--------------------------------------------------------------------------------
/core/src/main/resources/Blocks/Themes/default-bak/palm_tree_planks.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/Blocks/Themes/default-bak/palm_tree_planks.png
--------------------------------------------------------------------------------
/core/src/main/resources/Blocks/Themes/default-bak/spruce_log-normal.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/Blocks/Themes/default-bak/spruce_log-normal.png
--------------------------------------------------------------------------------
/core/src/main/resources/Blocks/Themes/default-bak/white_cube_light.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/Blocks/Themes/default-bak/white_cube_light.png
--------------------------------------------------------------------------------
/core/src/main/resources/Blocks/Themes/faithful/mossy_stone_bricks.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/Blocks/Themes/faithful/mossy_stone_bricks.png
--------------------------------------------------------------------------------
/core/src/main/resources/Blocks/Themes/default-bak/birch_log-parallax.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/Blocks/Themes/default-bak/birch_log-parallax.png
--------------------------------------------------------------------------------
/core/src/main/resources/Blocks/Themes/default-bak/birch_planks-normal.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/Blocks/Themes/default-bak/birch_planks-normal.png
--------------------------------------------------------------------------------
/core/src/main/resources/Blocks/Themes/default-bak/cobblestone-normal.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/Blocks/Themes/default-bak/cobblestone-normal.png
--------------------------------------------------------------------------------
/core/src/main/resources/Blocks/Themes/default-bak/grass_snow-parallax.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/Blocks/Themes/default-bak/grass_snow-parallax.png
--------------------------------------------------------------------------------
/core/src/main/resources/Blocks/Themes/default-bak/mossy_stone_bricks.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/Blocks/Themes/default-bak/mossy_stone_bricks.png
--------------------------------------------------------------------------------
/core/src/main/resources/Blocks/Themes/default-bak/oak_planks-parallax.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/Blocks/Themes/default-bak/oak_planks-parallax.png
--------------------------------------------------------------------------------
/core/src/main/resources/Blocks/Themes/default-bak/spruce_log-parallax.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/Blocks/Themes/default-bak/spruce_log-parallax.png
--------------------------------------------------------------------------------
/core/src/main/resources/Blocks/Themes/default-bak/stone_bricks-normal.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/Blocks/Themes/default-bak/stone_bricks-normal.png
--------------------------------------------------------------------------------
/core/src/main/resources/Blocks/Themes/default-bak/birch_planks-parallax.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/Blocks/Themes/default-bak/birch_planks-parallax.png
--------------------------------------------------------------------------------
/core/src/main/resources/Blocks/Themes/default-bak/cobblestone-parallax.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/Blocks/Themes/default-bak/cobblestone-parallax.png
--------------------------------------------------------------------------------
/core/src/main/resources/Blocks/Themes/default-bak/palm_tree_log-normal.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/Blocks/Themes/default-bak/palm_tree_log-normal.png
--------------------------------------------------------------------------------
/core/src/main/resources/Blocks/Themes/default-bak/palm_tree_log-parallax.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/Blocks/Themes/default-bak/palm_tree_log-parallax.png
--------------------------------------------------------------------------------
/core/src/main/resources/Blocks/Themes/default-bak/spruce_planks-normal.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/Blocks/Themes/default-bak/spruce_planks-normal.png
--------------------------------------------------------------------------------
/core/src/main/resources/Blocks/Themes/default-bak/spruce_planks-parallax.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/Blocks/Themes/default-bak/spruce_planks-parallax.png
--------------------------------------------------------------------------------
/core/src/main/resources/Blocks/Themes/default-bak/stone_bricks-parallax.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/Blocks/Themes/default-bak/stone_bricks-parallax.png
--------------------------------------------------------------------------------
/core/src/main/resources/Blocks/Themes/default-bak/mossy_cobblestone-normal.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/Blocks/Themes/default-bak/mossy_cobblestone-normal.png
--------------------------------------------------------------------------------
/core/src/main/resources/Blocks/Themes/default-bak/palm_tree_planks-normal.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/Blocks/Themes/default-bak/palm_tree_planks-normal.png
--------------------------------------------------------------------------------
/core/src/main/resources/Blocks/Themes/default-bak/mossy_cobblestone-parallax.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/Blocks/Themes/default-bak/mossy_cobblestone-parallax.png
--------------------------------------------------------------------------------
/core/src/main/resources/Blocks/Themes/default-bak/mossy_stone_bricks-normal.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/Blocks/Themes/default-bak/mossy_stone_bricks-normal.png
--------------------------------------------------------------------------------
/core/src/main/resources/Blocks/Themes/default-bak/mossy_stone_bricks-parallax.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/Blocks/Themes/default-bak/mossy_stone_bricks-parallax.png
--------------------------------------------------------------------------------
/core/src/main/resources/Blocks/Themes/default-bak/palm_tree_planks-parallax.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vxel/ialon/HEAD/core/src/main/resources/Blocks/Themes/default-bak/palm_tree_planks-parallax.png
--------------------------------------------------------------------------------
/core/src/main/java/org/delaunois/ialon/PlayerListener.java:
--------------------------------------------------------------------------------
1 | package org.delaunois.ialon;
2 |
3 | import com.jme3.math.Vector3f;
4 |
5 | public interface PlayerListener {
6 |
7 | void onMove(Vector3f location);
8 |
9 | }
10 |
--------------------------------------------------------------------------------
/gradle/wrapper/gradle-wrapper.properties:
--------------------------------------------------------------------------------
1 | distributionBase=GRADLE_USER_HOME
2 | distributionPath=wrapper/dists
3 | zipStoreBase=GRADLE_USER_HOME
4 | zipStorePath=wrapper/dists
5 | distributionUrl=https\://services.gradle.org/distributions/gradle-7.4-bin.zip
6 |
--------------------------------------------------------------------------------
/app/src/main/res/values/attrs.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
--------------------------------------------------------------------------------
/app/src/main/res/mipmap-anydpi-v26/ic_launcher.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
--------------------------------------------------------------------------------
/app/src/main/res/xml/data_extraction_rules.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
--------------------------------------------------------------------------------
/core/src/main/resources/Models/Wagon/wagon.mtl:
--------------------------------------------------------------------------------
1 | # Blender 3.4.1 MTL File: 'wagon.blend'
2 | # www.blender.org
3 |
4 | newmtl wagon
5 | Ns 360.000000
6 | Ka 0.800000 0.800000 0.800000
7 | Ks 0.000000 0.000000 0.000000
8 | Ke 0.000000 0.000000 0.000000
9 | Ni 1.450000
10 | d 1.000000
11 | illum 1
12 | map_Kd wagon.png
13 |
--------------------------------------------------------------------------------
/.gitignore:
--------------------------------------------------------------------------------
1 | /build
2 | /core/build
3 | /core/src/test/resources/scenery/saved/
4 | /app/debug
5 | /app/release
6 | /app/build
7 | /desktop/build
8 | /save
9 | /local
10 | /export
11 |
12 | /*.so
13 | /core/*.so
14 | /*.jpg
15 | /*.png
16 | /*.iml
17 |
18 | /.idea
19 | /.gradle
20 | local.properties
21 | /core/src/main/resources/Models/Wagon/wagon.blend1
22 |
--------------------------------------------------------------------------------
/core/src/main/java/org/delaunois/ialon/TerrainGenerator.java:
--------------------------------------------------------------------------------
1 | package org.delaunois.ialon;
2 |
3 | import com.jme3.math.Vector3f;
4 | import com.rvandoosselaer.blocks.ChunkGenerator;
5 |
6 | public interface TerrainGenerator extends ChunkGenerator {
7 |
8 | float getWaterHeight();
9 |
10 | void setWaterHeight(float waterHeight);
11 |
12 | float getHeight(Vector3f blockLocation);
13 | }
14 |
--------------------------------------------------------------------------------
/core/src/main/java/com/rvandoosselaer/blocks/ChunkGenerator.java:
--------------------------------------------------------------------------------
1 | package com.rvandoosselaer.blocks;
2 |
3 | import com.simsilica.mathd.Vec3i;
4 |
5 | /**
6 | * The contract of a ChunkGenerator implementation.
7 | *
8 | * @author rvandoosselaer
9 | */
10 | public interface ChunkGenerator {
11 |
12 | /**
13 | * Generates the chunk for the given chunk location.
14 | *
15 | * @param location of the chunk
16 | * @return chunk
17 | */
18 | Chunk generate(Vec3i location);
19 |
20 | }
21 |
--------------------------------------------------------------------------------
/core/src/main/java/com/rvandoosselaer/blocks/ChunkManagerListener.java:
--------------------------------------------------------------------------------
1 | package com.rvandoosselaer.blocks;
2 |
3 | /**
4 | * A listener that can be registered to the {@link ChunkManager}. Use this to get notified when the mesh of a chunk is
5 | * updated or when a new chunk is available for retrieval.
6 | *
7 | * @author: rvandoosselaer
8 | */
9 | public interface ChunkManagerListener {
10 |
11 | void onChunkUpdated(Chunk chunk);
12 |
13 | void onChunkAvailable(Chunk chunk);
14 |
15 | default void onChunkFetched(Chunk chunk) {};
16 | }
17 |
--------------------------------------------------------------------------------
/core/src/main/resources/Blocks/Materials/default-block.j3m:
--------------------------------------------------------------------------------
1 | Material normal-block : Blocks/MatDefs/Ialon.j3md {
2 |
3 | MaterialParameters {
4 | Shininess: 0
5 | UseMaterialColors: true
6 | Ambient: 1.0 1.0 1.0 1.0
7 | Diffuse: 1.0 1.0 1.0 1.0
8 | VertexLighting: true
9 | DiffuseMap: Flip MagBilinear BilinearNearestMipMap ialon-theme/dummy.png
10 | UseVertexColor: true
11 | AlphaDiscardThreshold : 0
12 | }
13 |
14 | AdditionalRenderState {
15 | PolyOffset -0.2 -0.2
16 | }
17 |
18 | }
--------------------------------------------------------------------------------
/core/src/main/resources/Blocks/Themes/default-bak/window.j3m:
--------------------------------------------------------------------------------
1 | Material window : Blocks/MatDefs/Lighting.j3md {
2 |
3 | MaterialParameters {
4 | Shininess: 0
5 | UseMaterialColors: true
6 | Ambient: 1.0 1.0 1.0 1.0
7 | Diffuse: 1.0 1.0 1.0 1.0
8 | Specular: 0 0 0 1.0
9 | VertexLighting: true
10 | DiffuseMap: MagNearest MinNearestNoMipMaps Blocks/Themes/default/window.png
11 | AlphaDiscardThreshold : 0.1
12 | }
13 |
14 | AdditionalRenderState {
15 | Blend Alpha
16 | FaceCull Off
17 | }
18 |
19 | }
--------------------------------------------------------------------------------
/core/src/main/resources/Blocks/Themes/faithful/water.j3m:
--------------------------------------------------------------------------------
1 | Material water : Blocks/MatDefs/Fluid.j3md {
2 |
3 | MaterialParameters {
4 | VertexLighting: false
5 | UseMaterialColors: true
6 | Ambient: 0.223 0.536 0.653 0.75
7 | Diffuse: 0.223 0.536 0.653 0.75
8 | Specular: 0.3 0.3 0.3 1.0
9 | Shininess: 96
10 |
11 | // custom
12 | WaveSpeed : 1.5
13 | WaveHeight : 0.03
14 | WaveSize : 10
15 | TextureScrollSpeedX : 0
16 | TextureScrollSpeedY : 0
17 | }
18 |
19 | AdditionalRenderState {
20 | Blend Alpha
21 | }
22 |
23 | }
--------------------------------------------------------------------------------
/core/src/main/resources/Blocks/Themes/faithful/water_still.j3m:
--------------------------------------------------------------------------------
1 | Material water-still : Blocks/MatDefs/Fluid.j3md {
2 |
3 | MaterialParameters {
4 | VertexLighting: false
5 | UseMaterialColors: true
6 | Ambient: 0.223 0.536 0.653 0.75
7 | Diffuse: 0.223 0.536 0.653 0.75
8 | Specular: 0.3 0.3 0.3 1.0
9 | Shininess: 96
10 |
11 | // custom
12 | WaveSpeed : 0
13 | WaveHeight : 0
14 | WaveSize : 0
15 | TextureScrollSpeedX : 0
16 | TextureScrollSpeedY : 0
17 | }
18 |
19 | AdditionalRenderState {
20 | Blend Alpha
21 | }
22 |
23 | }
--------------------------------------------------------------------------------
/core/src/main/resources/Blocks/Themes/default-bak/birch_leaves.j3m:
--------------------------------------------------------------------------------
1 | Material birch_leaves : Blocks/MatDefs/Lighting.j3md {
2 |
3 | MaterialParameters {
4 | Shininess: 0
5 | UseMaterialColors: true
6 | SteepParallax: true
7 | ParallaxHeight: 0.05
8 | Ambient: 1.0 1.0 1.0 1.0
9 | Diffuse: 1.0 1.0 1.0 1.0
10 | Specular: 0 0 0 1.0
11 | VertexLighting: true
12 | DiffuseMap: MagNearest MinNearestNoMipMaps Blocks/Themes/default/birch_leaves.png
13 | AlphaDiscardThreshold : 0.1
14 | }
15 |
16 | AdditionalRenderState {
17 | Blend Alpha
18 | }
19 |
20 | }
--------------------------------------------------------------------------------
/core/src/main/resources/Blocks/Themes/default-bak/oak_leaves-bak.j3m:
--------------------------------------------------------------------------------
1 | Material oak_leaves : Blocks/MatDefs/Lighting.j3md {
2 |
3 | MaterialParameters {
4 | Shininess: 0
5 | UseMaterialColors: true
6 | SteepParallax: true
7 | ParallaxHeight: 0.05
8 | Ambient: 1.0 1.0 1.0 1.0
9 | Diffuse: 1.0 1.0 1.0 1.0
10 | Specular: 0 0 0 1.0
11 | VertexLighting: true
12 | DiffuseMap: MagNearest MinNearestNoMipMaps Blocks/Themes/default/oak_leaves.png
13 | AlphaDiscardThreshold : 0.05
14 | }
15 |
16 | AdditionalRenderState {
17 | Blend Alpha
18 | }
19 |
20 | }
--------------------------------------------------------------------------------
/core/src/main/resources/Blocks/Themes/default-bak/spruce_leaves.j3m:
--------------------------------------------------------------------------------
1 | Material spruce_leaves : Blocks/MatDefs/Lighting.j3md {
2 |
3 | MaterialParameters {
4 | Shininess: 0
5 | UseMaterialColors: true
6 | SteepParallax: true
7 | ParallaxHeight: 0.05
8 | Ambient: 1.0 1.0 1.0 1.0
9 | Diffuse: 1.0 1.0 1.0 1.0
10 | Specular: 0 0 0 1.0
11 | VertexLighting: true
12 | DiffuseMap: MagNearest MinNearestNoMipMaps Blocks/Themes/default/spruce_leaves.png
13 | AlphaDiscardThreshold : 0.1
14 | }
15 |
16 | AdditionalRenderState {
17 | Blend Alpha
18 | }
19 |
20 | }
--------------------------------------------------------------------------------
/core/src/main/resources/ialon-theme/water_still.j3m:
--------------------------------------------------------------------------------
1 | Material water-still : Blocks/MatDefs/Ialon.j3md {
2 |
3 | MaterialParameters {
4 | VertexLighting: true
5 | UseVertexColor: true
6 | UseMaterialColors: true
7 | Ambient: 1.0 1.0 1.0 1.0
8 | Diffuse: 1.0 1.0 1.0 1.0
9 | Specular: 0.3 0.3 0.3 1.0
10 | Shininess: 96
11 | DiffuseMap: Flip WrapRepeat_S WrapRepeat_T ialon-theme/water2.png
12 |
13 | // custom
14 | TextureScrollSpeedX : 0.0
15 | TextureScrollSpeedY : 0.0
16 | }
17 |
18 | AdditionalRenderState {
19 | Blend Alpha
20 | }
21 |
22 | }
--------------------------------------------------------------------------------
/core/src/main/resources/Blocks/Themes/default-bak/palm_tree_leaves.j3m:
--------------------------------------------------------------------------------
1 | Material palm_tree_leaves : Blocks/MatDefs/Lighting.j3md {
2 |
3 | MaterialParameters {
4 | Shininess: 0
5 | UseMaterialColors: true
6 | SteepParallax: true
7 | ParallaxHeight: 0.05
8 | Ambient: 1.0 1.0 1.0 1.0
9 | Diffuse: 1.0 1.0 1.0 1.0
10 | Specular: 0 0 0 1.0
11 | VertexLighting: true
12 | DiffuseMap: MagNearest MinNearestNoMipMaps Blocks/Themes/default/palm_tree_leaves.png
13 | AlphaDiscardThreshold : 0.05
14 | }
15 |
16 | AdditionalRenderState {
17 | Blend Alpha
18 | }
19 |
20 | }
--------------------------------------------------------------------------------
/core/src/main/resources/blocks.proto:
--------------------------------------------------------------------------------
1 | syntax = "proto3";
2 |
3 | option java_package = "org.delaunois.explorer.protobuf";
4 | option java_outer_classname = "BlocksProtos";
5 |
6 | message ChunkProto {
7 | // the location of the chunk, represented as an array of 3 integers. Where location[0] = x, location[1] = y, location[2] = z
8 | repeated sint32 location = 1 [packed=true];
9 | // the size of the chunk, represented as an array of 3 integers. where size[0] = x, size[1] = y, size[2] = z
10 | repeated sint32 size = 2 [packed=true];
11 | // the block array
12 | repeated string blocks = 3;
13 | // the lightmap array
14 | bytes lightmap = 4;
15 |
16 | }
--------------------------------------------------------------------------------
/core/src/main/resources/ialon-theme/water.j3m:
--------------------------------------------------------------------------------
1 | Material water-still : Blocks/MatDefs/Ialon.j3md {
2 |
3 | MaterialParameters {
4 | VertexLighting: true
5 | UseVertexColor: true
6 | UseMaterialColors: true
7 | Ambient: 1.0 1.0 1.0 1.0
8 | Diffuse: 1.0 1.0 1.0 1.0
9 | Specular: 0.3 0.3 0.3 1.0
10 | Shininess: 96
11 | DiffuseMap: Flip WrapRepeat_S WrapRepeat_T ialon-theme/water3.png
12 |
13 | // custom
14 | TextureScrollSpeedX : 0.0
15 | TextureScrollSpeedY : -0.01
16 | }
17 |
18 | AdditionalRenderState {
19 | Blend Alpha
20 | PolyOffset -0.1 -0.1
21 | }
22 |
23 | }
24 |
--------------------------------------------------------------------------------
/core/src/main/java/org/delaunois/ialon/fastnoise/LayerMask.java:
--------------------------------------------------------------------------------
1 | package org.delaunois.ialon.fastnoise;
2 |
3 | public class LayerMask {
4 |
5 | private NoiseLayer noiseLayer;
6 | private NoiseLayer withLayer;
7 |
8 | public LayerMask(NoiseLayer noiseLayer, NoiseLayer withLayer) {
9 | this.noiseLayer = noiseLayer;
10 | this.withLayer = withLayer;
11 | }
12 |
13 | public NoiseLayer getNoiseLayer() {
14 | return noiseLayer;
15 | }
16 |
17 | public NoiseLayer getWithLayer() {
18 | return withLayer;
19 | }
20 |
21 | @Override
22 | public String toString() {
23 | return noiseLayer.getName() + " -> " + withLayer.getName();
24 | }
25 |
26 | }
27 |
--------------------------------------------------------------------------------
/core/src/main/java/com/rvandoosselaer/blocks/ChunkRepository.java:
--------------------------------------------------------------------------------
1 | package com.rvandoosselaer.blocks;
2 |
3 | import com.simsilica.mathd.Vec3i;
4 |
5 | /**
6 | * The contract of a ChunkRepository implementation.
7 | *
8 | * @author rvandoosselaer
9 | */
10 | public interface ChunkRepository {
11 |
12 | /**
13 | * Loads the chunk for the given chunk location.
14 | *
15 | * @param location of the chunk
16 | * @return chunk or null if the chunk could not be loaded
17 | */
18 | Chunk load(Vec3i location);
19 |
20 | /**
21 | * Saves the chunk
22 | *
23 | * @param chunk to save
24 | * @return true when successfully saved, false otherwise
25 | */
26 | boolean save(Chunk chunk);
27 |
28 | }
29 |
--------------------------------------------------------------------------------
/core/src/main/java/com/rvandoosselaer/blocks/ChunkResolver.java:
--------------------------------------------------------------------------------
1 | package com.rvandoosselaer.blocks;
2 |
3 | import com.simsilica.mathd.Vec3i;
4 |
5 | import java.util.Optional;
6 |
7 | import lombok.NonNull;
8 |
9 | /**
10 | * A service to retrieve chunks.
11 | *
12 | * @author: rvandoosselaer
13 | */
14 | public interface ChunkResolver {
15 |
16 | /**
17 | * Return a Chunk optional.
18 | *
19 | * @param location of the chunk
20 | * @return chunk
21 | */
22 | Optional get(@NonNull Vec3i location);
23 |
24 | /**
25 | * Return the chunk, if present in cache.
26 | * @param location of the chunk
27 | * @return chunk or null
28 | */
29 | Chunk unsafeFastGet(@NonNull Vec3i location);
30 |
31 | }
32 |
--------------------------------------------------------------------------------
/core/src/main/resources/Blocks/Themes/default-bak/grass.j3m:
--------------------------------------------------------------------------------
1 | Material grass-block : Blocks/MatDefs/LightingOverlayColor.j3md {
2 |
3 | MaterialParameters {
4 | Shininess: 0
5 | UseMaterialColors: true
6 | SteepParallax: true
7 | ParallaxHeight: 0.05
8 | Ambient: 1.0 1.0 1.0 1.0
9 | Diffuse: 1.0 1.0 1.0 1.0
10 | Specular: 0 0 0 1.0
11 | VertexLighting: true
12 | DiffuseMap: Flip Blocks/Themes/default/grass.png
13 | //NormalMap: Flip Blocks/Themes/default/grass-normal.png
14 | //ParallaxMap: Flip Blocks/Themes/default/grass-parallax.png
15 | OverlayColor: 0.07603188 0.1837715 0.084361315 1.0
16 | OverlayMap: Flip Blocks/Themes/default/grass-overlay.png
17 | }
18 |
19 | }
--------------------------------------------------------------------------------
/core/src/main/java/com/rvandoosselaer/blocks/BlocksTheme.java:
--------------------------------------------------------------------------------
1 | package com.rvandoosselaer.blocks;
2 |
3 |
4 | import lombok.AllArgsConstructor;
5 | import lombok.Builder;
6 | import lombok.Getter;
7 | import lombok.NoArgsConstructor;
8 | import lombok.Setter;
9 | import lombok.ToString;
10 |
11 | /**
12 | * A Blocks theme.
13 | *
14 | * @author rvandoosselaer
15 | */
16 | @Getter
17 | @Setter
18 | @Builder
19 | @ToString
20 | @NoArgsConstructor
21 | @AllArgsConstructor
22 | public class BlocksTheme {
23 |
24 | /**
25 | * The name of the theme
26 | */
27 | private String name;
28 |
29 | /**
30 | * The path to the texture folder of the theme, starting from an AssetManager accessible folder.
31 | */
32 | private String path;
33 |
34 | }
35 |
--------------------------------------------------------------------------------
/core/src/main/resources/ialon-theme/water_still.bak:
--------------------------------------------------------------------------------
1 | Material water-still : Blocks/MatDefs/Fluid.j3md {
2 |
3 | MaterialParameters {
4 | VertexLighting: false
5 | UseMaterialColors: true
6 | Ambient: 0.145 0.421 0.548 1.0
7 | Diffuse: 0.145 0.421 0.548 1.0
8 | Specular: 0.3 0.3 0.3 1.0
9 | Shininess: 96
10 | DiffuseMap: Flip WrapRepeat_S WrapRepeat_T ialon-theme/water.png
11 | NormalMap: Flip WrapRepeat_S WrapRepeat_T ialon-theme/water-normal.png
12 |
13 | // custom
14 | WaveSpeed : 0
15 | WaveHeight : 0
16 | WaveSize : 0
17 | TextureScrollSpeedX : 0.05
18 | TextureScrollSpeedY : 0.01
19 | }
20 |
21 | AdditionalRenderState {
22 | Blend Alpha
23 | }
24 |
25 | }
--------------------------------------------------------------------------------
/core/src/main/resources/Blocks/Themes/default-bak/water.j3m:
--------------------------------------------------------------------------------
1 | Material water : Blocks/MatDefs/Fluid.j3md {
2 |
3 | MaterialParameters {
4 | VertexLighting: false
5 | UseMaterialColors: true
6 | Ambient: 0.145 0.421 0.548 1.0
7 | Diffuse: 0.145 0.421 0.548 1.0
8 | Specular: 0.3 0.3 0.3 1.0
9 | Shininess: 96
10 | DiffuseMap: Flip WrapRepeat_S WrapRepeat_T Blocks/Themes/default/water.png
11 | NormalMap: Flip WrapRepeat_S WrapRepeat_T Blocks/Themes/default/water-normal.png
12 |
13 | // custom
14 | WaveSpeed : 1.5
15 | WaveHeight : 0.03
16 | WaveSize : 10
17 | TextureScrollSpeedX : 0.05
18 | TextureScrollSpeedY : 0.01
19 | }
20 |
21 | AdditionalRenderState {
22 | Blend Alpha
23 | }
24 |
25 | }
--------------------------------------------------------------------------------
/app/proguard-rules.pro:
--------------------------------------------------------------------------------
1 | # Add project specific ProGuard rules here.
2 | # You can control the set of applied configuration files using the
3 | # proguardFiles setting in build.gradle.
4 | #
5 | # For more details, see
6 | # http://developer.android.com/guide/developing/tools/proguard.html
7 |
8 | # If your project uses WebView with JS, uncomment the following
9 | # and specify the fully qualified class name to the JavaScript interface
10 | # class:
11 | #-keepclassmembers class fqcn.of.javascript.interface.for.webview {
12 | # public *;
13 | #}
14 |
15 | # Uncomment this to preserve the line number information for
16 | # debugging stack traces.
17 | #-keepattributes SourceFile,LineNumberTable
18 |
19 | # If you keep the line number information, uncomment this to
20 | # hide the original source file name.
21 | #-renamesourcefileattribute SourceFile
--------------------------------------------------------------------------------
/core/src/main/java/org/delaunois/ialon/EmptyGenerator.java:
--------------------------------------------------------------------------------
1 | package org.delaunois.ialon;
2 |
3 | import com.jme3.math.Vector3f;
4 | import com.rvandoosselaer.blocks.Chunk;
5 | import com.simsilica.mathd.Vec3i;
6 |
7 | public class EmptyGenerator implements TerrainGenerator {
8 |
9 | @Override
10 | public Chunk generate(Vec3i location) {
11 | return Chunk.createAt(location);
12 | }
13 |
14 | public float getWaterHeight() {
15 | throw new UnsupportedOperationException("Water is not supported by " + this.getClass().getSimpleName());
16 | }
17 |
18 | public void setWaterHeight(float waterHeight) {
19 | throw new UnsupportedOperationException("Water is not supported by " + this.getClass().getSimpleName());
20 | }
21 |
22 | public float getHeight(Vector3f blockLocation) {
23 | return 0;
24 | }
25 |
26 | }
--------------------------------------------------------------------------------
/core/src/main/resources/Blocks/Themes/default-bak/water_still.j3m:
--------------------------------------------------------------------------------
1 | Material water-still : Blocks/MatDefs/Fluid.j3md {
2 |
3 | MaterialParameters {
4 | VertexLighting: false
5 | UseMaterialColors: true
6 | Ambient: 0.145 0.421 0.548 1.0
7 | Diffuse: 0.145 0.421 0.548 1.0
8 | Specular: 0.3 0.3 0.3 1.0
9 | Shininess: 96
10 | DiffuseMap: Flip WrapRepeat_S WrapRepeat_T MagNearest MinNearestNoMipMaps Blocks/Themes/default/water.png
11 | NormalMap: Flip WrapRepeat_S WrapRepeat_T MagNearest MinNearestNoMipMaps Blocks/Themes/default/water-normal.png
12 |
13 | // custom
14 | WaveSpeed : 0
15 | WaveHeight : 0
16 | WaveSize : 0
17 | TextureScrollSpeedX : 0.05
18 | TextureScrollSpeedY : 0.01
19 | }
20 |
21 | AdditionalRenderState {
22 | Blend Alpha
23 | }
24 |
25 | }
--------------------------------------------------------------------------------
/core/src/main/java/org/delaunois/ialon/WaterLevel.java:
--------------------------------------------------------------------------------
1 | package org.delaunois.ialon;
2 |
3 | public enum WaterLevel {
4 |
5 | NONE((byte)0),
6 | LEVEL1((byte)1),
7 | LEVEL2((byte)2),
8 | LEVEL3((byte)3),
9 | LEVEL4((byte)4),
10 | LEVEL5((byte)5),
11 | LEVEL6((byte)6),
12 | LEVEL7((byte)7);
13 |
14 | private final byte level;
15 |
16 | WaterLevel(byte level) {
17 | this.level = level;
18 | }
19 |
20 | public byte getLevel() {
21 | return level;
22 | }
23 |
24 | public static byte[] getAllLevels() {
25 | return new byte[] {
26 | NONE.level,
27 | LEVEL1.level,
28 | LEVEL2.level,
29 | LEVEL3.level,
30 | LEVEL4.level,
31 | LEVEL5.level,
32 | LEVEL6.level,
33 | LEVEL7.level
34 | };
35 | }
36 | }
37 |
--------------------------------------------------------------------------------
/desktop/build.gradle:
--------------------------------------------------------------------------------
1 | apply plugin: "java"
2 | sourceSets.main.java.srcDirs = ["src/main/java"]
3 |
4 | ext {
5 | lombokVersion = "1.18.20"
6 | mockitoVersion = "5.11.0"
7 | junitVersion = "5.10.2"
8 | logbackVersion = "1.2.3"
9 | }
10 |
11 | dependencies {
12 | testImplementation "org.mockito:mockito-core:${mockitoVersion}"
13 | testImplementation "org.junit.jupiter:junit-jupiter-api:${junitVersion}"
14 | testRuntimeOnly "org.junit.jupiter:junit-jupiter-engine:${junitVersion}"
15 |
16 | // logging
17 | testImplementation "ch.qos.logback:logback-core:${logbackVersion}"
18 | testImplementation "ch.qos.logback:logback-classic:${logbackVersion}"
19 | testImplementation "org.slf4j:jul-to-slf4j:1.7.36"
20 | }
21 |
22 | test {
23 | useJUnitPlatform()
24 | }
25 |
26 | java {
27 | sourceCompatibility = JavaVersion.VERSION_1_8
28 | targetCompatibility = JavaVersion.VERSION_1_8
29 | }
--------------------------------------------------------------------------------
/core/src/main/java/com/rvandoosselaer/blocks/serialize/BlockDTO.java:
--------------------------------------------------------------------------------
1 | package com.rvandoosselaer.blocks.serialize;
2 |
3 | import com.rvandoosselaer.blocks.BlockIds;
4 | import com.rvandoosselaer.blocks.ShapeIds;
5 | import lombok.AllArgsConstructor;
6 | import lombok.Getter;
7 | import lombok.NoArgsConstructor;
8 | import lombok.Setter;
9 |
10 | /**
11 | * A POJO for deserializing a block from file.
12 | *
13 | * @author: rvandoosselaer
14 | */
15 | @Getter
16 | @Setter
17 | @NoArgsConstructor
18 | @AllArgsConstructor
19 | public class BlockDTO {
20 |
21 | private String name;
22 | private String type;
23 | private String shape = ShapeIds.CUBE;
24 | private boolean solid = true;
25 | private boolean transparent = false;
26 | private boolean multiTexture = false;
27 |
28 | public String getName() {
29 | if (name == null) {
30 | return BlockIds.getName(type, shape);
31 | }
32 | return name;
33 | }
34 |
35 | }
36 |
--------------------------------------------------------------------------------
/app/src/main/res/values/themes.xml:
--------------------------------------------------------------------------------
1 |
2 |
7 |
8 |
18 |
--------------------------------------------------------------------------------
/app/src/main/res/values-v31/themes.xml:
--------------------------------------------------------------------------------
1 |
2 |
6 |
7 |
18 |
--------------------------------------------------------------------------------
/core/src/main/java/com/rvandoosselaer/blocks/ChunkManagerState.java:
--------------------------------------------------------------------------------
1 | package com.rvandoosselaer.blocks;
2 |
3 | import com.jme3.app.Application;
4 | import com.jme3.app.state.BaseAppState;
5 | import lombok.Getter;
6 | import lombok.RequiredArgsConstructor;
7 |
8 | /**
9 | * An application state to handle the lifecycle of a ChunkManager.
10 | *
11 | * @author: rvandoosselaer
12 | */
13 | @Getter
14 | @RequiredArgsConstructor
15 | public class ChunkManagerState extends BaseAppState {
16 |
17 | private final ChunkManager chunkManager;
18 |
19 | @Override
20 | protected void initialize(Application app) {
21 | chunkManager.initialize();
22 | }
23 |
24 | @Override
25 | protected void cleanup(Application app) {
26 | chunkManager.cleanup();
27 | }
28 |
29 | @Override
30 | public void update(float tpf) {
31 | chunkManager.update();
32 | }
33 |
34 | @Override
35 | protected void onEnable() {
36 | }
37 |
38 | @Override
39 | protected void onDisable() {
40 | }
41 |
42 | }
43 |
--------------------------------------------------------------------------------
/core/src/main/java/org/delaunois/ialon/state/ChunkManagerState.java:
--------------------------------------------------------------------------------
1 | package org.delaunois.ialon.state;
2 |
3 | import com.jme3.app.Application;
4 | import com.jme3.app.state.BaseAppState;
5 |
6 | import org.delaunois.ialon.ChunkManager;
7 |
8 | import lombok.Getter;
9 | import lombok.RequiredArgsConstructor;
10 |
11 | /**
12 | * An application state to handle the lifecycle of a ChunkManager.
13 | *
14 | * @author rvandoosselaer
15 | */
16 | @Getter
17 | @RequiredArgsConstructor
18 | public class ChunkManagerState extends BaseAppState {
19 |
20 | private final ChunkManager chunkManager;
21 |
22 | @Override
23 | protected void initialize(Application app) {
24 | chunkManager.initialize();
25 | }
26 |
27 | @Override
28 | protected void cleanup(Application app) {
29 | chunkManager.cleanup();
30 | }
31 |
32 | @Override
33 | protected void onEnable() {
34 | // Nothing to do
35 | }
36 |
37 | @Override
38 | protected void onDisable() {
39 | // Nothing to do
40 | }
41 |
42 | }
43 |
--------------------------------------------------------------------------------
/.github/workflows/gradle.yml:
--------------------------------------------------------------------------------
1 | # This workflow uses actions that are not certified by GitHub.
2 | # They are provided by a third-party and are governed by
3 | # separate terms of service, privacy policy, and support
4 | # documentation.
5 | # This workflow will build a Java project with Gradle and cache/restore any dependencies to improve the workflow execution time
6 | # For more information see: https://docs.github.com/en/actions/automating-builds-and-tests/building-and-testing-java-with-gradle
7 |
8 | name: Build Ialon
9 |
10 | on:
11 | push:
12 | branches: [ "main" ]
13 | pull_request:
14 | branches: [ "main" ]
15 |
16 | permissions:
17 | contents: read
18 |
19 | jobs:
20 | build:
21 |
22 | runs-on: ubuntu-latest
23 |
24 | steps:
25 | - uses: actions/checkout@v3
26 | - name: Set up JDK
27 | uses: actions/setup-java@v3
28 | with:
29 | java-version: '17'
30 | distribution: 'temurin'
31 | - name: Build with Gradle
32 | uses: gradle/gradle-build-action@67421db6bd0bf253fb4bd25b31ebb98943c375e1
33 | with:
34 | arguments: build
35 |
--------------------------------------------------------------------------------
/app/src/main/res/values-v27/themes.xml:
--------------------------------------------------------------------------------
1 |
2 |
8 |
9 |
20 |
--------------------------------------------------------------------------------
/core/src/main/java/com/rvandoosselaer/blocks/ChunkMeshGenerator.java:
--------------------------------------------------------------------------------
1 | package com.rvandoosselaer.blocks;
2 |
3 | import com.jme3.scene.Mesh;
4 | import com.jme3.scene.Node;
5 |
6 | /**
7 | * The contract for a chunk mesh implementation.
8 | *
9 | * @author rvandoosselaer
10 | */
11 | public interface ChunkMeshGenerator {
12 |
13 | /**
14 | * Create the node for the chunk.
15 | *
16 | * @param chunk to create the node for
17 | * @return the node holding all chunk geometries
18 | */
19 | Node createNode(Chunk chunk);
20 |
21 | /**
22 | * Create the collision mesh for the chunk.
23 | *
24 | * @param chunk to create the collision mesh for
25 | * @return the collision mesh of the chunk
26 | */
27 | Mesh createCollisionMesh(Chunk chunk);
28 |
29 | /**
30 | * Create the node and the collision mesh for the chunk. The node and collision mesh should be set on the chunk.
31 | * This is a combination of the {@link #createNode(Chunk)} and {@link #createCollisionMesh(Chunk)}
32 | * methods.
33 | *
34 | * @param chunk
35 | */
36 | void createAndSetNodeAndCollisionMesh(Chunk chunk);
37 |
38 | }
39 |
--------------------------------------------------------------------------------
/gradle.properties:
--------------------------------------------------------------------------------
1 | # Project-wide Gradle settings.
2 | # IDE (e.g. Android Studio) users:
3 | # Gradle settings configured through the IDE *will override*
4 | # any settings specified in this file.
5 | # For more details on how to configure your build environment visit
6 | # http://www.gradle.org/docs/current/userguide/build_environment.html
7 | # Specifies the JVM arguments used for the daemon process.
8 | # The setting is particularly useful for tweaking memory settings.
9 | org.gradle.jvmargs=-Xmx2048m -Dfile.encoding=UTF-8
10 | org.gradle.warning.mode=summary
11 | # When configured, Gradle will run in incubating parallel mode.
12 | # This option should only be used with decoupled projects. More details, visit
13 | # http://www.gradle.org/docs/current/userguide/multi_project_builds.html#sec:decoupled_projects
14 | # org.gradle.parallel=true
15 | # AndroidX package structure to make it clearer which packages are bundled with the
16 | # Android operating system, and which are packaged with your app"s APK
17 | # https://developer.android.com/topic/libraries/support-library/androidx-rn
18 | android.useAndroidX=true
19 | # Automatically convert third-party libraries to use AndroidX
20 | android.enableJetifier=true
21 |
--------------------------------------------------------------------------------
/core/src/main/resources/Blocks/Shaders/BlendFunctions.glsllib:
--------------------------------------------------------------------------------
1 | vec4 blend_overlay(in vec4 firstColor, in vec4 secondColor) {
2 | return vec4(
3 | firstColor.r < 0.5 ? (2.0 * firstColor.r * secondColor.r) : (1.0 - 2.0 * (1.0 - firstColor.r) * (1.0 - secondColor.r)),
4 | firstColor.g < 0.5 ? (2.0 * firstColor.g * secondColor.g) : (1.0 - 2.0 * (1.0 - firstColor.g) * (1.0 - secondColor.g)),
5 | firstColor.b < 0.5 ? (2.0 * firstColor.b * secondColor.b) : (1.0 - 2.0 * (1.0 - firstColor.b) * (1.0 - secondColor.b)),
6 | firstColor.a < 0.5 ? (2.0 * firstColor.a * secondColor.a) : (1.0 - 2.0 * (1.0 - firstColor.a) * (1.0 - secondColor.a))
7 | );
8 | }
9 |
10 | vec4 blend_multiply(in vec4 firstColor, in vec4 secondColor) {
11 | return firstColor * secondColor;
12 | }
13 |
14 | vec4 blend_screen(in vec4 firstColor, in vec4 secondColor) {
15 | return vec4(
16 | 1.0 - (1.0 - firstColor.r) * (1.0 - secondColor.r),
17 | 1.0 - (1.0 - firstColor.g) * (1.0 - secondColor.g),
18 | 1.0 - (1.0 - firstColor.b) * (1.0 - secondColor.b),
19 | 1.0 - (1.0 - firstColor.a) * (1.0 - secondColor.a)
20 | );
21 | }
22 |
23 | vec4 blend_layer(in vec4 firstColor, in vec4 secondColor) {
24 | return firstColor * firstColor.a + secondColor * (1.0 - firstColor.a);
25 | }
--------------------------------------------------------------------------------
/app/src/main/AndroidManifest.xml:
--------------------------------------------------------------------------------
1 |
2 |
4 |
5 |
17 |
23 |
24 |
25 |
26 |
27 |
28 |
29 |
30 |
31 |
--------------------------------------------------------------------------------
/core/src/main/java/org/delaunois/ialon/control/CamFollowSpatialControl.java:
--------------------------------------------------------------------------------
1 | package org.delaunois.ialon.control;
2 |
3 | import com.jme3.math.Vector3f;
4 | import com.jme3.renderer.Camera;
5 | import com.jme3.renderer.RenderManager;
6 | import com.jme3.renderer.ViewPort;
7 | import com.jme3.scene.control.AbstractControl;
8 |
9 | import lombok.Setter;
10 | import lombok.extern.slf4j.Slf4j;
11 |
12 | /**
13 | * Makes the camera follow the translation of a spatial, with an optional local translation.
14 | */
15 | @Slf4j
16 | public class CamFollowSpatialControl extends AbstractControl {
17 |
18 | private final Camera camera;
19 | private final Vector3f tmp = new Vector3f();
20 |
21 | @Setter
22 | private Vector3f localTranslation;
23 |
24 | public CamFollowSpatialControl(Camera camera) {
25 | this.camera = camera;
26 | }
27 |
28 | @Override
29 | protected void controlUpdate(float tpf) {
30 | if (localTranslation != null) {
31 | tmp.set(spatial.getWorldTranslation()).addLocal(localTranslation);
32 | camera.setLocation(tmp);
33 | } else {
34 | camera.setLocation(spatial.getWorldTranslation());
35 | }
36 | }
37 |
38 | @Override
39 | protected void controlRender(RenderManager rm, ViewPort vp) {
40 | // Nothing to do
41 | }
42 |
43 | }
44 |
--------------------------------------------------------------------------------
/core/src/main/java/org/delaunois/ialon/state/ChunkPagerState.java:
--------------------------------------------------------------------------------
1 | package org.delaunois.ialon.state;
2 |
3 | import com.jme3.app.Application;
4 | import com.jme3.app.state.BaseAppState;
5 | import com.jme3.math.Vector3f;
6 |
7 | import org.delaunois.ialon.ChunkPager;
8 |
9 |
10 | public class ChunkPagerState extends BaseAppState {
11 |
12 | private final ChunkPager chunkPager;
13 |
14 | public ChunkPagerState(ChunkPager chunkPager) {
15 | this.chunkPager = chunkPager;
16 | }
17 |
18 | public ChunkPager getChunkPager() {
19 | return chunkPager;
20 | }
21 |
22 | @Override
23 | protected void initialize(Application app) {
24 | chunkPager.initialize();
25 | }
26 |
27 | @Override
28 | protected void cleanup(Application app) {
29 | chunkPager.cleanup();
30 | }
31 |
32 | @Override
33 | protected void onEnable() {
34 | // Nothing to do
35 | }
36 |
37 | @Override
38 | protected void onDisable() {
39 | // Nothing to do
40 | }
41 |
42 | @Override
43 | public void update(float tpf) {
44 | chunkPager.update();
45 | }
46 |
47 | public void setLocation(Vector3f location) {
48 | chunkPager.setLocation(location);
49 | }
50 |
51 | public Vector3f getLocation() {
52 | return chunkPager.getLocation();
53 | }
54 |
55 | }
56 |
--------------------------------------------------------------------------------
/core/src/main/resources/Blocks/Shaders/Unshaded.vert:
--------------------------------------------------------------------------------
1 | #import "Common/ShaderLib/GLSLCompat.glsllib"
2 | #import "Common/ShaderLib/Skinning.glsllib"
3 | #import "Common/ShaderLib/Instancing.glsllib"
4 | #import "Common/ShaderLib/MorphAnim.glsllib"
5 |
6 | attribute vec3 inPosition;
7 |
8 | #if defined(HAS_COLORMAP) || (defined(HAS_LIGHTMAP) && !defined(SEPARATE_TEXCOORD))
9 | #define NEED_TEXCOORD1
10 | #endif
11 |
12 | attribute vec2 inTexCoord;
13 | attribute vec2 inTexCoord2;
14 | attribute vec4 inColor;
15 |
16 | varying vec2 texCoord1;
17 | varying vec2 texCoord2;
18 |
19 | varying vec4 vertColor;
20 | #ifdef HAS_POINTSIZE
21 | uniform float m_PointSize;
22 | #endif
23 |
24 | void main(){
25 | #ifdef NEED_TEXCOORD1
26 | texCoord1 = inTexCoord;
27 | #endif
28 |
29 | #ifdef SEPARATE_TEXCOORD
30 | texCoord2 = inTexCoord2;
31 | #endif
32 |
33 | #ifdef HAS_VERTEXCOLOR
34 | vertColor = inColor;
35 | #endif
36 |
37 | #ifdef HAS_POINTSIZE
38 | gl_PointSize = m_PointSize;
39 | #endif
40 |
41 | vec4 modelSpacePos = vec4(inPosition, 1.0);
42 |
43 | #ifdef NUM_MORPH_TARGETS
44 | Morph_Compute(modelSpacePos);
45 | #endif
46 |
47 | #ifdef NUM_BONES
48 | Skinning_Compute(modelSpacePos);
49 | #endif
50 |
51 | gl_Position = TransformWorldViewProjection(modelSpacePos);
52 | }
--------------------------------------------------------------------------------
/.github/workflows/sonar.yml:
--------------------------------------------------------------------------------
1 | name: SonarCloud Analysis Ialon
2 |
3 | on:
4 | push:
5 | branches: [ "main" ]
6 | pull_request:
7 | branches: [ "main" ]
8 |
9 | permissions:
10 | contents: read
11 |
12 | jobs:
13 | build:
14 | runs-on: ubuntu-latest
15 | steps:
16 | - uses: actions/checkout@v3
17 | with:
18 | fetch-depth: 0 # Shallow clones should be disabled for a better relevancy of analysis
19 |
20 | - name: Set up JDK
21 | uses: actions/setup-java@v3
22 | with:
23 | java-version: '17'
24 | distribution: 'temurin'
25 |
26 | - name: Cache SonarCloud packages
27 | uses: actions/cache@v3
28 | with:
29 | path: ~/.sonar/cache
30 | key: ${{ runner.os }}-sonar
31 | restore-keys: ${{ runner.os }}-sonar
32 |
33 | - name: Cache Gradle packages
34 | uses: actions/cache@v3
35 | with:
36 | path: ~/.gradle/caches
37 | key: ${{ runner.os }}-gradle-${{ hashFiles('**/*.gradle') }}
38 | restore-keys: ${{ runner.os }}-gradle
39 |
40 | - name: Build and analyze
41 | env:
42 | GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} # Needed to get PR information, if any
43 | SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}
44 | run: ./gradlew build jacocoTestReport sonarqube --info
45 |
46 |
--------------------------------------------------------------------------------
/core/src/main/java/org/delaunois/ialon/fastnoise/Main.java:
--------------------------------------------------------------------------------
1 | package org.delaunois.ialon.fastnoise;
2 |
3 | import com.jme3.app.SimpleApplication;
4 | import com.jme3.material.Material;
5 | import com.jme3.scene.Geometry;
6 | import com.jme3.scene.shape.Quad;
7 | import com.jme3.system.AppSettings;
8 | import com.jme3.texture.Texture2D;
9 |
10 | public class Main extends SimpleApplication {
11 |
12 | public static void main(String... args) {
13 |
14 | Main main = new Main();
15 |
16 | AppSettings appSettings = new AppSettings(true);
17 | appSettings.setResolution(1280, 720);
18 |
19 | main.setSettings(appSettings);
20 | main.start();
21 |
22 |
23 | }
24 |
25 | @Override
26 | public void simpleInitApp() {
27 |
28 | NoiseLayer noiseLayer = new NoiseLayer();
29 | noiseLayer.setSeed(213);
30 | noiseLayer.setNoiseType(FastNoise.NoiseType.PerlinFractal);
31 |
32 | Texture2D texture2D = noiseLayer.generateTexture(720);
33 |
34 | Material unshaded = new Material(assetManager, "Common/MatDefs/Misc/Unshaded.j3md");
35 | unshaded.setTexture("ColorMap", texture2D);
36 |
37 | Geometry geometry = new Geometry("Noise Geometry", new Quad(cam.getHeight(), cam.getHeight()));
38 | geometry.setMaterial(unshaded);
39 |
40 | guiNode.attachChild(geometry);
41 |
42 | }
43 |
44 | }
45 |
--------------------------------------------------------------------------------
/core/src/main/java/com/rvandoosselaer/blocks/FlatTerrainGenerator.java:
--------------------------------------------------------------------------------
1 | package com.rvandoosselaer.blocks;
2 |
3 | import com.simsilica.mathd.Vec3i;
4 | import lombok.RequiredArgsConstructor;
5 |
6 | /**
7 | * A {@link ChunkGenerator} implementation that creates a flat looking terrain at a given y value.
8 | *
9 | * @author rvandoosselaer
10 | */
11 | @RequiredArgsConstructor
12 | public class FlatTerrainGenerator implements ChunkGenerator {
13 |
14 | /**
15 | * the y value (inclusive) of the highest blocks
16 | */
17 | private int y = 0;
18 | private final Block block;
19 |
20 | public FlatTerrainGenerator(int y, Block block) {
21 | if (y < 0 || y >= BlocksConfig.getInstance().getChunkSize().y) {
22 | throw new IllegalArgumentException("Invalid parameters specified! [y=" + y + "]");
23 | }
24 | this.y = y;
25 | this.block = block;
26 | }
27 |
28 | @Override
29 | public Chunk generate(Vec3i location) {
30 | Chunk chunk = Chunk.createAt(location);
31 |
32 | Vec3i chunkSize = BlocksConfig.getInstance().getChunkSize();
33 | for (int x = 0; x < chunkSize.x; x++) {
34 | for (int i = 0; i <= y; i++) {
35 | for (int z = 0; z < chunkSize.z; z++) {
36 | chunk.addBlock(x, i, z, block);
37 | }
38 | }
39 | }
40 |
41 | return chunk;
42 | }
43 |
44 | }
45 |
--------------------------------------------------------------------------------
/core/src/main/java/com/rvandoosselaer/blocks/DirectIntBuffer.java:
--------------------------------------------------------------------------------
1 | package com.rvandoosselaer.blocks;
2 |
3 | import com.jme3.util.BufferUtils;
4 |
5 | import java.nio.IntBuffer;
6 |
7 | public class DirectIntBuffer {
8 |
9 | private static final int INITIAL_CAPACITY = 1000;
10 | private IntBuffer buff;
11 | private int size = 0;
12 |
13 | public DirectIntBuffer() {
14 | buff = BufferUtils.createIntBuffer(INITIAL_CAPACITY);
15 | }
16 |
17 | public DirectIntBuffer(int capacity) {
18 | buff = BufferUtils.createIntBuffer(capacity);
19 | }
20 |
21 | public void add(int i) {
22 | if (buff.position() + 1 > buff.capacity()) {
23 | increaseCapacity();
24 | }
25 | buff.put(i);
26 | size++;
27 | }
28 |
29 | public IntBuffer getBuffer() {
30 | IntBuffer newbuffer = BufferUtils.createIntBuffer(buff.position());
31 | buff.flip();
32 | newbuffer.put(buff);
33 | newbuffer.flip();
34 | return newbuffer;
35 | }
36 |
37 | public IntBuffer getInternalBuffer() {
38 | return buff;
39 | }
40 |
41 | public int size() {
42 | return size;
43 | }
44 |
45 | public boolean isEmpty() {
46 | return size == 0;
47 | }
48 |
49 | public void clear() {
50 | buff.clear();
51 | }
52 |
53 | private void increaseCapacity() {
54 | IntBuffer newbuffer = BufferUtils.createIntBuffer(buff.capacity() * 2);
55 | buff.clear();
56 | newbuffer.put(buff);
57 | buff = newbuffer;
58 | }
59 |
60 | }
61 |
--------------------------------------------------------------------------------
/core/src/main/resources/Blocks/Shaders/Unshaded.frag:
--------------------------------------------------------------------------------
1 | #import "Common/ShaderLib/GLSLCompat.glsllib"
2 |
3 | #if defined(HAS_GLOWMAP) || defined(HAS_COLORMAP) || (defined(HAS_LIGHTMAP) && !defined(SEPARATE_TEXCOORD))
4 | #define NEED_TEXCOORD1
5 | #endif
6 |
7 | #if defined(DISCARD_ALPHA)
8 | uniform float m_AlphaDiscardThreshold;
9 | #endif
10 |
11 | uniform vec4 m_Color;
12 | uniform sampler2D m_ColorMap;
13 | uniform sampler2D m_LightMap;
14 |
15 | #ifdef DESATURATION
16 | uniform float m_DesaturationValue;
17 | #endif
18 |
19 | varying vec2 texCoord1;
20 | varying vec2 texCoord2;
21 |
22 | varying vec4 vertColor;
23 |
24 | void main(){
25 | vec4 color = vec4(1.0);
26 |
27 | #ifdef HAS_COLORMAP
28 | color *= texture2D(m_ColorMap, texCoord1);
29 | #endif
30 |
31 | #ifdef HAS_VERTEXCOLOR
32 | color *= vertColor;
33 | #endif
34 |
35 | #ifdef HAS_COLOR
36 | color *= m_Color;
37 | #endif
38 |
39 | #ifdef HAS_LIGHTMAP
40 | #ifdef SEPARATE_TEXCOORD
41 | color.rgb *= texture2D(m_LightMap, texCoord2).rgb;
42 | #else
43 | color.rgb *= texture2D(m_LightMap, texCoord1).rgb;
44 | #endif
45 | #endif
46 |
47 | #if defined(DISCARD_ALPHA)
48 | if(color.a < m_AlphaDiscardThreshold){
49 | discard;
50 | }
51 | #endif
52 |
53 | #ifdef DESATURATION
54 | vec3 gray = vec3(dot(vec3(0.2126,0.7152,0.0722), color.rgb));
55 | color.rgb = vec3(mix(color.rgb, gray, m_DesaturationValue));
56 | #endif
57 |
58 | gl_FragColor = color;
59 | }
60 |
--------------------------------------------------------------------------------
/app/build.gradle:
--------------------------------------------------------------------------------
1 | plugins {
2 | id 'com.android.application'
3 | }
4 |
5 | android {
6 | namespace "org.delaunois.ialon"
7 | compileSdkVersion 32
8 | buildToolsVersion "33.0.0"
9 |
10 | defaultConfig {
11 | applicationId "org.delaunois.ialon"
12 | minSdkVersion 26
13 | targetSdkVersion 32
14 | versionCode 1
15 | versionName "1.0"
16 | multiDexEnabled true
17 |
18 | testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
19 | }
20 |
21 | buildTypes {
22 | debug {
23 | minifyEnabled false
24 | }
25 | release {
26 | minifyEnabled false
27 | proguardFiles getDefaultProguardFile('proguard-android-optimize.txt'), 'proguard-rules.pro'
28 | }
29 | }
30 |
31 | compileOptions {
32 | sourceCompatibility JavaVersion.VERSION_1_8
33 | targetCompatibility JavaVersion.VERSION_1_8
34 | }
35 |
36 | packagingOptions {
37 | jniLibs {
38 | useLegacyPackaging true
39 | }
40 | merge "com/simsilica/lemur/style/base/glass-styles.groovy"
41 | exclude 'META-INF/DEPENDENCIES'
42 | exclude 'META-INF/INDEX.LIST'
43 | }
44 | }
45 |
46 | dependencies {
47 | implementation 'androidx.core:core-splashscreen:1.0.0'
48 | implementation('androidx.appcompat:appcompat:1.5.1') {
49 | exclude group: 'com.google.guava', module: 'listenablefuture'
50 | }
51 | implementation('com.google.android.material:material:1.7.0') {
52 | exclude group: 'com.google.guava', module: 'listenablefuture'
53 | }
54 | }
--------------------------------------------------------------------------------
/core/src/main/java/com/rvandoosselaer/blocks/TypeIds.java:
--------------------------------------------------------------------------------
1 | package com.rvandoosselaer.blocks;
2 |
3 | /**
4 | * Contains all the keys of the types that are registered in the {@link TypeRegistry}. Use these keys to retrieve the
5 | * types from the {@link TypeRegistry#get(String)}.
6 | *
7 | * @author: rvandoosselaer
8 | */
9 | public interface TypeIds {
10 |
11 | String BIRCH_LOG = "birch_log";
12 | String BIRCH_PLANKS = "birch_planks";
13 | String BRICKS = "bricks";
14 | String COBBLESTONE = "cobblestone";
15 | String MOSSY_COBBLESTONE = "mossy_cobblestone";
16 | String DIRT = "dirt";
17 | String GRAVEL = "gravel";
18 | String GRASS = "grass";
19 | String GRASS_SNOW = "grass_snow";
20 | String PALM_TREE_LOG = "palm_tree_log";
21 | String PALM_TREE_PLANKS = "palm_tree_planks";
22 | String ROCK = "rock";
23 | String OAK_LOG = "oak_log";
24 | String OAK_PLANKS = "oak_planks";
25 | String SAND = "sand";
26 | String SNOW = "snow";
27 | String SPRUCE_LOG = "spruce_log";
28 | String SPRUCE_PLANKS = "spruce_planks";
29 | String STONE_BRICKS = "stone_bricks";
30 | String MOSSY_STONE_BRICKS = "mossy_stone_bricks";
31 | String WATER = "water";
32 | String BIRCH_LEAVES = "birch_leaves";
33 | String PALM_TREE_LEAVES = "palm_tree_leaves";
34 | String OAK_LEAVES = "oak_leaves";
35 | String SPRUCE_LEAVES = "spruce_leaves";
36 | String ITEM_GRASS = "item_grass";
37 | String WHITE_LIGHT = "white_light";
38 | String WINDOW = "window";
39 | String SCALE = "scale";
40 | String RAIL = "rail";
41 | String RAIL_CURVED = "rail_curved";
42 | String RAIL_SLOPE = "rail_slope";
43 | }
44 |
--------------------------------------------------------------------------------
/core/src/main/java/com/rvandoosselaer/blocks/ChunkCache.java:
--------------------------------------------------------------------------------
1 | package com.rvandoosselaer.blocks;
2 |
3 | import com.simsilica.mathd.Vec3i;
4 |
5 | import java.util.Map;
6 | import java.util.Optional;
7 | import java.util.concurrent.ConcurrentHashMap;
8 |
9 | import lombok.NonNull;
10 | import lombok.extern.slf4j.Slf4j;
11 |
12 | /**
13 | * An in memory threadsafe chunk cache implementation.
14 | *
15 | * @author: rvandoosselaer
16 | */
17 | @Slf4j
18 | public class ChunkCache implements ChunkResolver {
19 |
20 | private final Map cache = new ConcurrentHashMap<>();
21 |
22 | public ChunkCache() {
23 | this(0);
24 | }
25 |
26 | public ChunkCache(int cacheSize) {
27 | }
28 |
29 | @Override
30 | public Optional get(@NonNull Vec3i location) {
31 | return Optional.ofNullable(cache.get(location));
32 | }
33 |
34 | @Override
35 | public Chunk unsafeFastGet(@NonNull Vec3i location) {
36 | return cache.get(location);
37 | }
38 |
39 | public void evict(@NonNull Vec3i location) {
40 | if (log.isDebugEnabled()) {
41 | log.debug("Cache evicted {}", location);
42 | }
43 | cache.remove(location);
44 | }
45 |
46 | public void evictAll() {
47 | cache.clear();
48 | }
49 |
50 | public void put(@NonNull Chunk chunk) {
51 | if (log.isDebugEnabled()) {
52 | log.debug("Cache added {}", chunk.getLocation());
53 | }
54 | cache.put(chunk.getLocation(), chunk);
55 | }
56 |
57 | public long getSize() {
58 | return cache.size();
59 | }
60 |
61 | public void maintain() {
62 |
63 | }
64 |
65 | }
66 |
--------------------------------------------------------------------------------
/core/src/main/java/com/rvandoosselaer/blocks/DirectVector2fBuffer.java:
--------------------------------------------------------------------------------
1 | package com.rvandoosselaer.blocks;
2 |
3 | import com.jme3.math.Vector2f;
4 | import com.jme3.util.BufferUtils;
5 |
6 | import java.nio.FloatBuffer;
7 |
8 | public class DirectVector2fBuffer {
9 |
10 | private static final int INITIAL_CAPACITY = 1000;
11 | private FloatBuffer buff;
12 | private int size = 0;
13 |
14 | public DirectVector2fBuffer() {
15 | buff = BufferUtils.createFloatBuffer(INITIAL_CAPACITY * 2);
16 | }
17 |
18 | public DirectVector2fBuffer(int capacity) {
19 | buff = BufferUtils.createFloatBuffer(capacity * 2);
20 | }
21 |
22 | public void add(Vector2f v) {
23 | if (buff.position() + 2 > buff.capacity()) {
24 | increaseCapacity();
25 | }
26 | buff.put(v.x).put(v.y);
27 | size++;
28 | }
29 |
30 | public FloatBuffer getBuffer() {
31 | FloatBuffer newbuffer = BufferUtils.createFloatBuffer(buff.position());
32 | buff.flip();
33 | newbuffer.put(buff);
34 | newbuffer.flip();
35 | return newbuffer;
36 | }
37 |
38 | public FloatBuffer getInternalBuffer() {
39 | return buff;
40 | }
41 |
42 | public int size() {
43 | return size;
44 | }
45 |
46 | public boolean isEmpty() {
47 | return size == 0;
48 | }
49 |
50 | public void clear() {
51 | buff.clear();
52 | }
53 |
54 | private void increaseCapacity() {
55 | FloatBuffer newbuffer = BufferUtils.createFloatBuffer(buff.capacity() * 2);
56 | buff.clear();
57 | newbuffer.put(buff);
58 | buff = newbuffer;
59 | }
60 |
61 | }
62 |
--------------------------------------------------------------------------------
/core/src/main/java/com/rvandoosselaer/blocks/DirectVector4fBuffer.java:
--------------------------------------------------------------------------------
1 | package com.rvandoosselaer.blocks;
2 |
3 | import com.jme3.math.Vector4f;
4 | import com.jme3.util.BufferUtils;
5 |
6 | import java.nio.FloatBuffer;
7 |
8 | public class DirectVector4fBuffer {
9 |
10 | private static final int INITIAL_CAPACITY = 1000;
11 | private FloatBuffer buff;
12 | private int size = 0;
13 |
14 | public DirectVector4fBuffer() {
15 | buff = BufferUtils.createFloatBuffer(INITIAL_CAPACITY * 4);
16 | }
17 |
18 | public DirectVector4fBuffer(int capacity) {
19 | buff = BufferUtils.createFloatBuffer(capacity * 4);
20 | }
21 |
22 | public void add(Vector4f v) {
23 | if (buff.position() + 4 > buff.capacity()) {
24 | increaseCapacity();
25 | }
26 | buff.put(v.x).put(v.y).put(v.z).put(v.w);
27 | size++;
28 | }
29 |
30 | public FloatBuffer getBuffer() {
31 | FloatBuffer newbuffer = BufferUtils.createFloatBuffer(buff.position());
32 | buff.flip();
33 | newbuffer.put(buff);
34 | newbuffer.flip();
35 | return newbuffer;
36 | }
37 |
38 | public FloatBuffer getInternalBuffer() {
39 | return buff;
40 | }
41 |
42 | public int size() {
43 | return size;
44 | }
45 |
46 | public boolean isEmpty() {
47 | return size == 0;
48 | }
49 |
50 | public void clear() {
51 | buff.clear();
52 | }
53 |
54 | private void increaseCapacity() {
55 | FloatBuffer newbuffer = BufferUtils.createFloatBuffer(buff.capacity() * 2);
56 | buff.clear();
57 | newbuffer.put(buff);
58 | buff = newbuffer;
59 | }
60 |
61 | }
62 |
--------------------------------------------------------------------------------
/core/src/main/java/com/rvandoosselaer/blocks/serialize/BlockDefinition.java:
--------------------------------------------------------------------------------
1 | package com.rvandoosselaer.blocks.serialize;
2 |
3 | import java.util.Arrays;
4 | import java.util.HashSet;
5 | import java.util.Set;
6 |
7 | import lombok.AllArgsConstructor;
8 | import lombok.Getter;
9 | import lombok.NoArgsConstructor;
10 | import lombok.Setter;
11 |
12 | /**
13 | * A POJO describing the parameters for creating a collection of blocks.
14 | *
15 | * @author: rvandoosselaer
16 | */
17 | @Getter
18 | @Setter
19 | @NoArgsConstructor
20 | @AllArgsConstructor
21 | public class BlockDefinition {
22 |
23 | private String type;
24 | private final Set shapes = new HashSet<>();
25 | private final Set waterLevels = new HashSet<>();
26 | private boolean solid = true;
27 | private boolean transparent = false;
28 | private boolean multiTexture = false;
29 |
30 | public BlockDefinition addShape(String shape) {
31 | if (shape != null) {
32 | shapes.add(shape);
33 | }
34 | return this;
35 | }
36 |
37 | public BlockDefinition addShapes(String... shapes) {
38 | if (shapes != null) {
39 | Arrays.stream(shapes).forEach(this::addShape);
40 | }
41 | return this;
42 | }
43 |
44 | public BlockDefinition addWaterLevel(Byte waterLevel) {
45 | if (waterLevel != 0) {
46 | waterLevels.add(waterLevel);
47 | }
48 | return this;
49 | }
50 |
51 | public BlockDefinition addWaterLevels(Byte... waterLevels) {
52 | if (waterLevels != null) {
53 | Arrays.stream(waterLevels).forEach(this::addWaterLevel);
54 | }
55 | return this;
56 | }
57 | }
58 |
--------------------------------------------------------------------------------
/core/src/main/java/com/rvandoosselaer/blocks/DirectVector3fBuffer.java:
--------------------------------------------------------------------------------
1 | package com.rvandoosselaer.blocks;
2 |
3 | import com.jme3.math.Vector3f;
4 | import com.jme3.util.BufferUtils;
5 |
6 | import java.nio.FloatBuffer;
7 |
8 | import lombok.extern.slf4j.Slf4j;
9 |
10 | @Slf4j
11 | public class DirectVector3fBuffer {
12 |
13 | private static final int INITIAL_CAPACITY = 1000;
14 | private int size = 0;
15 | private FloatBuffer buff;
16 |
17 | public DirectVector3fBuffer() {
18 | buff = BufferUtils.createFloatBuffer(INITIAL_CAPACITY * 3);
19 | }
20 |
21 | public DirectVector3fBuffer(int capacity) {
22 | buff = BufferUtils.createFloatBuffer(capacity * 3);
23 | }
24 |
25 | public void add(Vector3f v) {
26 | if (buff.position() + 3 > buff.capacity()) {
27 | increaseCapacity();
28 | }
29 | buff.put(v.x).put(v.y).put(v.z);
30 | size++;
31 | }
32 |
33 | public FloatBuffer getBuffer() {
34 | FloatBuffer newbuffer = BufferUtils.createFloatBuffer(buff.position());
35 | buff.flip();
36 | newbuffer.put(buff);
37 | newbuffer.flip();
38 | return newbuffer;
39 | }
40 |
41 | public FloatBuffer getInternalBuffer() {
42 | return buff;
43 | }
44 |
45 | public int size() {
46 | return size;
47 | }
48 |
49 | public boolean isEmpty() {
50 | return size == 0;
51 | }
52 |
53 | public void clear() {
54 | buff.clear();
55 | }
56 |
57 | private void increaseCapacity() {
58 | FloatBuffer newbuffer = BufferUtils.createFloatBuffer(buff.capacity() * 2);
59 | buff.clear();
60 | newbuffer.put(buff);
61 | buff = newbuffer;
62 | }
63 |
64 | }
65 |
--------------------------------------------------------------------------------
/core/src/main/resources/Textures/arrowdown.svg:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
53 |
--------------------------------------------------------------------------------
/core/src/main/resources/Textures/arrowleft.svg:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
53 |
--------------------------------------------------------------------------------
/core/build.gradle:
--------------------------------------------------------------------------------
1 | apply plugin: "java"
2 | apply plugin: "jacoco"
3 | sourceSets.main.java.srcDirs = ["src/main/java"]
4 |
5 | ext {
6 | minieVersion = "7.4.0"
7 | lombokVersion = "1.18.20"
8 | simMathVersion = '1.5.0'
9 | sio2Version = '1.7.0'
10 | blocksVersion = "1.6.4"
11 | protobufVersion = "3.11.4"
12 | jacksonVersion = "2.12.3"
13 | lemurprotoVersion = "1.13.0"
14 | logbackVersion = "1.2.3"
15 | mockitoVersion = "5.11.0"
16 | junitVersion = "5.10.2"
17 | }
18 |
19 | dependencies {
20 |
21 | // physics
22 | implementation "com.github.stephengold:Minie:${minieVersion}"
23 |
24 | // utilities
25 | //noinspection AnnotationProcessorOnCompilePath
26 | compileOnly "org.projectlombok:lombok:${lombokVersion}"
27 | annotationProcessor "org.projectlombok:lombok:${lombokVersion}"
28 | implementation "com.google.protobuf:protobuf-java:${protobufVersion}"
29 | implementation "com.fasterxml.jackson.dataformat:jackson-dataformat-yaml:${jacksonVersion}"
30 | implementation "com.simsilica:sim-math:${simMathVersion}"
31 | implementation "com.simsilica:lemur-proto:${lemurprotoVersion}"
32 |
33 | // logging
34 | implementation "ch.qos.logback:logback-core:${logbackVersion}"
35 | implementation "ch.qos.logback:logback-classic:${logbackVersion}"
36 | implementation "org.slf4j:jul-to-slf4j:1.7.36"
37 |
38 | testImplementation "org.mockito:mockito-core:${mockitoVersion}"
39 | testImplementation "org.junit.jupiter:junit-jupiter-api:${junitVersion}"
40 | testRuntimeOnly "org.junit.jupiter:junit-jupiter-engine:${junitVersion}"
41 | }
42 |
43 | test {
44 | useJUnitPlatform()
45 | }
46 |
47 | jacocoTestReport {
48 | reports {
49 | xml.enabled true
50 | }
51 | }
52 |
53 | java {
54 | sourceCompatibility = JavaVersion.VERSION_1_8
55 | targetCompatibility = JavaVersion.VERSION_1_8
56 | }
--------------------------------------------------------------------------------
/core/src/main/resources/Textures/arrowright.svg:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
53 |
--------------------------------------------------------------------------------
/core/src/main/resources/Textures/arrowdown-full.svg:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
53 |
--------------------------------------------------------------------------------
/core/src/main/resources/Textures/arrowup.svg:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
54 |
--------------------------------------------------------------------------------
/core/src/test/resources/logback-test.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | true
6 |
7 |
8 |
9 |
10 | %d{HH:mm:ss.SSS} [%-20thread] %-5level %logger{36} - %msg%n
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
22 |
23 |
24 |
25 |
26 |
27 |
28 |
29 |
30 |
31 |
32 |
33 |
34 |
35 |
36 |
--------------------------------------------------------------------------------
/core/src/main/resources/Textures/arrowleft-full.svg:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
53 |
--------------------------------------------------------------------------------
/core/src/main/resources/Textures/arrowright-full.svg:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
53 |
--------------------------------------------------------------------------------
/core/src/main/java/org/delaunois/ialon/InputActionManager.java:
--------------------------------------------------------------------------------
1 | package org.delaunois.ialon;
2 |
3 | import com.jme3.input.InputManager;
4 | import com.jme3.input.controls.ActionListener;
5 |
6 | import java.util.ArrayList;
7 | import java.util.HashMap;
8 |
9 | import lombok.Getter;
10 | import lombok.Setter;
11 |
12 | public class InputActionManager {
13 |
14 | private final HashMap mappings = new HashMap<>();
15 |
16 | @Getter
17 | @Setter
18 | private InputManager inputManager;
19 |
20 | private static class Mapping {
21 | private final String name;
22 | private final ArrayList listeners = new ArrayList<>();
23 |
24 | public Mapping(String name) {
25 | this.name = name;
26 | }
27 | }
28 |
29 | public void triggerAction(String actionName, boolean isPressed) {
30 | Mapping mapping = mappings.get(actionName);
31 | for (ActionListener listener : mapping.listeners) {
32 | listener.onAction(mapping.name, isPressed, 0);
33 | }
34 | }
35 |
36 | public void addListener(ActionListener listener, String... mappingNames) {
37 | if (inputManager != null) {
38 | inputManager.addListener(listener, mappingNames);
39 | }
40 |
41 | for (String mappingName : mappingNames) {
42 | Mapping mapping = mappings.computeIfAbsent(mappingName, k -> new Mapping(mappingName));
43 | if (!mapping.listeners.contains(listener)) {
44 | mapping.listeners.add(listener);
45 | }
46 | }
47 | }
48 |
49 | public void removeListener(ActionListener listener) {
50 | if (inputManager != null) {
51 | inputManager.removeListener(listener);
52 | }
53 |
54 | for (Mapping mapping : mappings.values()) {
55 | mapping.listeners.remove(listener);
56 | }
57 | }
58 |
59 | }
60 |
--------------------------------------------------------------------------------
/core/src/main/resources/Textures/arrowup-full.svg:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
54 |
--------------------------------------------------------------------------------
/core/src/main/resources/Textures/flight.svg:
--------------------------------------------------------------------------------
1 |
2 |
17 |
19 |
20 |
40 |
44 |
45 |
--------------------------------------------------------------------------------
/core/src/test/java/org/delaunois/ialon/WaterTest.java:
--------------------------------------------------------------------------------
1 | package org.delaunois.ialon;
2 |
3 | import com.rvandoosselaer.blocks.BlockIds;
4 |
5 | import org.delaunois.ialon.support.BaseSceneryTest;
6 | import org.junit.jupiter.api.Test;
7 |
8 | class WaterTest extends BaseSceneryTest {
9 |
10 | @Test
11 | void testAddSource() {
12 | init("water-ut1");
13 |
14 | // Add a water source. Horizontal flow. No block.
15 | addBlock(BlockIds.WATER_SOURCE, 8, 9, 8);
16 | waitLiquidSimulationEnd();
17 | verify("expected.zblock", "the water should flow");
18 |
19 | // Remove the water source
20 | removeSourceBlock(8, 9, 8);
21 | waitLiquidSimulationEnd();
22 | verify("chunk_0_0_0.zblock", "the water should have disappeared");
23 | }
24 |
25 | @Test
26 | void testAddSource2() {
27 | init("water-ut2");
28 |
29 | // Add a water source. Horizontal flow. Blocks stopping flow.
30 | addBlock(BlockIds.WATER_SOURCE, 11, 9, 7);
31 | addBlock(BlockIds.WATER_SOURCE, 6, 9, 7);
32 | waitLiquidSimulationEnd();
33 | verify("expected.zblock", "the water should flow");
34 |
35 | // Remove the water source
36 | removeSourceBlock(11, 9, 7);
37 | removeSourceBlock(6, 9, 7);
38 | waitLiquidSimulationEnd();
39 | verify("chunk_0_0_0.zblock", "the water should have disappeared");
40 | }
41 |
42 | @Test
43 | void testAddSource3() {
44 | init("water-ut3");
45 |
46 | // Water cascade (vertical flow)
47 | addBlock(BlockIds.WATER_SOURCE, 8, 13, 7);
48 | waitLiquidSimulationEnd();
49 | verify("expected.zblock", "the water should flow");
50 |
51 | // Remove the water source
52 | removeSourceBlock(8, 13, 7);
53 | waitLiquidSimulationEnd();
54 | verify("chunk_0_0_0.zblock", "the water should have disappeared");
55 | }
56 |
57 | }
58 |
--------------------------------------------------------------------------------
/core/src/main/resources/logback.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | true
6 |
7 |
8 |
9 |
10 | %d{HH:mm:ss.SSS} [%-15thread] %-5level %logger{36} - %msg%n
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
22 |
23 |
24 |
25 |
26 |
27 |
28 |
29 |
30 |
31 |
32 |
33 |
34 |
35 |
36 |
37 |
--------------------------------------------------------------------------------
/core/src/main/java/org/delaunois/ialon/control/SpatialFollowCamControl.java:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (C) 2022 Cédric de Launois
3 | *
4 | * This program is free software: you can redistribute it and/or modify
5 | * it under the terms of the GNU General Public License as published by
6 | * the Free Software Foundation, either version 3 of the License, or
7 | * (at your option) any later version.
8 | *
9 | * This program is distributed in the hope that it will be useful,
10 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 | * GNU General Public License for more details.
13 | *
14 | * You should have received a copy of the GNU General Public License
15 | * along with this program. If not, see .
16 | */
17 |
18 | package org.delaunois.ialon.control;
19 |
20 | import com.jme3.math.Vector3f;
21 | import com.jme3.renderer.Camera;
22 | import com.jme3.renderer.RenderManager;
23 | import com.jme3.renderer.ViewPort;
24 | import com.jme3.scene.control.AbstractControl;
25 |
26 | import lombok.Setter;
27 | import lombok.extern.slf4j.Slf4j;
28 |
29 | /**
30 | * Makes a spatial follow the translation of the camera, with an optional local translation.
31 | */
32 | @Slf4j
33 | public class SpatialFollowCamControl extends AbstractControl {
34 |
35 | private final Camera cam;
36 | private final Vector3f tmp = new Vector3f();
37 |
38 | @Setter
39 | private Vector3f translation;
40 |
41 | public SpatialFollowCamControl(Camera cam) {
42 | this.cam = cam;
43 | }
44 |
45 | @Override
46 | protected void controlUpdate(float tpf) {
47 | if (translation != null) {
48 | tmp.set(cam.getLocation()).addLocal(translation);
49 | spatial.setLocalTranslation(tmp);
50 | } else {
51 | spatial.setLocalTranslation(cam.getLocation());
52 | }
53 | }
54 |
55 | @Override
56 | protected void controlRender(RenderManager rm, ViewPort vp) {
57 | // Nothing to do
58 | }
59 | }
60 |
--------------------------------------------------------------------------------
/core/src/test/java/org/delaunois/ialon/BlockSelectionStateTest.java:
--------------------------------------------------------------------------------
1 | package org.delaunois.ialon;
2 |
3 | import com.jme3.app.SimpleApplication;
4 | import com.jme3.asset.DesktopAssetManager;
5 | import com.jme3.math.Vector3f;
6 | import com.jme3.system.JmeContext;
7 | import com.jme3.util.BufferAllocatorFactory;
8 | import com.jme3.util.PrimitiveAllocator;
9 |
10 | import org.delaunois.ialon.state.PlayerState;
11 | import org.delaunois.ialon.support.SceneryTestBuilderApplication;
12 | import org.junit.jupiter.api.Test;
13 |
14 | import static org.junit.jupiter.api.Assertions.assertTrue;
15 |
16 | class BlockSelectionStateTest {
17 |
18 | protected static final int TIMEOUT_IN_MILLIS = 10000;
19 |
20 | static {
21 | System.setProperty(BufferAllocatorFactory.PROPERTY_BUFFER_ALLOCATOR_IMPLEMENTATION, PrimitiveAllocator.class.getName());
22 | }
23 |
24 | @Test
25 | void testShowMenu() {
26 | IalonConfig config = new IalonConfig();
27 | config.setDevMode(true);
28 | config.setDebugChunks(true);
29 | config.setPlayerLocation(new Vector3f(0, 100, 0));
30 | config.setPlayerStartFly(true);
31 |
32 | IalonInitializer.configureBlocksFramework(new DesktopAssetManager(true), config);
33 | config.setTerrainGenerator(new NoiseTerrainGenerator(2, 50));
34 |
35 | SimpleApplication app = new SceneryTestBuilderApplication(config);
36 | app.setShowSettings(false);
37 | app.start(JmeContext.Type.Headless);
38 |
39 | PlayerState playerState = null;
40 | while (playerState == null) {
41 | playerState = app.getStateManager().getState(PlayerState.class);
42 | }
43 |
44 | long start = System.currentTimeMillis();
45 | long duration = 0;
46 | while (!app.getStateManager().getState(PlayerState.class).isEnabled() && duration < TIMEOUT_IN_MILLIS) {
47 | duration = System.currentTimeMillis() - start;
48 | }
49 |
50 | assertTrue(duration < TIMEOUT_IN_MILLIS, "The player should have started before timeout");
51 | }
52 |
53 | }
54 |
--------------------------------------------------------------------------------
/core/src/main/java/org/delaunois/ialon/state/PhysicsChunkPagerState.java:
--------------------------------------------------------------------------------
1 | package org.delaunois.ialon.state;
2 |
3 | import com.jme3.app.Application;
4 | import com.jme3.app.state.BaseAppState;
5 | import com.jme3.bullet.PhysicsSpace;
6 | import com.jme3.math.Vector3f;
7 |
8 | import org.delaunois.ialon.ChunkManager;
9 | import org.delaunois.ialon.PhysicsChunkPager;
10 |
11 | import lombok.Getter;
12 |
13 | /**
14 | * An AppState implementation that manages the lifecycle of a {@link PhysicsChunkPager}.
15 | *
16 | * @author rvandoosselaer
17 | */
18 | public class PhysicsChunkPagerState extends BaseAppState {
19 |
20 | @Getter
21 | private final PhysicsChunkPager physicsChunkPager;
22 |
23 | public PhysicsChunkPagerState(PhysicsChunkPager physicsChunkPager) {
24 | this.physicsChunkPager = physicsChunkPager;
25 | }
26 |
27 | public PhysicsChunkPagerState(PhysicsSpace physicsSpace, ChunkManager chunkManager) {
28 | this(new PhysicsChunkPager(physicsSpace, chunkManager));
29 | }
30 |
31 | @Override
32 | protected void initialize(Application app) {
33 | physicsChunkPager.initialize();
34 | }
35 |
36 | @Override
37 | protected void cleanup(Application app) {
38 | physicsChunkPager.cleanup();
39 | }
40 |
41 | @Override
42 | protected void onEnable() {
43 | // Nothing to do
44 | }
45 |
46 | @Override
47 | protected void onDisable() {
48 | // Nothing to do
49 | }
50 |
51 | @Override
52 | public void update(float tpf) {
53 | physicsChunkPager.update();
54 | }
55 |
56 | public void setPhysicsSpace(PhysicsSpace physicsSpace) {
57 | physicsChunkPager.setPhysicsSpace(physicsSpace);
58 | }
59 |
60 | public PhysicsSpace getPhysicsSpace() {
61 | return physicsChunkPager.getPhysicsSpace();
62 | }
63 |
64 | public void setLocation(Vector3f location) {
65 | physicsChunkPager.setLocation(location);
66 | }
67 |
68 | public Vector3f getLocation() {
69 | return physicsChunkPager.getLocation();
70 | }
71 | }
72 |
--------------------------------------------------------------------------------
/core/src/main/java/com/rvandoosselaer/blocks/Direction.java:
--------------------------------------------------------------------------------
1 | package com.rvandoosselaer.blocks;
2 |
3 | import com.jme3.math.Vector3f;
4 | import com.simsilica.mathd.Vec3i;
5 |
6 | import lombok.Getter;
7 | import lombok.NonNull;
8 | import lombok.ToString;
9 | import lombok.extern.slf4j.Slf4j;
10 |
11 | /**
12 | * An enum holding direction information in a right-handed coordinate system, just as OpenGL.
13 | *
14 | * @author rvandoosselaer
15 | */
16 | @Slf4j
17 | @Getter
18 | @ToString
19 | public enum Direction {
20 | UP(0, 1, 0),
21 | DOWN(0, -1, 0),
22 | WEST(-1, 0, 0),
23 | EAST(1, 0, 0),
24 | SOUTH(0, 0, 1),
25 | NORTH(0, 0, -1);
26 |
27 | private final Vec3i vector;
28 |
29 | Direction(int x, int y, int z) {
30 | this.vector = new Vec3i(x, y, z);
31 | }
32 |
33 | public static Direction fromVector(@NonNull Vector3f vector3f) {
34 | int x = Math.round(vector3f.x);
35 | int y = Math.round(vector3f.y);
36 | int z = Math.round(vector3f.z);
37 | if (x != 0) {
38 | if (x == 1) {
39 | return EAST;
40 | } else if (x == -1) {
41 | return WEST;
42 | }
43 | } else if (y != 0) {
44 | if (y == 1) {
45 | return UP;
46 | } else if (y == -1) {
47 | return DOWN;
48 | }
49 | } else if (z != 0) {
50 | if (z == 1) {
51 | return SOUTH;
52 | } else if (z == -1) {
53 | return NORTH;
54 | }
55 | }
56 | log.error("Unable to find direction from vector {}. Returning UP.", vector3f);
57 | return UP;
58 | }
59 |
60 | public Direction opposite() {
61 | if (vector.x != 0) {
62 | return vector.x > 0 ? WEST : EAST;
63 | } else if (vector.y != 0) {
64 | return vector.y > 0 ? DOWN : UP;
65 | } else if (vector.z != 0) {
66 | return vector.z > 0 ? NORTH : SOUTH;
67 | }
68 | throw new IllegalStateException("Invalid direction vector: " + vector);
69 | }
70 |
71 | }
72 |
--------------------------------------------------------------------------------
/desktop/src/main/java/org/delaunois/ialon/DesktopLauncher.java:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (C) 2022 Cédric de Launois
3 | *
4 | * This program is free software: you can redistribute it and/or modify
5 | * it under the terms of the GNU General Public License as published by
6 | * the Free Software Foundation, either version 3 of the License, or
7 | * (at your option) any later version.
8 | *
9 | * This program is distributed in the hope that it will be useful,
10 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 | * GNU General Public License for more details.
13 | *
14 | * You should have received a copy of the GNU General Public License
15 | * along with this program. If not, see .
16 | */
17 |
18 | package org.delaunois.ialon;
19 |
20 | import com.jme3.system.AppSettings;
21 | import com.jme3.util.BufferAllocatorFactory;
22 | import com.jme3.util.PrimitiveAllocator;
23 |
24 | import org.delaunois.ialon.serialize.IalonConfigRepository;
25 |
26 |
27 | public class DesktopLauncher {
28 |
29 | static {
30 | System.setProperty(BufferAllocatorFactory.PROPERTY_BUFFER_ALLOCATOR_IMPLEMENTATION, PrimitiveAllocator.class.getName());
31 | }
32 |
33 | public static void main(String[] args) {
34 | IalonConfig config = new IalonConfig();
35 | IalonConfigRepository.loadConfig(config);
36 | config.setGridRadiusMin(3);
37 | config.setGridRadiusMax(20);
38 | config.setDevMode(true);
39 | Ialon app = new Ialon(config);
40 |
41 | AppSettings settings = new AppSettings(false);
42 | settings.setFrameRate(IalonConfig.FPS_LIMIT);
43 | settings.setGammaCorrection(false);
44 | settings.setResolution(config.getScreenWidth(), config.getScreenHeight());
45 | settings.setRenderer(AppSettings.LWJGL_OPENGL32);
46 | settings.setUseInput(true);
47 | settings.setAudioRenderer(null);
48 | settings.setVSync(false);
49 |
50 | app.setSettings(settings);
51 | app.setShowSettings(false);
52 | app.start();
53 | }
54 | }
--------------------------------------------------------------------------------
/core/src/main/resources/Blocks/Shaders/Ialon.frag:
--------------------------------------------------------------------------------
1 | #import "Common/ShaderLib/GLSLCompat.glsllib"
2 | #import "Blocks/Shaders/BlendFunctions.glsllib"
3 |
4 | const float ATLAS_SIZE = 2048.0;
5 | const float TEX_SIZE = 128.0;
6 | const float NUM_TEXTURES = ATLAS_SIZE / TEX_SIZE;
7 | const float UV_TEX_SIZE = 1.0 / NUM_TEXTURES;
8 | const float UV_PADDING = 0.25 * UV_TEX_SIZE;
9 | const float PADDED_UV_TEX_SIZE = UV_TEX_SIZE - 2.0 * UV_PADDING;
10 |
11 | #ifdef DIFFUSEMAP
12 | uniform sampler2D m_DiffuseMap;
13 | #endif
14 |
15 | uniform float m_AlphaDiscardThreshold;
16 | uniform float m_GammaCorrection;
17 |
18 | flat in vec2 wrapCoordMin;
19 | flat in vec2 wrapCoordMax;
20 |
21 | in vec2 texCoord;
22 | in vec3 AmbientSum;
23 | in vec4 DiffuseSum;
24 | in float fogFactor;
25 |
26 | void main() {
27 |
28 | vec4 diffuseColor;
29 | vec2 uv = texCoord;
30 |
31 | if (wrapCoordMin.y > 0.0) {
32 | if (uv.y >= wrapCoordMax.y) {
33 | uv.y = uv.y - PADDED_UV_TEX_SIZE;
34 | } else if (uv.y <= wrapCoordMin.y) {
35 | uv.y = uv.y + PADDED_UV_TEX_SIZE;
36 | }
37 |
38 | if (uv.x >= wrapCoordMax.x) {
39 | uv.x = uv.x - PADDED_UV_TEX_SIZE;
40 | } else if (uv.x <= wrapCoordMin.x) {
41 | uv.x = uv.x + PADDED_UV_TEX_SIZE;
42 | }
43 | diffuseColor = textureGrad(m_DiffuseMap, uv, dFdx(texCoord), dFdy(texCoord));
44 |
45 | } else {
46 | #ifdef DIFFUSEMAP
47 | diffuseColor = texture2D(m_DiffuseMap, uv);
48 | #else
49 | diffuseColor = vec4(1.0);
50 | #endif
51 | }
52 |
53 | float alpha = DiffuseSum.a * diffuseColor.a;
54 |
55 | if (alpha < m_AlphaDiscardThreshold){
56 | discard;
57 | }
58 |
59 | gl_FragColor.rgb = (AmbientSum.rgb + DiffuseSum.rgb) * diffuseColor.rgb;
60 | if (m_GammaCorrection > 0.0) {
61 | gl_FragColor.r = pow(gl_FragColor.r, m_GammaCorrection);
62 | gl_FragColor.g = pow(gl_FragColor.g, m_GammaCorrection);
63 | gl_FragColor.b = pow(gl_FragColor.b, m_GammaCorrection);
64 | }
65 | gl_FragColor.a = alpha;
66 | //gl_FragColor = mix(vec4(0.39, 0.67, 1.0, 1.0), gl_FragColor, fogFactor);
67 | }
68 |
--------------------------------------------------------------------------------
/core/src/main/java/org/delaunois/ialon/RotationHelper.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (C) 2022 Cédric de Launois
3 | *
4 | * This program is free software: you can redistribute it and/or modify
5 | * it under the terms of the GNU General Public License as published by
6 | * the Free Software Foundation, either version 3 of the License, or
7 | * (at your option) any later version.
8 | *
9 | * This program is distributed in the hope that it will be useful,
10 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 | * GNU General Public License for more details.
13 | *
14 | * You should have received a copy of the GNU General Public License
15 | * along with this program. If not, see .
16 | */
17 |
18 | package org.delaunois.ialon;
19 |
20 | import com.jme3.math.Matrix3f;
21 | import com.jme3.math.Quaternion;
22 | import com.jme3.math.Vector3f;
23 | import com.jme3.renderer.Camera;
24 | import com.jme3.scene.Spatial;
25 |
26 | public class RotationHelper {
27 |
28 | private final Matrix3f mat = new Matrix3f();
29 | private final Quaternion q = new Quaternion();
30 | private final Vector3f up = new Vector3f();
31 | private final Vector3f left = new Vector3f();
32 | private final Vector3f dir = new Vector3f();
33 |
34 | public void rotate(Camera cam, float value, Vector3f axis, Vector3f camUp, Vector3f camLeft, Vector3f camDir) {
35 | rotate(value, axis, camUp, camLeft, camDir, q);
36 | cam.setAxes(q);
37 | }
38 |
39 | public void rotate(Spatial spatial, float value, Vector3f axis, Vector3f up, Vector3f left, Vector3f dir) {
40 | rotate(value, axis, up, left, dir, q);
41 | spatial.getLocalRotation().set(q);
42 | }
43 |
44 | public void rotate(float value, Vector3f axis, Vector3f camUp, Vector3f camLeft, Vector3f camDir, Quaternion store) {
45 | mat.fromAngleNormalAxis(value, axis);
46 |
47 | mat.mult(camUp, up);
48 | mat.mult(camLeft, left);
49 | mat.mult(camDir, dir);
50 |
51 | if (up.getY() < 0) {
52 | return;
53 | }
54 |
55 | store.fromAxes(left, up, dir);
56 | store.normalizeLocal();
57 | }
58 |
59 | }
60 |
--------------------------------------------------------------------------------
/core/src/main/java/org/delaunois/ialon/FlatTerrainGenerator.java:
--------------------------------------------------------------------------------
1 | package org.delaunois.ialon;
2 |
3 | import com.jme3.math.Vector3f;
4 | import com.rvandoosselaer.blocks.Block;
5 | import com.rvandoosselaer.blocks.BlockIds;
6 | import com.rvandoosselaer.blocks.BlocksConfig;
7 | import com.rvandoosselaer.blocks.Chunk;
8 | import com.simsilica.mathd.Vec3i;
9 |
10 | public class FlatTerrainGenerator implements TerrainGenerator {
11 |
12 | /**
13 | * the y value (inclusive) of the highest blocks
14 | */
15 | private final int ground;
16 | private final Block block;
17 |
18 | public FlatTerrainGenerator() {
19 | this(0, null);
20 | }
21 |
22 | public FlatTerrainGenerator(int y, Block block) {
23 | if (y < 0 || y >= BlocksConfig.getInstance().getChunkSize().y) {
24 | throw new IllegalArgumentException("Invalid parameters specified! [y=" + y + "]");
25 | }
26 | if (block == null) {
27 | block = BlocksConfig.getInstance().getBlockRegistry().get(BlockIds.GRASS);
28 | }
29 |
30 | this.ground = y;
31 | this.block = block;
32 | }
33 |
34 | @Override
35 | public Chunk generate(Vec3i location) {
36 | Chunk chunk = Chunk.createAt(location);
37 |
38 | Vec3i chunkSize = BlocksConfig.getInstance().getChunkSize();
39 | for (int x = 0; x < chunkSize.x; x++) {
40 | for (int y = 0; y < chunkSize.y; y++) {
41 | for (int z = 0; z < chunkSize.z; z++) {
42 | if (y <= ground) {
43 | chunk.addBlock(x, y, z, block);
44 | chunk.setSunlight(x, y, z, 0);
45 | } else {
46 | chunk.setSunlight(x, y, z, 15);
47 | }
48 | }
49 | }
50 | }
51 |
52 | chunk.setDirty(false);
53 | return chunk;
54 | }
55 |
56 | public float getWaterHeight() {
57 | return ground - 1f;
58 | }
59 |
60 | public void setWaterHeight(float waterHeight) {
61 | throw new UnsupportedOperationException("Water is not supported by " + this.getClass().getSimpleName());
62 | }
63 |
64 | public float getHeight(Vector3f blockLocation) {
65 | return ground;
66 | }
67 |
68 | }
--------------------------------------------------------------------------------
/core/src/main/java/org/delaunois/ialon/state/WireframeState.java:
--------------------------------------------------------------------------------
1 | package org.delaunois.ialon.state;
2 |
3 | import com.jme3.app.Application;
4 | import com.jme3.app.state.BaseAppState;
5 | import com.jme3.input.KeyInput;
6 | import com.jme3.input.controls.ActionListener;
7 | import com.jme3.input.controls.KeyTrigger;
8 | import com.jme3.material.RenderState;
9 | import com.rvandoosselaer.blocks.BlocksConfig;
10 | import com.rvandoosselaer.blocks.TypeRegistry;
11 |
12 | /**
13 | * @author rvandoosselaer
14 | */
15 | public class WireframeState extends BaseAppState implements ActionListener {
16 |
17 | private static final KeyTrigger TOGGLE_WIREFRAME_TRIGGER = new KeyTrigger(KeyInput.KEY_W);
18 | private static final String TOGGLE_WIREFRAME = "toggle-wireframe";
19 |
20 | private boolean isWireframe = false;
21 |
22 | @Override
23 | protected void initialize(Application app) {
24 | app.getInputManager().addMapping(TOGGLE_WIREFRAME, TOGGLE_WIREFRAME_TRIGGER);
25 | app.getInputManager().addListener(this, TOGGLE_WIREFRAME);
26 | }
27 |
28 | @Override
29 | protected void cleanup(Application app) {
30 | app.getInputManager().deleteMapping(TOGGLE_WIREFRAME);
31 | app.getInputManager().removeListener(this);
32 | }
33 |
34 | @Override
35 | protected void onEnable() {
36 | // Nothing to do
37 | }
38 |
39 | @Override
40 | protected void onDisable() {
41 | // Nothing to do
42 | }
43 |
44 | @Override
45 | public void onAction(String name, boolean isPressed, float tpf) {
46 | if (TOGGLE_WIREFRAME.equals(name) && !isPressed) {
47 | toggleWireframe();
48 | }
49 | }
50 |
51 | private void toggleWireframe() {
52 | TypeRegistry typeRegistry = BlocksConfig.getInstance().getTypeRegistry();
53 | typeRegistry.getAll().stream()
54 | .map(typeRegistry::get)
55 | .forEach(material -> {
56 | material.getAdditionalRenderState().setWireframe(!isWireframe);
57 | material.getAdditionalRenderState().setFaceCullMode(!isWireframe ? RenderState.FaceCullMode.Off : RenderState.FaceCullMode.Back);
58 | });
59 | isWireframe = !isWireframe;
60 | }
61 |
62 | }
63 |
--------------------------------------------------------------------------------
/gradlew.bat:
--------------------------------------------------------------------------------
1 | @if "%DEBUG%" == "" @echo off
2 | @rem ##########################################################################
3 | @rem
4 | @rem Gradle startup script for Windows
5 | @rem
6 | @rem ##########################################################################
7 |
8 | @rem Set local scope for the variables with windows NT shell
9 | if "%OS%"=="Windows_NT" setlocal
10 |
11 | set DIRNAME=%~dp0
12 | if "%DIRNAME%" == "" set DIRNAME=.
13 | set APP_BASE_NAME=%~n0
14 | set APP_HOME=%DIRNAME%
15 |
16 | @rem Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script.
17 | set DEFAULT_JVM_OPTS=
18 |
19 | @rem Find java.exe
20 | if defined JAVA_HOME goto findJavaFromJavaHome
21 |
22 | set JAVA_EXE=java.exe
23 | %JAVA_EXE% -version >NUL 2>&1
24 | if "%ERRORLEVEL%" == "0" goto init
25 |
26 | echo.
27 | echo ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH.
28 | echo.
29 | echo Please set the JAVA_HOME variable in your environment to match the
30 | echo location of your Java installation.
31 |
32 | goto fail
33 |
34 | :findJavaFromJavaHome
35 | set JAVA_HOME=%JAVA_HOME:"=%
36 | set JAVA_EXE=%JAVA_HOME%/bin/java.exe
37 |
38 | if exist "%JAVA_EXE%" goto init
39 |
40 | echo.
41 | echo ERROR: JAVA_HOME is set to an invalid directory: %JAVA_HOME%
42 | echo.
43 | echo Please set the JAVA_HOME variable in your environment to match the
44 | echo location of your Java installation.
45 |
46 | goto fail
47 |
48 | :init
49 | @rem Get command-line arguments, handling Windows variants
50 |
51 | if not "%OS%" == "Windows_NT" goto win9xME_args
52 |
53 | :win9xME_args
54 | @rem Slurp the command line arguments.
55 | set CMD_LINE_ARGS=
56 | set _SKIP=2
57 |
58 | :win9xME_args_slurp
59 | if "x%~1" == "x" goto execute
60 |
61 | set CMD_LINE_ARGS=%*
62 |
63 | :execute
64 | @rem Setup the command line
65 |
66 | set CLASSPATH=%APP_HOME%\gradle\wrapper\gradle-wrapper.jar
67 |
68 | @rem Execute Gradle
69 | "%JAVA_EXE%" %DEFAULT_JVM_OPTS% %JAVA_OPTS% %GRADLE_OPTS% "-Dorg.gradle.appname=%APP_BASE_NAME%" -classpath "%CLASSPATH%" org.gradle.wrapper.GradleWrapperMain %CMD_LINE_ARGS%
70 |
71 | :end
72 | @rem End local scope for the variables with windows NT shell
73 | if "%ERRORLEVEL%"=="0" goto mainEnd
74 |
75 | :fail
76 | rem Set variable GRADLE_EXIT_CONSOLE if you need the _script_ return code instead of
77 | rem the _cmd.exe /c_ return code!
78 | if not "" == "%GRADLE_EXIT_CONSOLE%" exit 1
79 | exit /b 1
80 |
81 | :mainEnd
82 | if "%OS%"=="Windows_NT" endlocal
83 |
84 | :omega
85 |
--------------------------------------------------------------------------------
/core/src/main/java/org/delaunois/ialon/state/ChunkSaverState.java:
--------------------------------------------------------------------------------
1 | package org.delaunois.ialon.state;
2 |
3 | import com.google.common.util.concurrent.ThreadFactoryBuilder;
4 | import com.jme3.app.Application;
5 | import com.jme3.app.state.BaseAppState;
6 | import com.rvandoosselaer.blocks.Chunk;
7 | import com.rvandoosselaer.blocks.ChunkManagerListener;
8 | import com.simsilica.mathd.Vec3i;
9 |
10 | import org.delaunois.ialon.IalonConfig;
11 |
12 | import java.util.concurrent.ExecutorService;
13 | import java.util.concurrent.Executors;
14 |
15 | import lombok.extern.slf4j.Slf4j;
16 |
17 | /**
18 | * Persist chunk using the chunk repository
19 | *
20 | * @author Cedric de Launois
21 | */
22 | @Slf4j
23 | public class ChunkSaverState extends BaseAppState implements ChunkManagerListener {
24 |
25 | private ExecutorService executorService;
26 |
27 | private final IalonConfig config;
28 |
29 | public ChunkSaverState(IalonConfig config) {
30 | this.config = config;
31 | }
32 |
33 | @Override
34 | protected void initialize(Application app) {
35 | executorService = Executors.newSingleThreadExecutor(new ThreadFactoryBuilder().setNameFormat("chunk-saver").build());
36 | }
37 |
38 | /**
39 | * Saves (in another thread) the chunk at the given location
40 | * @param location the location of the chunk
41 | */
42 | public void asyncSave(Vec3i location) {
43 | config
44 | .getChunkManager()
45 | .getChunk(location)
46 | .ifPresent(chunk -> executorService.submit(() -> {
47 | try {
48 | config.getChunkRepository().save(chunk);
49 | log.info("Chunk {} saved", location);
50 | } catch (Exception e) {
51 | log.error("Failed to save chunk", e);
52 | }
53 | }));
54 | }
55 |
56 | @Override
57 | protected void cleanup(Application app) {
58 | log.info("Stopping chunk-saver");
59 | executorService.shutdown();
60 | }
61 |
62 | @Override
63 | protected void onEnable() {
64 | // Nothing to do
65 | }
66 |
67 | @Override
68 | protected void onDisable() {
69 | // Nothing to do
70 | }
71 |
72 | @Override
73 | public void onChunkUpdated(Chunk chunk) {
74 | asyncSave(chunk.getLocation());
75 | }
76 |
77 | @Override
78 | public void onChunkAvailable(Chunk chunk) {
79 | // Nothing to do
80 | }
81 | }
82 |
--------------------------------------------------------------------------------
/core/src/main/resources/Textures/arrowjump.svg:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
70 |
--------------------------------------------------------------------------------
/core/src/main/resources/Textures/arrowjump-full.svg:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
70 |
--------------------------------------------------------------------------------
/core/src/main/resources/Blocks/MatDefs/FluidDepth.j3md:
--------------------------------------------------------------------------------
1 | MaterialDef WaterDepth Textured {
2 |
3 | MaterialParameters {
4 | // the depth when the FadeColor is fully visible
5 | Float FadeDepth
6 |
7 | // the color the fluid will blend to
8 | Vector4 FadeColor
9 |
10 | // Enable fading of the fluid
11 | Boolean EnableFading
12 |
13 | // the shoreline size. Set to 0 to disable
14 | Float ShorelineSize
15 |
16 | // the color of the shoreline
17 | Vector4 ShorelineColor
18 |
19 | // samples for aa
20 | Int NumSamples
21 |
22 | // the rendered scene
23 | Texture2D Texture
24 |
25 | // the depth texture of the fluid geometries that fade
26 | Texture2D FluidDepthTexture
27 |
28 | // the depth texture of the scene without the geometries that fade
29 | Texture2D SceneDepthTexture
30 |
31 | // Enable water distortion to simulate the effect of light going through water
32 | Boolean UseDistortion
33 |
34 | // The strength of the distortion effect on the X and Y axes
35 | Float DistortionStrengthX
36 | Float DistortionStrengthY
37 |
38 | // The amplitude of the distortion effect on the X and Y axes
39 | Float DistortionAmplitudeX
40 | Float DistortionAmplitudeY
41 |
42 | // The speed of the distortion effect
43 | Float DistortionSpeed
44 |
45 | // the reflection texture
46 | Texture2D ReflectionMap
47 |
48 | // water height needed to calculate the reflection
49 | Float WaterHeight
50 |
51 | // the strength of the reflection in the water
52 | Float ReflectionStrength
53 |
54 | // needed to calculate texture position
55 | Matrix4 TextureProjMatrix
56 | Vector3 CameraPosition
57 |
58 | // blend mode to use for depth fading. By default colors are layered on top of each other, using this flag
59 | // it can be switched to overlay mode
60 | Boolean BlendOverlay
61 | }
62 |
63 | Technique {
64 | VertexShader GLSL310 GLSL300 GLSL100 GLSL150: Common/MatDefs/Post/Post.vert
65 | FragmentShader GLSL310 GLSL300 GLSL100 GLSL150: Blocks/Shaders/FluidDepth.frag
66 |
67 | WorldParameters {
68 | Time
69 | FrustumNearFar
70 | ViewProjectionMatrixInverse
71 | }
72 |
73 | Defines {
74 | DISTORTION : UseDistortion
75 | FADE: EnableFading
76 | BLEND_OVERLAY : BlendOverlay
77 | }
78 | }
79 |
80 | }
--------------------------------------------------------------------------------
/core/src/main/resources/Textures/minus.svg:
--------------------------------------------------------------------------------
1 |
2 |
19 |
20 |
47 |
49 | .cls-1{fill:#ff2400;}.cls-2{fill:#ba1d08;}
51 |
52 | Trash Can
54 |
56 |
57 |
59 | Trash Can
60 |
61 |
62 |
63 |
67 |
73 |
74 |
--------------------------------------------------------------------------------
/core/src/main/java/com/rvandoosselaer/blocks/ChunkMesh.java:
--------------------------------------------------------------------------------
1 | package com.rvandoosselaer.blocks;
2 |
3 | import com.jme3.scene.Mesh;
4 | import com.jme3.scene.VertexBuffer;
5 |
6 | import java.util.concurrent.TimeUnit;
7 |
8 | import lombok.Getter;
9 | import lombok.NoArgsConstructor;
10 | import lombok.extern.slf4j.Slf4j;
11 |
12 | /**
13 | * A class to help create a mesh for a specific block type of a chunk.
14 | *
15 | * @author rvandoosselaer
16 | */
17 | @Slf4j
18 | @Getter
19 | @NoArgsConstructor
20 | public class ChunkMesh {
21 |
22 | private static final int INITIAL_CAPACITY = 2000;
23 |
24 | private boolean collisionMesh = false;
25 | private final DirectVector3fBuffer positions = new DirectVector3fBuffer(INITIAL_CAPACITY);
26 | private final DirectVector3fBuffer normals = new DirectVector3fBuffer(INITIAL_CAPACITY);
27 | private final DirectVector4fBuffer tangents = new DirectVector4fBuffer(INITIAL_CAPACITY);
28 | private final DirectVector2fBuffer uvs = new DirectVector2fBuffer(INITIAL_CAPACITY);
29 | private final DirectIntBuffer indices = new DirectIntBuffer(INITIAL_CAPACITY);
30 | private final DirectVector4fBuffer colors = new DirectVector4fBuffer(INITIAL_CAPACITY);
31 |
32 | public ChunkMesh(boolean collisionMesh) {
33 | this.collisionMesh = collisionMesh;
34 | }
35 |
36 | public Mesh generateMesh() {
37 | long start = System.nanoTime();
38 | Mesh mesh = new Mesh();
39 | // all meshes have a position and index buffer
40 | mesh.setBuffer(VertexBuffer.Type.Position, 3, positions.getBuffer());
41 | mesh.setBuffer(VertexBuffer.Type.Index, 1, indices.getBuffer());
42 |
43 | // collision meshes don't require uvs, normals and tangents
44 | if (!isCollisionMesh()) {
45 | mesh.setBuffer(VertexBuffer.Type.TexCoord, 2, uvs.getBuffer());
46 | mesh.setBuffer(VertexBuffer.Type.Normal, 3, normals.getBuffer());
47 | if (!tangents.isEmpty()) {
48 | mesh.setBuffer(VertexBuffer.Type.Tangent, 4, tangents.getBuffer());
49 | }
50 | if (!colors.isEmpty()) {
51 | mesh.setBuffer(VertexBuffer.Type.Color, 4, colors.getBuffer());
52 | }
53 | }
54 | mesh.updateBound();
55 | mesh.setStatic();
56 | long stop = System.nanoTime();
57 | if (log.isTraceEnabled()) {
58 | log.trace("Mesh generation took {}ms", TimeUnit.NANOSECONDS.toMillis(stop - start));
59 | }
60 | return mesh;
61 | }
62 |
63 | public void clear() {
64 | // Nothing to do
65 | }
66 |
67 | }
68 |
--------------------------------------------------------------------------------
/core/src/main/resources/Textures/range.svg:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
76 |
--------------------------------------------------------------------------------
/core/src/main/java/org/delaunois/ialon/control/MoonControl.java:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (C) 2022 Cédric de Launois
3 | *
4 | * This program is free software: you can redistribute it and/or modify
5 | * it under the terms of the GNU General Public License as published by
6 | * the Free Software Foundation, either version 3 of the License, or
7 | * (at your option) any later version.
8 | *
9 | * This program is distributed in the hope that it will be useful,
10 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 | * GNU General Public License for more details.
13 | *
14 | * You should have received a copy of the GNU General Public License
15 | * along with this program. If not, see .
16 | */
17 |
18 | package org.delaunois.ialon.control;
19 |
20 | import com.jme3.math.FastMath;
21 | import com.jme3.math.Vector3f;
22 | import com.jme3.renderer.Camera;
23 | import com.jme3.renderer.RenderManager;
24 | import com.jme3.renderer.ViewPort;
25 | import com.jme3.scene.control.AbstractControl;
26 |
27 | import org.delaunois.ialon.IalonConfig;
28 |
29 | import lombok.Getter;
30 | import lombok.Setter;
31 | import lombok.extern.slf4j.Slf4j;
32 |
33 | @Slf4j
34 | public class MoonControl extends AbstractControl {
35 |
36 | @Getter
37 | @Setter
38 | private Vector3f position = new Vector3f();
39 |
40 | @Setter
41 | private SunControl sunControl;
42 |
43 | @Setter
44 | private Camera cam;
45 |
46 | private long lastUpdate = 0;
47 | private final IalonConfig config;
48 |
49 | public MoonControl(IalonConfig config) {
50 | this.config = config;
51 | }
52 |
53 | @Override
54 | protected void controlUpdate(float tpf) {
55 | if (!sunControl.isEnabled()) {
56 | return;
57 | }
58 |
59 | long now = System.currentTimeMillis();
60 | if (lastUpdate == 0 || now - lastUpdate > sunControl.getUpdateThreshold()) {
61 | lastUpdate = now;
62 | float time = config.getTime() + FastMath.PI;
63 | float height = FastMath.sin(time);
64 | float x = FastMath.cos(time) * 100f;
65 | float z = FastMath.sin(time) * 100f;
66 | float y = height * config.getSunAmplitude() * 10f;
67 | position.set(x, y, z);
68 | }
69 |
70 | spatial.setLocalTranslation((cam.getLocation().add(position)));
71 | spatial.lookAt(cam.getLocation(), Vector3f.UNIT_Y);
72 | }
73 |
74 | @Override
75 | protected void controlRender(RenderManager rm, ViewPort vp) {
76 | // Nothing to do
77 | }
78 |
79 | }
80 |
--------------------------------------------------------------------------------
/core/src/main/java/org/delaunois/ialon/ui/UiHelper.java:
--------------------------------------------------------------------------------
1 | package org.delaunois.ialon.ui;
2 |
3 | import com.jme3.math.ColorRGBA;
4 | import com.jme3.math.Vector3f;
5 | import com.simsilica.lemur.HAlignment;
6 | import com.simsilica.lemur.Panel;
7 | import com.simsilica.lemur.VAlignment;
8 | import com.simsilica.lemur.component.QuadBackgroundComponent;
9 |
10 | import org.delaunois.ialon.IalonConfig;
11 |
12 | import lombok.Getter;
13 |
14 | public class UiHelper {
15 |
16 | public static final String ALPHA_DISCARD_THRESHOLD = "AlphaDiscardThreshold";
17 |
18 | public static void addBackground(Panel panel) {
19 | addBackground(panel, new ColorRGBA(0f, 0, 0, 0.5f));
20 | }
21 |
22 | public static void addBackground(Panel panel, ColorRGBA colorRGBA) {
23 | QuadBackgroundComponent quadBackgroundComponent = new QuadBackgroundComponent(colorRGBA);
24 | quadBackgroundComponent.getMaterial().getMaterial().clearParam(ALPHA_DISCARD_THRESHOLD);
25 | panel.setBackground(quadBackgroundComponent);
26 | }
27 |
28 | public static IconButton createTextureButton(IalonConfig config, String textureName, float size, float posx, float posy) {
29 | IconButton iconButton = new IconButton();
30 |
31 | // Icon
32 | iconButton.icon = new Panel();
33 | iconButton.icon.setPreferredSize(new Vector3f(size, size, 0));
34 |
35 | AtlasIconComponent icon = new AtlasIconComponent("Textures/" + textureName);
36 | icon.setVAlignment(VAlignment.Center);
37 | icon.setHAlignment(HAlignment.Center);
38 | config.getTextureAtlasManager().getAtlas().applyCoords(icon.getIconGeometry(), 0.1f);
39 | icon.getMaterial().setTexture(config.getTextureAtlasManager().getDiffuseMap());
40 | icon.getMaterial().getMaterial().clearParam(ALPHA_DISCARD_THRESHOLD);
41 |
42 | iconButton.icon.setBackground(icon);
43 | iconButton.icon.setLocalTranslation(posx, posy, 0);
44 |
45 | // Background
46 | iconButton.background = new Panel();
47 | iconButton.background.setPreferredSize(new Vector3f(size, size, 0));
48 | QuadBackgroundComponent background = new QuadBackgroundComponent(new ColorRGBA(0, 0, 0, 0.5f));
49 | // Clear AlphaDiscardThreshold because it is useless here and generates a new specific Shader
50 | background.getMaterial().getMaterial().clearParam(ALPHA_DISCARD_THRESHOLD);
51 | iconButton.background.setBackground(background);
52 | iconButton.background.setLocalTranslation(posx, posy, -1);
53 |
54 | return iconButton;
55 | }
56 |
57 | public static class IconButton {
58 | @Getter
59 | public Panel icon;
60 |
61 | @Getter
62 | public Panel background;
63 | }
64 |
65 | }
66 |
--------------------------------------------------------------------------------
/core/src/main/resources/Textures/plus.svg:
--------------------------------------------------------------------------------
1 |
2 |
19 |
20 |
47 |
49 | .cls-1{fill:#ff2400;}.cls-2{fill:#ba1d08;}
51 |
52 | Trash Can
54 |
56 |
57 |
59 | Trash Can
60 |
61 |
62 |
63 |
67 |
71 |
77 |
78 |
--------------------------------------------------------------------------------
/core/src/main/java/org/delaunois/ialon/state/ChunkLiquidManagerState.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (C) 2022 Cédric de Launois
3 | *
4 | * This program is free software: you can redistribute it and/or modify
5 | * it under the terms of the GNU General Public License as published by
6 | * the Free Software Foundation, either version 3 of the License, or
7 | * (at your option) any later version.
8 | *
9 | * This program is distributed in the hope that it will be useful,
10 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 | * GNU General Public License for more details.
13 | *
14 | * You should have received a copy of the GNU General Public License
15 | * along with this program. If not, see .
16 | */
17 |
18 | package org.delaunois.ialon.state;
19 |
20 | import com.jme3.app.Application;
21 | import com.jme3.app.state.BaseAppState;
22 | import com.simsilica.mathd.Vec3i;
23 |
24 | import org.delaunois.ialon.ChunkLiquidManager;
25 | import org.delaunois.ialon.IalonConfig;
26 |
27 | import java.util.HashSet;
28 | import java.util.Set;
29 |
30 | import lombok.Getter;
31 | import lombok.extern.slf4j.Slf4j;
32 |
33 | /**
34 | * An application state to handle the liquid simulation.
35 | *
36 | * @author Cedric de Launois
37 | */
38 | @Slf4j
39 | public class ChunkLiquidManagerState extends BaseAppState {
40 |
41 | @Getter
42 | private final ChunkLiquidManager chunkLiquidManager;
43 |
44 | private float elapsed = 0;
45 | private final IalonConfig config;
46 |
47 | public ChunkLiquidManagerState(IalonConfig config) {
48 | this.config = config;
49 | this.chunkLiquidManager = new ChunkLiquidManager(config);
50 | }
51 |
52 | @Override
53 | protected void initialize(Application app) {
54 | // Nothing to do
55 | }
56 |
57 | @Override
58 | protected void cleanup(Application app) {
59 | // Nothing to do
60 | }
61 |
62 | @Override
63 | protected void onEnable() {
64 | // Nothing to do
65 | }
66 |
67 | @Override
68 | protected void onDisable() {
69 | // Nothing to do
70 | }
71 |
72 | @Override
73 | public void update(float tpf) {
74 | elapsed += tpf;
75 | int queueSize = chunkLiquidManager.queueSize();
76 | if (elapsed > (1 / config.getWaterSimulationSpeed()) && queueSize > 0) {
77 | Set updatedChunks = new HashSet<>();
78 | for (int i = 0; i < queueSize; i ++) {
79 | updatedChunks.addAll(chunkLiquidManager.step());
80 | }
81 | if (!updatedChunks.isEmpty()) {
82 | chunkLiquidManager.updateChunkMesh(updatedChunks);
83 | }
84 | elapsed = 0;
85 | }
86 | }
87 |
88 | }
89 |
--------------------------------------------------------------------------------
/core/src/main/java/org/delaunois/ialon/state/SettingsValue.java:
--------------------------------------------------------------------------------
1 | package org.delaunois.ialon.state;
2 |
3 | import com.jme3.math.Vector3f;
4 | import com.jme3.renderer.Camera;
5 | import com.simsilica.lemur.Container;
6 | import com.simsilica.lemur.DefaultRangedValueModel;
7 | import com.simsilica.lemur.Insets3f;
8 | import com.simsilica.lemur.Label;
9 | import com.simsilica.lemur.VAlignment;
10 | import com.simsilica.lemur.core.VersionedReference;
11 |
12 | import org.delaunois.ialon.ui.Slider;
13 |
14 | import java.util.function.Function;
15 |
16 | import static org.delaunois.ialon.Ialon.IALON_STYLE;
17 |
18 | public class SettingsValue {
19 |
20 | private final String title;
21 | private final double min;
22 | private final double max;
23 | private final double value;
24 | private final Camera cam;
25 | private final Function labelValueFunction;
26 | private VersionedReference sliderRef;
27 | private Label label;
28 |
29 | public SettingsValue(String title, Camera cam, double min, double max, double value) {
30 | this(title, cam, min, max, value, String::valueOf);
31 | }
32 |
33 | public SettingsValue(String title, Camera cam, double min, double max, double value, Function labelValueFunction) {
34 | this.title = title;
35 | this.cam = cam;
36 | this.min = min;
37 | this.max = max;
38 | this.value = value;
39 | this.labelValueFunction = labelValueFunction;
40 | }
41 |
42 | public void addToContainer(Container container, int position) {
43 | float vw = cam.getWidth() / 100f;
44 | float vh = cam.getHeight() / 100f;
45 | Label titleLabel = new Label(title);
46 | titleLabel.setFontSize(4 * vh);
47 | titleLabel.setPreferredSize(new Vector3f(20 * vw, 8 * vh, 0));
48 | titleLabel.setTextVAlignment(VAlignment.Center);
49 | container.addChild(titleLabel, position, 0);
50 |
51 | Slider slider = new Slider(IALON_STYLE);
52 | slider.setPreferredSize(new Vector3f(50 * vw, 8 * vh, 0));
53 | slider.setModel(new DefaultRangedValueModel(min, max, value));
54 | slider.setLocalTranslation(0, 0, 4f);
55 | slider.setInsets(new Insets3f(0, vw, 0, vw));
56 | sliderRef = container.addChild(slider, position, 1).getModel().createReference();
57 |
58 | label = new Label(labelValueFunction.apply(value));
59 | label.setFontSize(4 * vh);
60 | label.setPreferredSize(new Vector3f(8 * vw, 8 * vh, 0));
61 | label.setTextVAlignment(VAlignment.Center);
62 | container.addChild(label, position, 2);
63 | }
64 |
65 | public void update() {
66 | if (sliderRef.update()) {
67 | label.setText(labelValueFunction.apply(sliderRef.get()));
68 | }
69 | }
70 |
71 | public double getValue() {
72 | return sliderRef.get();
73 | }
74 |
75 | }
76 |
--------------------------------------------------------------------------------
/core/src/test/java/org/delaunois/ialon/ChunkManagerTest.java:
--------------------------------------------------------------------------------
1 | package org.delaunois.ialon;
2 |
3 | import com.jme3.asset.DesktopAssetManager;
4 | import com.jme3.math.Vector3f;
5 | import com.jme3.util.BufferAllocatorFactory;
6 | import com.jme3.util.PrimitiveAllocator;
7 | import com.rvandoosselaer.blocks.BlocksConfig;
8 | import com.simsilica.mathd.Vec3i;
9 |
10 | import org.junit.jupiter.api.AfterEach;
11 | import org.junit.jupiter.api.BeforeAll;
12 | import org.junit.jupiter.api.Test;
13 |
14 | import static org.junit.jupiter.api.Assertions.assertEquals;
15 | import static org.junit.jupiter.api.Assertions.assertNotNull;
16 |
17 | class ChunkManagerTest {
18 |
19 | static {
20 | System.setProperty(BufferAllocatorFactory.PROPERTY_BUFFER_ALLOCATOR_IMPLEMENTATION, PrimitiveAllocator.class.getName());
21 | }
22 |
23 | @BeforeAll
24 | static void setUp() {
25 | IalonInitializer.configureBlocksFramework(new DesktopAssetManager(true), new IalonConfig());
26 | }
27 |
28 | @AfterEach
29 | void reset() {
30 | IalonInitializer.configureBlocksFramework(new DesktopAssetManager(true), new IalonConfig());
31 | }
32 |
33 | @Test
34 | void testLocationCalculation() {
35 | BlocksConfig.getInstance().setChunkSize(new Vec3i(16, 16, 16));
36 |
37 | Vector3f location = new Vector3f(0, 0, 0);
38 | Vec3i chunkLocation = ChunkManager.getChunkLocation(location);
39 |
40 | assertEquals(new Vec3i(0, 0, 0), chunkLocation);
41 |
42 | location = new Vector3f(13, 10, 5);
43 | chunkLocation = ChunkManager.getChunkLocation(location);
44 |
45 | assertEquals(new Vec3i(0, 0, 0), chunkLocation);
46 |
47 | location = new Vector3f(-5, 3, -9);
48 | chunkLocation = ChunkManager.getChunkLocation(location);
49 |
50 | assertEquals(new Vec3i(-1, 0, -1), chunkLocation);
51 |
52 | location = new Vector3f(16, 15, 2);
53 | chunkLocation = ChunkManager.getChunkLocation(location);
54 |
55 | assertEquals(new Vec3i(1, 0, 0), chunkLocation);
56 |
57 | location = new Vector3f(16, 32, 2);
58 | chunkLocation = ChunkManager.getChunkLocation(location);
59 |
60 | assertEquals(new Vec3i(1, 2, 0), chunkLocation);
61 | }
62 |
63 | @Test
64 | void testAddBlock() {
65 | ChunkManager chunkManager = ChunkManager.builder().poolSize(1).build();
66 | assertNotNull(chunkManager);
67 | chunkManager.initialize();
68 |
69 | IalonConfig config = new IalonConfig();
70 | config.setChunkManager(chunkManager);
71 |
72 | WorldManager worldManager = new WorldManager(chunkManager,
73 | new ChunkLightManager(config),
74 | new ChunkLiquidManager(config));
75 |
76 | Vector3f location = new Vector3f(16, 32, 2);
77 | worldManager.addBlock(location, BlocksConfig.getInstance().getBlockRegistry().get((short)1));
78 | }
79 | }
80 |
--------------------------------------------------------------------------------
/core/src/main/java/org/delaunois/ialon/state/AxesDebugState.java:
--------------------------------------------------------------------------------
1 | package org.delaunois.ialon.state;
2 |
3 | import com.jme3.app.Application;
4 | import com.jme3.app.SimpleApplication;
5 | import com.jme3.app.state.BaseAppState;
6 | import com.jme3.material.Material;
7 | import com.jme3.math.ColorRGBA;
8 | import com.jme3.math.Vector3f;
9 | import com.jme3.scene.Geometry;
10 | import com.jme3.scene.Mesh;
11 | import com.jme3.scene.Node;
12 | import com.jme3.scene.debug.Arrow;
13 |
14 | public class AxesDebugState extends BaseAppState {
15 |
16 | private static final int SIZE = 50;
17 |
18 | private final Node axes;
19 | private final Arrow x;
20 | private final Arrow y;
21 | private final Arrow z;
22 |
23 | private Node rootNode;
24 | private SimpleApplication app;
25 |
26 | public AxesDebugState() {
27 | x = new Arrow(Vector3f.UNIT_X.mult(SIZE));
28 | y = new Arrow(Vector3f.UNIT_Y.mult(SIZE));
29 | z = new Arrow(Vector3f.UNIT_Z.mult(SIZE));
30 | axes = new Node("Axes");
31 | }
32 |
33 | @Override
34 | protected void initialize(Application app) {
35 | this.app = (SimpleApplication) app;
36 | this.rootNode = this.app.getGuiNode();
37 | Geometry gx = buildGeometry(x, ColorRGBA.Red);
38 | Geometry gy = buildGeometry(y, ColorRGBA.Green);
39 | Geometry gz = buildGeometry(z, ColorRGBA.Blue);
40 | axes.attachChild(gx);
41 | axes.attachChild(gy);
42 | axes.attachChild(gz);
43 | Vector3f position = new Vector3f(50.0f, app.getCamera().getHeight() * 0.38f, -1);
44 | setPosition(position);
45 | }
46 |
47 | @Override
48 | public void update(float tpf) {
49 | axes.setLocalRotation(app.getCamera().getRotation());
50 | }
51 |
52 | @Override
53 | protected void cleanup(Application app) {
54 | // Nothing to do
55 | }
56 |
57 | public void setPosition(Vector3f position) {
58 | axes.setLocalTranslation(position);
59 | }
60 |
61 | @Override
62 | protected void onEnable() {
63 | if (rootNode == null) {
64 | rootNode = ((SimpleApplication) getApplication()).getGuiNode();
65 | }
66 |
67 | if (axes.getParent() == null) {
68 | rootNode.attachChild(axes);
69 | }
70 | }
71 |
72 | @Override
73 | protected void onDisable() {
74 | if (axes.getParent() != null) {
75 | rootNode.detachChild(axes);
76 | }
77 | }
78 |
79 | private Geometry buildGeometry(Mesh shape, ColorRGBA color) {
80 | Geometry g = new Geometry("coordinate axis", shape);
81 | Material mat = new Material(app.getAssetManager(), "Common/MatDefs/Misc/Unshaded.j3md");
82 | mat.getAdditionalRenderState().setWireframe(true);
83 | mat.getAdditionalRenderState().setLineWidth(4);
84 | mat.setColor("Color", color);
85 | g.setMaterial(mat);
86 | return g;
87 | }
88 | }
89 |
--------------------------------------------------------------------------------
/core/src/main/java/org/delaunois/ialon/IalonShapeSet.java:
--------------------------------------------------------------------------------
1 | package org.delaunois.ialon;
2 |
3 | import com.rvandoosselaer.blocks.ShapeIds;
4 |
5 | public enum IalonShapeSet {
6 |
7 | STANDARD_SHAPES_NO_STAIRS(
8 | new String[] {
9 | ShapeIds.CUBE,
10 | ShapeIds.PYRAMID,
11 | ShapeIds.POLE,
12 | ShapeIds.FENCE,
13 | ShapeIds.SLAB,
14 | ShapeIds.DOUBLE_SLAB,
15 | ShapeIds.PLATE,
16 | ShapeIds.WEDGE_NORTH,
17 | ShapeIds.WEDGE_EAST,
18 | ShapeIds.WEDGE_SOUTH,
19 | ShapeIds.WEDGE_WEST,
20 | ShapeIds.WEDGE_INVERTED_NORTH,
21 | ShapeIds.WEDGE_INVERTED_EAST,
22 | ShapeIds.WEDGE_INVERTED_SOUTH,
23 | ShapeIds.WEDGE_INVERTED_WEST,
24 | }
25 | ),
26 | STANDARD_SHAPES(new String[]{
27 | ShapeIds.CUBE,
28 | ShapeIds.PYRAMID,
29 | ShapeIds.POLE,
30 | ShapeIds.FENCE,
31 | ShapeIds.SLAB,
32 | ShapeIds.DOUBLE_SLAB,
33 | ShapeIds.PLATE,
34 | ShapeIds.WEDGE_NORTH,
35 | ShapeIds.WEDGE_EAST,
36 | ShapeIds.WEDGE_SOUTH,
37 | ShapeIds.WEDGE_WEST,
38 | ShapeIds.WEDGE_INVERTED_NORTH,
39 | ShapeIds.WEDGE_INVERTED_EAST,
40 | ShapeIds.WEDGE_INVERTED_SOUTH,
41 | ShapeIds.WEDGE_INVERTED_WEST,
42 | ShapeIds.STAIRS_NORTH,
43 | ShapeIds.STAIRS_EAST,
44 | ShapeIds.STAIRS_SOUTH,
45 | ShapeIds.STAIRS_WEST,
46 | ShapeIds.STAIRS_INVERTED_NORTH,
47 | ShapeIds.STAIRS_INVERTED_EAST,
48 | ShapeIds.STAIRS_INVERTED_SOUTH,
49 | ShapeIds.STAIRS_INVERTED_WEST,
50 | ShapeIds.STAIRS_INNER_CORNER_NORTH,
51 | ShapeIds.STAIRS_INNER_CORNER_EAST,
52 | ShapeIds.STAIRS_INNER_CORNER_SOUTH,
53 | ShapeIds.STAIRS_INNER_CORNER_WEST,
54 | ShapeIds.STAIRS_INVERTED_INNER_CORNER_NORTH,
55 | ShapeIds.STAIRS_INVERTED_INNER_CORNER_EAST,
56 | ShapeIds.STAIRS_INVERTED_INNER_CORNER_SOUTH,
57 | ShapeIds.STAIRS_INVERTED_INNER_CORNER_WEST,
58 | ShapeIds.STAIRS_OUTER_CORNER_NORTH,
59 | ShapeIds.STAIRS_OUTER_CORNER_EAST,
60 | ShapeIds.STAIRS_OUTER_CORNER_SOUTH,
61 | ShapeIds.STAIRS_OUTER_CORNER_WEST,
62 | ShapeIds.STAIRS_INVERTED_OUTER_CORNER_NORTH,
63 | ShapeIds.STAIRS_INVERTED_OUTER_CORNER_EAST,
64 | ShapeIds.STAIRS_INVERTED_OUTER_CORNER_SOUTH,
65 | ShapeIds.STAIRS_INVERTED_OUTER_CORNER_WEST
66 | });
67 |
68 | private final String[] shapes;
69 |
70 | IalonShapeSet(String[] shapes) {
71 | this.shapes = shapes;
72 | }
73 |
74 | public String[] getShapes() {
75 | return shapes;
76 | }
77 | }
78 |
79 |
--------------------------------------------------------------------------------
/core/src/main/java/org/delaunois/ialon/state/MoonState.java:
--------------------------------------------------------------------------------
1 | package org.delaunois.ialon.state;
2 |
3 | import com.jme3.app.Application;
4 | import com.jme3.app.SimpleApplication;
5 | import com.jme3.app.state.BaseAppState;
6 | import com.jme3.asset.TextureKey;
7 | import com.jme3.material.Material;
8 | import com.jme3.material.RenderState;
9 | import com.jme3.math.ColorRGBA;
10 | import com.jme3.renderer.queue.RenderQueue;
11 | import com.jme3.scene.Geometry;
12 | import com.jme3.scene.Spatial;
13 | import com.jme3.scene.shape.Quad;
14 | import com.jme3.texture.Texture;
15 |
16 | import org.delaunois.ialon.IalonConfig;
17 | import org.delaunois.ialon.control.MoonControl;
18 |
19 | import lombok.extern.slf4j.Slf4j;
20 |
21 | @Slf4j
22 | public class MoonState extends BaseAppState {
23 |
24 | private SimpleApplication app;
25 | private MoonControl moonControl;
26 | private Geometry moon;
27 | private final IalonConfig config;
28 |
29 | public MoonState(IalonConfig config) {
30 | this.config = config;
31 | }
32 |
33 | @Override
34 | protected void initialize(Application app) {
35 | this.app = (SimpleApplication) app;
36 |
37 | moon = new Geometry("moon", new Quad(15f, 15f));
38 | moon.setQueueBucket(RenderQueue.Bucket.Sky);
39 | moon.setCullHint(Spatial.CullHint.Never);
40 | moon.setShadowMode(RenderQueue.ShadowMode.Off);
41 |
42 | TextureKey tex = new TextureKey("Textures/moon.png");
43 | tex.setGenerateMips(false);
44 | Texture moonTexture = app.getAssetManager().loadTexture(tex);
45 | Material moonMat = new Material(app.getAssetManager(), "Common/MatDefs/Misc/Unshaded.j3md");
46 | moonMat.getAdditionalRenderState().setBlendMode(RenderState.BlendMode.Alpha);
47 | moonMat.setTexture("ColorMap", moonTexture);
48 | moonMat.setColor("Color", ColorRGBA.White);
49 | moon.setMaterial(moonMat);
50 |
51 | config.getTextureAtlasManager().getAtlas().applyCoords(moon, 0.1f);
52 | moonMat.setTexture("ColorMap", config.getTextureAtlasManager().getDiffuseMap());
53 |
54 | moonControl = new MoonControl(config);
55 | moonControl.setCam(app.getCamera());
56 | moon.addControl(moonControl);
57 | }
58 |
59 | @Override
60 | protected void cleanup(Application app) {
61 | // Nothing to do
62 | }
63 |
64 | @Override
65 | protected void onEnable() {
66 | SunState sunState = app.getStateManager().getState(SunState.class);
67 | if (sunState == null) {
68 | log.error("MoonState requires SunState");
69 | return;
70 | }
71 | moonControl.setSunControl(sunState.getSunControl());
72 | if (moon.getParent() == null) {
73 | this.app.getRootNode().attachChild(moon);
74 | }
75 | }
76 |
77 | @Override
78 | protected void onDisable() {
79 | if (moon.getParent() != null) {
80 | this.app.getRootNode().detachChild(moon);
81 | }
82 | }
83 |
84 |
85 | }
86 |
--------------------------------------------------------------------------------
/core/src/main/java/org/delaunois/ialon/state/WagonState.java:
--------------------------------------------------------------------------------
1 | package org.delaunois.ialon.state;
2 |
3 | import com.jme3.app.Application;
4 | import com.jme3.app.state.BaseAppState;
5 | import com.jme3.bullet.BulletAppState;
6 | import com.jme3.bullet.collision.shapes.BoxCollisionShape;
7 | import com.jme3.bullet.control.RigidBodyControl;
8 | import com.jme3.material.Material;
9 | import com.jme3.math.Quaternion;
10 | import com.jme3.math.Vector3f;
11 | import com.jme3.scene.Geometry;
12 | import com.jme3.scene.Node;
13 |
14 | import org.delaunois.ialon.Ialon;
15 |
16 | import lombok.Getter;
17 |
18 | public class WagonState extends BaseAppState {
19 |
20 | private Node rootNode;
21 | private Ialon app;
22 |
23 | @Getter
24 | private Node wagonNode;
25 |
26 | private final Quaternion rotation = new Quaternion();
27 | private float angle = 0;
28 |
29 | @Override
30 | protected void initialize(Application app) {
31 | this.app = (Ialon) app;
32 | this.rootNode = this.app.getRootNode();
33 |
34 | wagonNode = new Node("Wagon");
35 | Geometry wagon = createWagon();
36 | wagon.setLocalTranslation(0, -0.2f, 0);
37 | wagonNode.attachChild(wagon);
38 | BoxCollisionShape collisionShape = new BoxCollisionShape(0.25f, 0.15f, 0.35f);
39 | RigidBodyControl rigidBodyControl = new RigidBodyControl(collisionShape, 1f);
40 | wagonNode.addControl(rigidBodyControl);
41 | rigidBodyControl.setKinematic(true);
42 | wagonNode.setLocalTranslation(-15.5f, 61f, -66.5f);
43 | }
44 |
45 | @Override
46 | public void update(float tpf) {
47 | // Nothing to do
48 | angle += tpf;
49 | wagonNode.setLocalRotation(rotation.fromAngleNormalAxis(angle, Vector3f.UNIT_Y));
50 | }
51 |
52 | @Override
53 | protected void cleanup(Application app) {
54 | // Nothing to do
55 | }
56 |
57 | @Override
58 | protected void onEnable() {
59 | if (wagonNode.getParent() == null) {
60 | BulletAppState bulletAppState = app.getStateManager().getState(BulletAppState.class);
61 | bulletAppState.getPhysicsSpace().add(wagonNode);
62 | rootNode.attachChild(wagonNode);
63 | }
64 | }
65 |
66 | @Override
67 | protected void onDisable() {
68 | if (wagonNode.getParent() != null) {
69 | wagonNode.getParent().detachChild(wagonNode);
70 | BulletAppState bulletAppState = app.getStateManager().getState(BulletAppState.class);
71 | if (bulletAppState.getPhysicsSpace() != null) {
72 | bulletAppState.getPhysicsSpace().remove(wagonNode);
73 | }
74 | }
75 | }
76 |
77 | private Geometry createWagon() {
78 | Geometry model = (Geometry) app.getAssetManager().loadModel("Models/Wagon/wagon.j3o");
79 | Material modelMaterial = model.getMaterial();
80 | modelMaterial.setTexture("DiffuseMap", app.getConfig().getTextureAtlasManager().getDiffuseMap());
81 | return model;
82 | }
83 | }
84 |
--------------------------------------------------------------------------------