tiles
Fabien Benetou 2 years ago
parent e3604cc7de
commit 892e725ed7
  1. 19
      index.html

@ -1902,6 +1902,14 @@ const available_asset_kits = [
tiles_types_parts : ["battlement"],
tiles : [ "battlement", "battlement_cornerInner", "battlement_cornerOuter", "battlement_half", "column", "columnPaint", "columnPaint_damaged", "column_damaged", "detail_barrel", "detail_crate", "detail_crateSmall", "fence", "floor", "floor_flat", "floor_stairs", "floor_stairsCornerInner", "floor_stairsCornerOuter", "floor_steps", "floor_stepsCornerInner", "floor_stepsCornerOuter", "overhang", "overhang_fence", "overhang_round", "roof", "roof_corner", "roof_edge", "structure", "structure_poles", "structure_wall", "tower", "towerPaint", "towerPaint_base", "tower_base", "tower_edge", "tower_top", "wall", "wallFortified", "wallFortifiedPaint", "wallFortifiedPaint_gate", "wallFortifiedPaint_half", "wallFortified_gate", "wallFortified_gateHalf", "wallFortified_half", "wallPaint", "wallPaint_detail", "wallPaint_flat", "wallPaint_gate", "wallPaint_half", "wall_detail", "wall_flat", "wall_flatGate", "wall_gate", "wall_gateHalf", "wall_half", "wall_low" ],
hex_type : false,
},{
force_extension : ".gltf",
force_horizontal_offset : .5,
tile_URL : "../content/UltimateSpaceKit-March2023/",
tiles_types_full : ["Characters", "Environment", "Items", "Vehicles"],
tiles_types_parts : [],
tiles: ["Characters/Astronaut_BarbaraTheBee", "Characters/Astronaut_FernandoTheFlamingo", "Characters/Astronaut_FinnTheFrog", "Characters/Astronaut_RaeTheRedPanda", "Characters/Enemy_ExtraSmall", "Characters/Enemy_Flying", "Characters/Enemy_Large", "Characters/Enemy_Small", "Characters/Mech_BarbaraTheBee", "Characters/Mech_FernandoTheFlamingo", "Characters/Mech_FinnTheFrog", "Characters/Mech_RaeTheRedPanda", "Environment/Base_Large", "Environment/Building_L", "Environment/Bush_1", "Environment/Bush_2", "Environment/Bush_3", "Environment/Connector", "Environment/GeodesicDome", "Environment/Grass_1", "Environment/Grass_2", "Environment/Grass_3", "Environment/House_Cylinder", "Environment/House_Long", "Environment/House_Open", "Environment/House_OpenBack", "Environment/House_Single", "Environment/House_Single_Support", "Environment/MetalSupport", "Environment/Planet_1", "Environment/Planet_10", "Environment/Planet_11", "Environment/Planet_2", "Environment/Planet_3", "Environment/Planet_4", "Environment/Planet_5", "Environment/Planet_6", "Environment/Planet_7", "Environment/Planet_8", "Environment/Planet_9", "Environment/Plant_1", "Environment/Plant_2", "Environment/Plant_3", "Environment/Ramp", "Environment/Rock_1", "Environment/Rock_2", "Environment/Rock_3", "Environment/Rock_4", "Environment/Rock_Large_1", "Environment/Rock_Large_2", "Environment/Rock_Large_3", "Environment/Roof_Antenna", "Environment/Roof_Opening", "Environment/Roof_Radar", "Environment/Roof_VentL", "Environment/Roof_VentR", "Environment/SolarPanel_Ground", "Environment/SolarPanel_Roof", "Environment/SolarPanel_Structure", "Environment/Stairs", "Environment/Tree_Blob_1", "Environment/Tree_Blob_2", "Environment/Tree_Blob_3", "Environment/Tree_Floating_1", "Environment/Tree_Floating_2", "Environment/Tree_Floating_3", "Environment/Tree_Lava_1", "Environment/Tree_Lava_2", "Environment/Tree_Lava_3", "Environment/Tree_Light_1", "Environment/Tree_Light_2", "Environment/Tree_Spikes_1", "Environment/Tree_Spikes_2", "Environment/Tree_Spiral_1", "Environment/Tree_Spiral_2", "Environment/Tree_Spiral_3", "Environment/Tree_Swirl_1", "Environment/Tree_Swirl_2", "Items/Pickup_Bullets", "Items/Pickup_Crate", "Items/Pickup_Health", "Items/Pickup_Jar", "Items/Pickup_KeyCard", "Items/Pickup_Sphere", "Items/Pickup_Thunder", "Vehicles/Rover_1", "Vehicles/Rover_2", "Vehicles/Rover_Round", "Vehicles/Spaceship_BarbaraTheBee", "Vehicles/Spaceship_FernandoTheFlamingo", "Vehicles/Spaceship_FinnTheFrog", "Vehicles/Spaceship_RaeTheRedPanda",],
hex_type : false,
}
]
@ -1920,13 +1928,18 @@ function displayAllTiles(){
tiles_types.map( (tile_type,ttn) => {
if (t.indexOf(tile_type) > -1) {
x = ttn/10
if (available_asset_kits[selected_asset_kit].force_horizontal_offset)
x+=ttn*available_asset_kits[selected_asset_kit].force_horizontal_offset
if (tile_type != last_type) n = 0
last_type = tile_type
}
} )
let el = addGltfFromURLAsTarget( available_asset_kits[selected_asset_kit].tile_URL+t+tile_extension,
.09,
""+x+" 0.7 -"+n*scale )
let fullURL = available_asset_kits[selected_asset_kit].tile_URL+t
if ( available_asset_kits[selected_asset_kit].force_extension )
fullURL+=available_asset_kits[selected_asset_kit].force_extension
else
fullURL+=tile_extension
let el = addGltfFromURLAsTarget( fullURL, .09, ""+x+" 0.7 -"+n*scale )
// fine tuning should also be per asset set
// el.class = ...
n++

Loading…
Cancel
Save