Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions commons/src/main/java/net/swofty/commons/CustomWorlds.java
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,8 @@
public enum CustomWorlds {
SKYBLOCK_ISLAND_TEMPLATE("hypixel_skyblock_island_template"),
SKYBLOCK_HUB("hypixel_skyblock_hub"),
SKYBLOCK_SPIDERS_DEN("hypixel_skyblock_spiders_den"),
SKYBLOCK_THE_END("hypixel_skyblock_the_end"),
SKYBLOCK_GOLD_MINE("hypixel_skyblock_gold_mine"),
SKYBLOCK_DEEP_CAVERNS("hypixel_skyblock_deep_caverns"),
SKYBLOCK_DWARVEN_MINES("hypixel_skyblock_dwarven_mines"),
Expand Down
2 changes: 2 additions & 0 deletions commons/src/main/java/net/swofty/commons/ServerType.java
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,8 @@
public enum ServerType {
SKYBLOCK_ISLAND(true),
SKYBLOCK_HUB(true),
SKYBLOCK_SPIDERS_DEN(true),
SKYBLOCK_THE_END(true),
SKYBLOCK_DUNGEON_HUB(true),
SKYBLOCK_THE_FARMING_ISLANDS(true),
SKYBLOCK_GOLD_MINE(true),
Expand Down
2 changes: 2 additions & 0 deletions loader/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,8 @@ dependencies {
implementation(project(":type.island"))
implementation(project(":type.hub"))
implementation(project(":type.thefarmingislands"))
implementation(project(":type.spidersden"))
implementation(project(":type.theend"))
implementation(project(":type.goldmine"))
implementation(project(":type.deepcaverns"))
implementation(project(":type.dwarvenmines"))
Expand Down
2 changes: 1 addition & 1 deletion loader/src/main/java/net/swofty/loader/Hypixel.java
Original file line number Diff line number Diff line change
Expand Up @@ -357,7 +357,7 @@ ToProxyChannels.PROXY_IS_ONLINE, new JSONObject(), (response) -> {
Logger.error("Proxy did not respond to alive check. Shutting down...");
System.exit(0);
}
}, TaskSchedule.tick(4), TaskSchedule.stop());
}, TaskSchedule.tick(20), TaskSchedule.stop());

return TaskSchedule.seconds(1);
}, ExecutionType.TICK_END);
Expand Down
4 changes: 3 additions & 1 deletion settings.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,8 @@ include(":pvp")

