Skip to content

Commit

Permalink
Further work on 1.19.2 port
Browse files Browse the repository at this point in the history
  • Loading branch information
Sniffity committed Oct 22, 2022
1 parent 49f92ff commit 8eec416
Show file tree
Hide file tree
Showing 4 changed files with 17 additions and 23 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
import com.github.sniffity.panthalassa.client.events.CameraSetupEvent;
import com.github.sniffity.panthalassa.client.events.KeyInputEvent;
import com.github.sniffity.panthalassa.client.events.RenderTickEvent;
import com.github.sniffity.panthalassa.client.render.armor.RenderDivingSuit;
import com.github.sniffity.panthalassa.client.render.blockentity.RenderHydrothermalVent;
import com.github.sniffity.panthalassa.client.render.blockentity.RenderPressureEqualizer;
import com.github.sniffity.panthalassa.client.render.display.RenderArchelonShell;
Expand Down Expand Up @@ -37,6 +38,8 @@
import net.minecraftforge.fml.common.Mod.EventBusSubscriber.Bus;
import net.minecraftforge.fml.event.lifecycle.FMLClientSetupEvent;
import org.lwjgl.glfw.GLFW;
import software.bernie.example.client.renderer.armor.GeckoArmorRenderer;

import java.awt.*;


Expand Down Expand Up @@ -118,6 +121,11 @@ public static void registerRenderers(final EntityRenderersEvent.RegisterRenderer
RenderTranquilizingTorpedo::new);
}

@SubscribeEvent
public static void registerRenderers(final EntityRenderersEvent.AddLayers event) {
RenderDivingSuit.registerArmorRenderer(ItemDivingSuit.class, ()-> new RenderDivingSuit());
}

public static final KeyMapping KEY_VEHICLE_LIGHTS = new KeyMapping("key.vehicle.lights", GLFW.GLFW_KEY_H, "key.panthalassa.category");
public static final KeyMapping KEY_VEHICLE_SPECIAL = new KeyMapping("key.vehicle.special", GLFW.GLFW_KEY_Y, "key.panthalassa.category");
public static final KeyMapping KEY_VEHICLE_SONAR = new KeyMapping("key.vehicle.sonar", GLFW.GLFW_KEY_N, "key.panthalassa.category");
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ public boolean canUse() {
int searchRadius = 10;
PoiManager pointofinterestmanager = ((ServerLevel) creature.level).getPoiManager();
Optional<PoiRecord> portalPOI = pointofinterestmanager.getInRange(
(pointOfInterestType) -> pointOfInterestType == PanthalassaPOI.PANTHALASSA_POI_PORTAL.getKey(),
(pointOfInterestType) -> pointOfInterestType.get() == PanthalassaPOI.PANTHALASSA_POI_PORTAL.get(),
creature.blockPosition(),
searchRadius,
PoiManager.Occupancy.ANY)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,8 +22,8 @@ public class PanthalassaBlocks {
public static final RegistryObject<Block> PORTAL_FRAME = register("panthalassa_portal_frame",
BlockPortalFrame::new, new Item.Properties().tab(PanthalassaItemGroup.GROUP));

public static final RegistryObject<Block> PORTAL = register("panthalassa_portal",
BlockPortal::new, new Item.Properties().tab(PanthalassaItemGroup.GROUP));
public static final RegistryObject<Block> PORTAL = BLOCKS.register("panthalassa_portal",
BlockPortal::new);

public static final RegistryObject<Block> PRIMORDIAL_STALK = register("primordial_stalk",
() -> new BlockPrimordialStalk(BlockBehaviour.Properties.of(Material.PLANT, MaterialColor.COLOR_GREEN)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
"noise": {
"min_y": 0,
"height": 128,
"size_horizontal": 2,
"size_horizontal": 1,
"size_vertical": 2
},
"noise_router": {
Expand All @@ -42,25 +42,11 @@
"shift_y": 0,
"shift_z": "minecraft:shift_z"
},
"continents": "minecraft:overworld/continents",
"erosion": "minecraft:overworld/erosion",
"depth": "minecraft:overworld/depth",
"ridges": "minecraft:overworld/ridges",
"initial_density_without_jaggedness": {
"type": "minecraft:mul",
"argument1": 4,
"argument2": {
"type": "minecraft:quarter_negative",
"argument": {
"type": "minecraft:mul",
"argument1": "minecraft:overworld/depth",
"argument2": {
"type": "minecraft:cache_2d",
"argument": "minecraft:overworld/factor"
}
}
}
},
"continents": 0,
"erosion": 0,
"depth": 0,
"ridges": 0,
"initial_density_without_jaggedness": 0,
"final_density": {
"type": "minecraft:squeeze",
"argument": {
Expand Down

0 comments on commit 8eec416

Please sign in to comment.