include(":type.prototypelobby")
include(":type.thefarmingislands")
include("type.spidersden")
include("type.theend")
include(":type.goldmine")
include(":type.deepcaverns")
include(":type.dwarvenmines")
Expand All @@ -34,4 +36,4 @@ include(":service.datamutex")
include(":service.party")
include(":service.orchestrator")
include(":service.darkauction")
include(":anticheat")
include(":anticheat")
Original file line number Diff line number Diff line change
Expand Up @@ -136,7 +136,8 @@ public LoaderValues getLoaderValues() {
return new LoaderValues(
(type) -> switch (type) {
case SKYBLOCK_THE_FARMING_ISLANDS -> new Pos(74, 72, -180, 35, 0);
case SKYBLOCK_GOLD_MINE -> new Pos(-9.5, 64, -228, 0, 0); // TODO: UPDATE TO PROPER POSITION
case SKYBLOCK_SPIDERS_DEN -> new Pos(-159.5, 73, -158.5, -45, 0);
case SKYBLOCK_GOLD_MINE -> new Pos(-9.5, 64, -228.5, 0, 0);
case SKYBLOCK_DUNGEON_HUB -> new Pos(-44, 88, 11.5, 0, 0);
default -> new Pos(-2.5, 72.5, -69.5, 180, 0);
}, // Spawn position
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -291,7 +291,7 @@ public void initialize(MinecraftServer server) {
MinecraftServer.getDimensionTypeRegistry().register(
Key.key("skyblock:island"),
DimensionType.builder()
.ambientLight(2)
.ambientLight(1)
.build());
SkyBlockIsland.runVacantLoop(MinecraftServer.getSchedulerManager());

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -36,15 +36,15 @@ public enum LaunchPads {
boolean hasRequirement = player.getSkills().getCurrentLevel(SkillCategories.FARMING) >= 5;
if (!hasRequirement) {
return PlayerHolograms.ExternalPlayerHologram.builder()
.pos(new Pos(80, 73.3, -184.5))
.pos(new Pos(79.5, 73.3, -184.5))
.player(player)
.text(new String[]{"§bTravel To:", "§aThe Farming Islands", "§cRequires Farming Level 5"})
.text(new String[]{"§bTravel to:", "§aThe Farming Islands", "§cRequires Farming Level 5"})
.build();
} else {
return PlayerHolograms.ExternalPlayerHologram.builder()
.pos(new Pos(80, 73.3, -184.5))
.pos(new Pos(79.5, 73.3, -184.5))
.player(player)
.text(new String[]{"§bTravel To:", "§aThe Farming Islands"})
.text(new String[]{"§bTravel to:", "§aThe Farming Islands"})
.build();
}
}
Expand All @@ -61,7 +61,89 @@ public enum LaunchPads {
(player) -> PlayerHolograms.ExternalPlayerHologram.builder()
.pos(new Pos(111.5, 71.7, -202.5))
.player(player)
.text(new String[]{"§bTravel To:", "§aThe Village"})
.text(new String[]{"§bTravel to:", "§aThe Village"})
.build()
),

GRAVEYARD_TO_SPIDERS_DEN(
getSlimeBlocksNear(new Pos(-162, 73, -161)),
ServerType.SKYBLOCK_HUB,
ServerType.SKYBLOCK_SPIDERS_DEN,
new Pos(-202.5, 83, -233.5),
(player) -> player.sendTo(ServerType.SKYBLOCK_SPIDERS_DEN),
(player) -> player.getSkills().getCurrentLevel(SkillCategories.COMBAT) >= 1,
"§cYou must be at least Combat Level I to join this island!",
(player) -> {
boolean hasRequirement = player.getSkills().getCurrentLevel(SkillCategories.COMBAT) >= 1;
if (!hasRequirement) {
return PlayerHolograms.ExternalPlayerHologram.builder()
.pos(new Pos(-162.5, 75, -161.5))
.player(player)
.text(new String[]{"§bTravel to:", "§aSpider's Den", "§cRequires Combat Level 1"})
.build();
} else {
return PlayerHolograms.ExternalPlayerHologram.builder()
.pos(new Pos(-162.5, 75, -161.5))
.player(player)
.text(new String[]{"§bTravel to:", "§aSpider's Den"})
.build();
}
}
),

SPIDERS_DEN_TO_GRAVEYARD(
getSlimeBlocksNear(new Pos(-197, 83, -228)),
ServerType.SKYBLOCK_SPIDERS_DEN,
ServerType.SKYBLOCK_HUB,
new Pos(-159.5, 73, -158.5),
(player) -> player.sendTo(ServerType.SKYBLOCK_HUB),
(player) -> true,
"",
(player) -> PlayerHolograms.ExternalPlayerHologram.builder()
.pos(new Pos(-197.5, 83, -228.5))
.player(player)
.text(new String[]{"§bTravel to:", "§aHub Island"})
.build()
),

SPIDERS_DEN_TO_THE_END(
getSlimeBlocksNear(new Pos(-383.5, 119, -261)),
ServerType.SKYBLOCK_SPIDERS_DEN,
ServerType.SKYBLOCK_THE_END,
new Pos(-503, 101, -275),
(player) -> player.sendTo(ServerType.SKYBLOCK_THE_END),
(player) -> player.getSkills().getCurrentLevel(SkillCategories.COMBAT) >= 12,
"§cYou must be at least Combat Level XII to join this island!",
(player) -> {
boolean hasRequirement = player.getSkills().getCurrentLevel(SkillCategories.COMBAT) >= 12;
if (!hasRequirement) {
return PlayerHolograms.ExternalPlayerHologram.builder()
.pos(new Pos(-383, 120, -261))
.player(player)
.text(new String[]{"§bTravel to:", "§aThe End", "§cRequires Combat Level 12"})
.build();
} else {
return PlayerHolograms.ExternalPlayerHologram.builder()
.pos(new Pos(-383, 120, -261))
.player(player)
.text(new String[]{"§bTravel to:", "§aThe End"})
.build();
}
}
),

THE_END_TO_SPIDERS_DEN(
getSlimeBlocksNear(new Pos(-197, 83, -228)),
ServerType.SKYBLOCK_THE_END,
ServerType.SKYBLOCK_SPIDERS_DEN,
new Pos(-378, 118.5, -261),
(player) -> player.sendTo(ServerType.SKYBLOCK_SPIDERS_DEN),
(player) -> true,
"",
(player) -> PlayerHolograms.ExternalPlayerHologram.builder()
.pos(new Pos(-495, 102, -275))
.player(player)
.text(new String[]{"§bTravel to:", "§aSpider's Den"})
.build()
),

Expand All @@ -77,15 +159,15 @@ public enum LaunchPads {
boolean hasRequirement = player.getSkills().getCurrentLevel(SkillCategories.MINING) >= 1;
if (!hasRequirement) {
return PlayerHolograms.ExternalPlayerHologram.builder()
.pos(new Pos(-9.5, 64.7, -230.5))
.pos(new Pos(-9.5, 64.7, -231.5))
.player(player)
.text(new String[]{"§bTravel To:", "§aGold Mine", "§cRequires Mining Level 1"})
.text(new String[]{"§bTravel to:", "§aGold Mine", "§cRequires Mining Level 1"})
.build();
} else {
return PlayerHolograms.ExternalPlayerHologram.builder()
.pos(new Pos(-9.5, 64.7, -230.5))
.pos(new Pos(-9.5, 64.7, -231.5))
.player(player)
.text(new String[]{"§bTravel To:", "§aGold Mine"})
.text(new String[]{"§bTravel to:", "§aGold Mine"})
.build();
}
}
Expand All @@ -100,9 +182,9 @@ public enum LaunchPads {
(player) -> true,
"",
(player) -> PlayerHolograms.ExternalPlayerHologram.builder()
.pos(new Pos(-5, 73.3, -269))
.pos(new Pos(-4.5, 73.3, -268.5))
.player(player)
.text(new String[]{"§bTravel To:", "§aThe Village"})
.text(new String[]{"§bTravel to:", "§aThe Village"})
.build()
),

Expand All @@ -117,7 +199,7 @@ public enum LaunchPads {
(player) -> PlayerHolograms.ExternalPlayerHologram.builder()
.pos(new Pos(-7, 69, -396))
.player(player)
.text(new String[]{"§bTravel To:", "§aDeep Caverns"})
.text(new String[]{"§bTravel to:", "§aDeep Caverns"})
.build()
),

Expand All @@ -132,7 +214,7 @@ public enum LaunchPads {
(player) -> PlayerHolograms.ExternalPlayerHologram.builder()
.pos(new Pos(4, 158.5, 89))
.player(player)
.text(new String[]{"§bTravel To:", "§aGold Mine"})
.text(new String[]{"§bTravel to:", "§aGold Mine"})
.build()
);

Expand Down
27 changes: 27 additions & 0 deletions type.spidersden/build.gradle.kts
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
plugins {
java
}

group = "net.swofty"
version = "3.0"

java {
sourceCompatibility = JavaVersion.VERSION_25
targetCompatibility = JavaVersion.VERSION_25
toolchain {
languageVersion.set(JavaLanguageVersion.of(25))
}
}

dependencies {
implementation(project(":type.skyblockgeneric"))
implementation(project(":type.generic"))
implementation(project(":commons"))
implementation(project(":proxy.api"))
compileOnly("net.minestom:minestom:2025.12.20c-1.21.11") {
exclude(group = "org.jboss.shrinkwrap.resolver", module = "shrinkwrap-resolver-depchain")
}
implementation("org.tinylog:tinylog-api:2.7.0")
implementation("org.tinylog:tinylog-impl:2.7.0")
implementation("org.joml:joml:1.10.8")
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,107 @@
package net.swofty.type.spidersden;

import net.minestom.server.MinecraftServer;
import net.minestom.server.coordinate.Pos;
import net.swofty.commons.CustomWorlds;
import net.swofty.commons.ServerType;
import net.swofty.commons.ServiceType;
import net.swofty.proxyapi.redis.ProxyToClient;
import net.swofty.proxyapi.redis.ServiceToClient;
import net.swofty.type.generic.SkyBlockTypeLoader;
import net.swofty.type.generic.entity.npc.HypixelNPC;
import net.swofty.type.generic.event.HypixelEventClass;
import net.swofty.type.generic.tab.TablistManager;
import net.swofty.type.generic.tab.TablistModule;
import net.swofty.type.skyblockgeneric.SkyBlockGenericLoader;
import net.swofty.type.skyblockgeneric.tabmodules.AccountInformationModule;
import net.swofty.type.skyblockgeneric.tabmodules.SkyBlockPlayersOnlineModule;
import net.swofty.type.spidersden.tab.SpidersDenServerModule;
import org.jetbrains.annotations.Nullable;
import org.tinylog.Logger;

import java.util.ArrayList;
import java.util.List;
import java.util.stream.Collectors;

public class TypeSpidersDenLoader implements SkyBlockTypeLoader {
@Override
public ServerType getType() {
return ServerType.SKYBLOCK_SPIDERS_DEN;
}

@Override
public void onInitialize(MinecraftServer server) {
Logger.info("TypeSpidersDenLoader initialized!");
}

@Override
public void afterInitialize(MinecraftServer server) {

}

@Override
public LoaderValues getLoaderValues() {
return new LoaderValues(
(type) -> switch (type) {
case SKYBLOCK_THE_END -> new Pos(-378, 118.5, -261, -90, 0);
default -> new Pos(-202.5, 83, -233.5, 135, 0);
}, // Spawn position
true // Announce death messages
);
}

public TablistManager getTablistManager() {
return new TablistManager() {
@Override
public List<TablistModule> getModules() {
return new ArrayList<>(List.of(
new SkyBlockPlayersOnlineModule(1),
new SkyBlockPlayersOnlineModule(2),
new SpidersDenServerModule(),
new AccountInformationModule()
));
}
};
}

@Override
public List<HypixelEventClass> getTraditionalEvents() {
return SkyBlockGenericLoader.loopThroughPackage(
"net.swofty.type.spidersden.events",
HypixelEventClass.class
).collect(Collectors.toList());
}

@Override
public List<HypixelEventClass> getCustomEvents() {
return new ArrayList<>();
}

@Override
public List<HypixelNPC> getNPCs() {
return new ArrayList<>(SkyBlockGenericLoader.loopThroughPackage(
"net.swofty.type.spidersden.npcs",
HypixelNPC.class
).toList());
}

@Override
public List<ServiceToClient> getServiceRedisListeners() {
return List.of();
}

@Override
public List<ProxyToClient> getProxyRedisListeners() {
return List.of();
}

@Override
public List<ServiceType> getRequiredServices() {
return new ArrayList<>(List.of(ServiceType.DATA_MUTEX));
}

@Override
public @Nullable CustomWorlds getMainInstance() {
return CustomWorlds.SKYBLOCK_SPIDERS_DEN;
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
package net.swofty.type.spidersden.events;

import lombok.SneakyThrows;
import net.minestom.server.event.player.AsyncPlayerConfigurationEvent;
import net.swofty.type.generic.HypixelConst;
import net.swofty.type.generic.event.EventNodes;
import net.swofty.type.generic.event.HypixelEvent;
import net.swofty.type.generic.event.HypixelEventClass;
import net.swofty.type.skyblockgeneric.user.SkyBlockPlayer;

public class ActionPlayerJoin implements HypixelEventClass {

@SneakyThrows
@HypixelEvent(node = EventNodes.PLAYER, requireDataLoaded = false)
public void run(AsyncPlayerConfigurationEvent event) {

final SkyBlockPlayer player = (SkyBlockPlayer) event.getPlayer();

event.setSpawningInstance(HypixelConst.getInstanceContainer());
player.setRespawnPoint(HypixelConst.getTypeLoader()
.getLoaderValues()
.spawnPosition()
.apply(player.getOriginServer())
);
}
}
Loading
Loading