├── .editorconfig ├── .github ├── ISSUE_TEMPLATE │ ├── bug_report.yml │ ├── config.yml │ ├── custom.md │ └── feature_request.yml └── workflows │ ├── build-remote.yml │ ├── build.yml │ ├── dispatch-preview.yml │ ├── pull-request.yml │ └── sync_with_upstream.yml ├── .gitignore ├── .gitmodules ├── .idea └── copyright │ ├── Geyser.xml │ └── profiles_settings.xml ├── CONTRIBUTING.md ├── LICENSE ├── README.md ├── ap ├── build.gradle.kts └── src │ └── main │ ├── java │ └── org │ │ └── geysermc │ │ └── geyser │ │ └── processor │ │ ├── BlockEntityProcessor.java │ │ ├── ClassProcessor.java │ │ ├── CollisionRemapperProcessor.java │ │ ├── PacketTranslatorProcessor.java │ │ └── SoundHandlerProcessor.java │ └── resources │ └── META-INF │ └── services │ └── javax.annotation.processing.Processor ├── api ├── build.gradle.kts └── src │ └── main │ ├── java-templates │ └── org │ │ └── geysermc │ │ └── geyser │ │ └── api │ │ └── BuildData.java │ └── java │ └── org │ └── geysermc │ └── geyser │ └── api │ ├── GeyserApi.java │ ├── bedrock │ └── camera │ │ ├── CameraData.java │ │ ├── CameraEaseType.java │ │ ├── CameraFade.java │ │ ├── CameraPerspective.java │ │ ├── CameraPosition.java │ │ ├── CameraShake.java │ │ └── GuiElement.java │ ├── block │ └── custom │ │ ├── CustomBlockData.java │ │ ├── CustomBlockPermutation.java │ │ ├── CustomBlockState.java │ │ ├── NonVanillaCustomBlockData.java │ │ ├── component │ │ ├── BoxComponent.java │ │ ├── CustomBlockComponents.java │ │ ├── GeometryComponent.java │ │ ├── MaterialInstance.java │ │ ├── PlacementConditions.java │ │ └── TransformationComponent.java │ │ ├── nonvanilla │ │ ├── JavaBlockState.java │ │ └── JavaBoundingBox.java │ │ └── property │ │ ├── CustomBlockProperty.java │ │ └── PropertyType.java │ ├── command │ ├── Command.java │ ├── CommandExecutor.java │ └── CommandSource.java │ ├── connection │ └── GeyserConnection.java │ ├── entity │ ├── EntityData.java │ └── type │ │ ├── GeyserEntity.java │ │ └── player │ │ └── GeyserPlayerEntity.java │ ├── event │ ├── EventBus.java │ ├── EventRegistrar.java │ ├── EventSubscriber.java │ ├── ExtensionEventBus.java │ ├── ExtensionEventSubscriber.java │ ├── bedrock │ │ ├── ClientEmoteEvent.java │ │ ├── SessionDisconnectEvent.java │ │ ├── SessionInitializeEvent.java │ │ ├── SessionJoinEvent.java │ │ ├── SessionLoadResourcePacksEvent.java │ │ ├── SessionLoginEvent.java │ │ └── SessionSkinApplyEvent.java │ ├── connection │ │ ├── ConnectionEvent.java │ │ ├── ConnectionRequestEvent.java │ │ └── GeyserBedrockPingEvent.java │ ├── downstream │ │ └── ServerDefineCommandsEvent.java │ ├── java │ │ ├── ServerDefineCommandsEvent.java │ │ └── ServerTransferEvent.java │ └── lifecycle │ │ ├── GeyserDefineCommandsEvent.java │ │ ├── GeyserDefineCustomBlocksEvent.java │ │ ├── GeyserDefineCustomItemsEvent.java │ │ ├── GeyserDefineCustomSkullsEvent.java │ │ ├── GeyserDefineResourcePacksEvent.java │ │ ├── GeyserLoadResourcePacksEvent.java │ │ ├── GeyserPostInitializeEvent.java │ │ ├── GeyserPostReloadEvent.java │ │ ├── GeyserPreInitializeEvent.java │ │ ├── GeyserPreReloadEvent.java │ │ ├── GeyserRegisterPermissionCheckersEvent.java │ │ ├── GeyserRegisterPermissionsEvent.java │ │ └── GeyserShutdownEvent.java │ ├── extension │ ├── Extension.java │ ├── ExtensionDescription.java │ ├── ExtensionLoader.java │ ├── ExtensionLogger.java │ ├── ExtensionManager.java │ └── exception │ │ ├── InvalidDescriptionException.java │ │ └── InvalidExtensionException.java │ ├── item │ └── custom │ │ ├── CustomItemData.java │ │ ├── CustomItemOptions.java │ │ ├── CustomRenderOffsets.java │ │ └── NonVanillaCustomItemData.java │ ├── network │ ├── AuthType.java │ ├── BedrockListener.java │ └── RemoteServer.java │ ├── pack │ ├── PackCodec.java │ ├── PathPackCodec.java │ ├── ResourcePack.java │ ├── ResourcePackManifest.java │ ├── UrlPackCodec.java │ ├── exception │ │ └── ResourcePackException.java │ └── option │ │ ├── PriorityOption.java │ │ ├── ResourcePackOption.java │ │ ├── SubpackOption.java │ │ └── UrlFallbackOption.java │ ├── permission │ └── PermissionChecker.java │ ├── skin │ ├── Cape.java │ ├── Skin.java │ ├── SkinData.java │ └── SkinGeometry.java │ └── util │ ├── CreativeCategory.java │ ├── MinecraftVersion.java │ ├── PlatformType.java │ └── TriState.java ├── bootstrap ├── bungeecord │ ├── build.gradle.kts │ └── src │ │ └── main │ │ ├── java │ │ └── org │ │ │ └── geysermc │ │ │ └── geyser │ │ │ └── platform │ │ │ └── bungeecord │ │ │ ├── GeyserBungeeCompressionDisabler.java │ │ │ ├── GeyserBungeeConfiguration.java │ │ │ ├── GeyserBungeeDumpInfo.java │ │ │ ├── GeyserBungeeInjector.java │ │ │ ├── GeyserBungeeLogger.java │ │ │ ├── GeyserBungeeMain.java │ │ │ ├── GeyserBungeePingPassthrough.java │ │ │ ├── GeyserBungeePlugin.java │ │ │ ├── GeyserBungeeUpdateListener.java │ │ │ └── command │ │ │ └── BungeeCommandSource.java │ │ └── resources │ │ └── bungee.yml ├── mod │ ├── build.gradle.kts │ ├── fabric │ │ ├── build.gradle.kts │ │ ├── gradle.properties │ │ └── src │ │ │ └── main │ │ │ ├── java │ │ │ └── org │ │ │ │ └── geysermc │ │ │ │ └── geyser │ │ │ │ └── platform │ │ │ │ └── fabric │ │ │ │ ├── GeyserFabricBootstrap.java │ │ │ │ ├── GeyserFabricDumpInfo.java │ │ │ │ ├── GeyserFabricMain.java │ │ │ │ └── GeyserFabricPlatform.java │ │ │ └── resources │ │ │ └── fabric.mod.json │ ├── neoforge │ │ ├── build.gradle.kts │ │ ├── gradle.properties │ │ └── src │ │ │ └── main │ │ │ ├── java │ │ │ └── org │ │ │ │ └── geysermc │ │ │ │ └── geyser │ │ │ │ └── platform │ │ │ │ └── neoforge │ │ │ │ ├── GeyserNeoForgeBootstrap.java │ │ │ │ ├── GeyserNeoForgeCommandRegistry.java │ │ │ │ ├── GeyserNeoForgeDumpInfo.java │ │ │ │ ├── GeyserNeoForgeMain.java │ │ │ │ ├── GeyserNeoForgePlatform.java │ │ │ │ ├── ModConstants.java │ │ │ │ ├── PermissionUtils.java │ │ │ │ └── mixin │ │ │ │ └── PermissionNodeMixin.java │ │ │ └── resources │ │ │ ├── META-INF │ │ │ └── neoforge.mods.toml │ │ │ └── geyser_neoforge.mixins.json │ └── src │ │ └── main │ │ ├── java │ │ └── org │ │ │ └── geysermc │ │ │ └── geyser │ │ │ └── platform │ │ │ └── mod │ │ │ ├── GeyserChannelGetter.java │ │ │ ├── GeyserModBootstrap.java │ │ │ ├── GeyserModCompressionDisabler.java │ │ │ ├── GeyserModConfiguration.java │ │ │ ├── GeyserModInjector.java │ │ │ ├── GeyserModLogger.java │ │ │ ├── GeyserModUpdateListener.java │ │ │ ├── GeyserServerPortGetter.java │ │ │ ├── ModPingPassthrough.java │ │ │ ├── command │ │ │ └── ModCommandSource.java │ │ │ ├── mixin │ │ │ ├── client │ │ │ │ └── IntegratedServerMixin.java │ │ │ └── server │ │ │ │ ├── BlockPlaceMixin.java │ │ │ │ ├── DedicatedServerMixin.java │ │ │ │ ├── PistonBaseBlockMixin.java │ │ │ │ └── ServerConnectionListenerMixin.java │ │ │ ├── platform │ │ │ └── GeyserModPlatform.java │ │ │ └── world │ │ │ └── GeyserModWorldManager.java │ │ └── resources │ │ └── geyser.mixins.json ├── spigot │ ├── build.gradle.kts │ └── src │ │ └── main │ │ ├── java │ │ └── org │ │ │ └── geysermc │ │ │ └── geyser │ │ │ └── platform │ │ │ └── spigot │ │ │ ├── GeyserPaperLogger.java │ │ │ ├── GeyserPaperPingPassthrough.java │ │ │ ├── GeyserSpigotCompressionDisabler.java │ │ │ ├── GeyserSpigotConfiguration.java │ │ │ ├── GeyserSpigotDumpInfo.java │ │ │ ├── GeyserSpigotInjector.java │ │ │ ├── GeyserSpigotLogger.java │ │ │ ├── GeyserSpigotMain.java │ │ │ ├── GeyserSpigotPingPassthrough.java │ │ │ ├── GeyserSpigotPlugin.java │ │ │ ├── GeyserSpigotUpdateListener.java │ │ │ ├── GeyserSpigotVersionChecker.java │ │ │ ├── PaperAdventure.java │ │ │ ├── ReflectedNames.java │ │ │ ├── command │ │ │ ├── SpigotCommandRegistry.java │ │ │ └── SpigotCommandSource.java │ │ │ └── world │ │ │ ├── GeyserPistonListener.java │ │ │ ├── GeyserSpigotBlockPlaceListener.java │ │ │ └── manager │ │ │ ├── GeyserSpigotLegacyNativeWorldManager.java │ │ │ ├── GeyserSpigotNativeWorldManager.java │ │ │ └── GeyserSpigotWorldManager.java │ │ └── resources │ │ └── plugin.yml ├── standalone │ ├── build.gradle.kts │ └── src │ │ └── main │ │ ├── java │ │ └── org │ │ │ └── geysermc │ │ │ └── geyser │ │ │ └── platform │ │ │ └── standalone │ │ │ ├── GeyserStandaloneBootstrap.java │ │ │ ├── GeyserStandaloneConfiguration.java │ │ │ ├── GeyserStandaloneDumpInfo.java │ │ │ ├── GeyserStandaloneLogger.java │ │ │ └── gui │ │ │ ├── ANSIColor.java │ │ │ ├── ColorPane.java │ │ │ ├── GeyserStandaloneGUI.java │ │ │ └── GraphPanel.java │ │ └── resources │ │ └── log4j2.xml ├── velocity │ ├── build.gradle.kts │ └── src │ │ └── main │ │ └── java │ │ └── org │ │ └── geysermc │ │ └── geyser │ │ └── platform │ │ └── velocity │ │ ├── GeyserVelocityCompressionDisabler.java │ │ ├── GeyserVelocityConfiguration.java │ │ ├── GeyserVelocityDumpInfo.java │ │ ├── GeyserVelocityInjector.java │ │ ├── GeyserVelocityLogger.java │ │ ├── GeyserVelocityMain.java │ │ ├── GeyserVelocityPingPassthrough.java │ │ ├── GeyserVelocityPlugin.java │ │ ├── GeyserVelocityUpdateListener.java │ │ └── command │ │ └── VelocityCommandSource.java └── viaproxy │ ├── build.gradle.kts │ └── src │ └── main │ ├── java │ └── org │ │ └── geysermc │ │ └── geyser │ │ └── platform │ │ └── viaproxy │ │ ├── GeyserViaProxyConfiguration.java │ │ ├── GeyserViaProxyDumpInfo.java │ │ ├── GeyserViaProxyLogger.java │ │ ├── GeyserViaProxyMain.java │ │ ├── GeyserViaProxyPlugin.java │ │ └── listener │ │ └── GeyserServerTransferListener.java │ └── resources │ └── viaproxy.yml ├── build-logic ├── build.gradle.kts ├── settings.gradle.kts └── src │ └── main │ └── kotlin │ ├── LibsAccessor.kt │ ├── extensions.kt │ ├── geyser.base-conventions.gradle.kts │ ├── geyser.modded-conventions.gradle.kts │ ├── geyser.modrinth-uploading-conventions.gradle.kts │ ├── geyser.platform-conventions.gradle.kts │ ├── geyser.publish-conventions.gradle.kts │ └── geyser.shadow-conventions.gradle.kts ├── build.gradle.kts ├── common ├── build.gradle.kts └── src │ └── main │ └── java │ └── org │ └── geysermc │ └── floodgate │ ├── crypto │ ├── AesCipher.java │ ├── AesKeyProducer.java │ ├── Base64Topping.java │ ├── FloodgateCipher.java │ ├── KeyProducer.java │ └── Topping.java │ ├── news │ ├── NewsItem.java │ ├── NewsItemAction.java │ ├── NewsItemMessage.java │ ├── NewsType.java │ └── data │ │ ├── AnnouncementData.java │ │ ├── BuildSpecificData.java │ │ ├── CheckAfterData.java │ │ ├── ConfigSpecificData.java │ │ └── ItemData.java │ ├── pluginmessage │ └── PluginMessageChannels.java │ └── util │ ├── BedrockData.java │ ├── DeviceOs.java │ ├── FloodgateInfoHolder.java │ ├── InputMode.java │ ├── InvalidFormatException.java │ ├── LinkedPlayer.java │ ├── UiProfile.java │ └── WebsocketEventType.java ├── core ├── build.gradle.kts └── src │ ├── main │ ├── java-templates │ │ └── org │ │ │ └── geysermc │ │ │ └── geyser │ │ │ └── BuildData.java │ ├── java │ │ └── org │ │ │ └── geysermc │ │ │ └── geyser │ │ │ ├── Constants.java │ │ │ ├── FloodgateKeyLoader.java │ │ │ ├── GeyserBootstrap.java │ │ │ ├── GeyserImpl.java │ │ │ ├── GeyserLogger.java │ │ │ ├── GeyserMain.java │ │ │ ├── Permissions.java │ │ │ ├── command │ │ │ ├── CommandRegistry.java │ │ │ ├── CommandSourceConverter.java │ │ │ ├── ExceptionHandlers.java │ │ │ ├── GeyserCommand.java │ │ │ ├── GeyserCommandSource.java │ │ │ ├── GeyserPermission.java │ │ │ ├── defaults │ │ │ │ ├── AdvancedTooltipsCommand.java │ │ │ │ ├── AdvancementsCommand.java │ │ │ │ ├── ConnectionTestCommand.java │ │ │ │ ├── DumpCommand.java │ │ │ │ ├── ExtensionsCommand.java │ │ │ │ ├── HelpCommand.java │ │ │ │ ├── ListCommand.java │ │ │ │ ├── OffhandCommand.java │ │ │ │ ├── PingCommand.java │ │ │ │ ├── ReloadCommand.java │ │ │ │ ├── SettingsCommand.java │ │ │ │ ├── StatisticsCommand.java │ │ │ │ ├── StopCommand.java │ │ │ │ └── VersionCommand.java │ │ │ └── standalone │ │ │ │ ├── PermissionConfiguration.java │ │ │ │ └── StandaloneCloudCommandManager.java │ │ │ ├── configuration │ │ │ ├── EmoteOffhandWorkaroundOption.java │ │ │ ├── GeyserConfiguration.java │ │ │ ├── GeyserCustomSkullConfiguration.java │ │ │ └── GeyserJacksonConfiguration.java │ │ │ ├── dump │ │ │ ├── BootstrapDumpInfo.java │ │ │ └── DumpInfo.java │ │ │ ├── entity │ │ │ ├── EntityDefinition.java │ │ │ ├── EntityDefinitions.java │ │ │ ├── GeyserDirtyMetadata.java │ │ │ ├── GeyserEntityData.java │ │ │ ├── attribute │ │ │ │ └── GeyserAttributeType.java │ │ │ ├── factory │ │ │ │ └── EntityFactory.java │ │ │ ├── properties │ │ │ │ ├── GeyserEntityProperties.java │ │ │ │ ├── GeyserEntityPropertyManager.java │ │ │ │ ├── VanillaEntityProperties.java │ │ │ │ └── type │ │ │ │ │ ├── BooleanProperty.java │ │ │ │ │ ├── EnumProperty.java │ │ │ │ │ ├── FloatProperty.java │ │ │ │ │ ├── IntProperty.java │ │ │ │ │ └── PropertyType.java │ │ │ ├── type │ │ │ │ ├── AbstractArrowEntity.java │ │ │ │ ├── AbstractWindChargeEntity.java │ │ │ │ ├── AreaEffectCloudEntity.java │ │ │ │ ├── ArrowEntity.java │ │ │ │ ├── BoatEntity.java │ │ │ │ ├── ChestBoatEntity.java │ │ │ │ ├── CommandBlockMinecartEntity.java │ │ │ │ ├── DefaultBlockMinecartEntity.java │ │ │ │ ├── DisplayBaseEntity.java │ │ │ │ ├── EnderCrystalEntity.java │ │ │ │ ├── EnderEyeEntity.java │ │ │ │ ├── Entity.java │ │ │ │ ├── EvokerFangsEntity.java │ │ │ │ ├── ExpOrbEntity.java │ │ │ │ ├── FallingBlockEntity.java │ │ │ │ ├── FireballEntity.java │ │ │ │ ├── FireworkEntity.java │ │ │ │ ├── FishingHookEntity.java │ │ │ │ ├── FurnaceMinecartEntity.java │ │ │ │ ├── InteractionEntity.java │ │ │ │ ├── ItemEntity.java │ │ │ │ ├── ItemFrameEntity.java │ │ │ │ ├── LeashKnotEntity.java │ │ │ │ ├── Leashable.java │ │ │ │ ├── LightningEntity.java │ │ │ │ ├── LivingEntity.java │ │ │ │ ├── MinecartEntity.java │ │ │ │ ├── PaintingEntity.java │ │ │ │ ├── SpawnerMinecartEntity.java │ │ │ │ ├── TNTEntity.java │ │ │ │ ├── TextDisplayEntity.java │ │ │ │ ├── ThrowableEggEntity.java │ │ │ │ ├── ThrowableEntity.java │ │ │ │ ├── ThrowableItemEntity.java │ │ │ │ ├── ThrownPotionEntity.java │ │ │ │ ├── Tickable.java │ │ │ │ ├── TridentEntity.java │ │ │ │ ├── WitherSkullEntity.java │ │ │ │ ├── living │ │ │ │ │ ├── AbstractFishEntity.java │ │ │ │ │ ├── AgeableEntity.java │ │ │ │ │ ├── AgeableWaterEntity.java │ │ │ │ │ ├── AllayEntity.java │ │ │ │ │ ├── AmbientEntity.java │ │ │ │ │ ├── ArmorStandEntity.java │ │ │ │ │ ├── BatEntity.java │ │ │ │ │ ├── CreatureEntity.java │ │ │ │ │ ├── DolphinEntity.java │ │ │ │ │ ├── FlyingEntity.java │ │ │ │ │ ├── GlowSquidEntity.java │ │ │ │ │ ├── GolemEntity.java │ │ │ │ │ ├── IronGolemEntity.java │ │ │ │ │ ├── MagmaCubeEntity.java │ │ │ │ │ ├── MobEntity.java │ │ │ │ │ ├── SlimeEntity.java │ │ │ │ │ ├── SnowGolemEntity.java │ │ │ │ │ ├── SquidEntity.java │ │ │ │ │ ├── TadpoleEntity.java │ │ │ │ │ ├── WaterEntity.java │ │ │ │ │ ├── animal │ │ │ │ │ │ ├── AnimalEntity.java │ │ │ │ │ │ ├── ArmadilloEntity.java │ │ │ │ │ │ ├── AxolotlEntity.java │ │ │ │ │ │ ├── BeeEntity.java │ │ │ │ │ │ ├── FoxEntity.java │ │ │ │ │ │ ├── FrogEntity.java │ │ │ │ │ │ ├── GoatEntity.java │ │ │ │ │ │ ├── HoglinEntity.java │ │ │ │ │ │ ├── MooshroomEntity.java │ │ │ │ │ │ ├── OcelotEntity.java │ │ │ │ │ │ ├── PandaEntity.java │ │ │ │ │ │ ├── PolarBearEntity.java │ │ │ │ │ │ ├── PufferFishEntity.java │ │ │ │ │ │ ├── RabbitEntity.java │ │ │ │ │ │ ├── SheepEntity.java │ │ │ │ │ │ ├── SnifferEntity.java │ │ │ │ │ │ ├── StriderEntity.java │ │ │ │ │ │ ├── TropicalFishEntity.java │ │ │ │ │ │ ├── TurtleEntity.java │ │ │ │ │ │ ├── VariantHolder.java │ │ │ │ │ │ ├── VariantIntHolder.java │ │ │ │ │ │ ├── farm │ │ │ │ │ │ │ ├── ChickenEntity.java │ │ │ │ │ │ │ ├── CowEntity.java │ │ │ │ │ │ │ ├── PigEntity.java │ │ │ │ │ │ │ └── TemperatureVariantAnimal.java │ │ │ │ │ │ ├── horse │ │ │ │ │ │ │ ├── AbstractHorseEntity.java │ │ │ │ │ │ │ ├── CamelEntity.java │ │ │ │ │ │ │ ├── ChestedHorseEntity.java │ │ │ │ │ │ │ ├── HorseEntity.java │ │ │ │ │ │ │ ├── LlamaEntity.java │ │ │ │ │ │ │ ├── SkeletonHorseEntity.java │ │ │ │ │ │ │ ├── TraderLlamaEntity.java │ │ │ │ │ │ │ └── ZombieHorseEntity.java │ │ │ │ │ │ └── tameable │ │ │ │ │ │ │ ├── CatEntity.java │ │ │ │ │ │ │ ├── ParrotEntity.java │ │ │ │ │ │ │ ├── TameableEntity.java │ │ │ │ │ │ │ └── WolfEntity.java │ │ │ │ │ ├── merchant │ │ │ │ │ │ ├── AbstractMerchantEntity.java │ │ │ │ │ │ └── VillagerEntity.java │ │ │ │ │ └── monster │ │ │ │ │ │ ├── AbstractSkeletonEntity.java │ │ │ │ │ │ ├── BasePiglinEntity.java │ │ │ │ │ │ ├── BlazeEntity.java │ │ │ │ │ │ ├── BoggedEntity.java │ │ │ │ │ │ ├── BreezeEntity.java │ │ │ │ │ │ ├── CreakingEntity.java │ │ │ │ │ │ ├── CreeperEntity.java │ │ │ │ │ │ ├── ElderGuardianEntity.java │ │ │ │ │ │ ├── EnderDragonEntity.java │ │ │ │ │ │ ├── EnderDragonPartEntity.java │ │ │ │ │ │ ├── EndermanEntity.java │ │ │ │ │ │ ├── GhastEntity.java │ │ │ │ │ │ ├── GiantEntity.java │ │ │ │ │ │ ├── GuardianEntity.java │ │ │ │ │ │ ├── MonsterEntity.java │ │ │ │ │ │ ├── PhantomEntity.java │ │ │ │ │ │ ├── PiglinEntity.java │ │ │ │ │ │ ├── ShulkerEntity.java │ │ │ │ │ │ ├── SkeletonEntity.java │ │ │ │ │ │ ├── SpiderEntity.java │ │ │ │ │ │ ├── VexEntity.java │ │ │ │ │ │ ├── WardenEntity.java │ │ │ │ │ │ ├── WitherEntity.java │ │ │ │ │ │ ├── ZoglinEntity.java │ │ │ │ │ │ ├── ZombieEntity.java │ │ │ │ │ │ ├── ZombieVillagerEntity.java │ │ │ │ │ │ ├── ZombifiedPiglinEntity.java │ │ │ │ │ │ └── raid │ │ │ │ │ │ ├── AbstractIllagerEntity.java │ │ │ │ │ │ ├── PillagerEntity.java │ │ │ │ │ │ ├── RaidParticipantEntity.java │ │ │ │ │ │ ├── RavagerEntity.java │ │ │ │ │ │ ├── SpellcasterIllagerEntity.java │ │ │ │ │ │ └── VindicatorEntity.java │ │ │ │ └── player │ │ │ │ │ ├── PlayerEntity.java │ │ │ │ │ ├── SessionPlayerEntity.java │ │ │ │ │ └── SkullPlayerEntity.java │ │ │ └── vehicle │ │ │ │ ├── BoostableVehicleComponent.java │ │ │ │ ├── CamelVehicleComponent.java │ │ │ │ ├── ClientVehicle.java │ │ │ │ └── VehicleComponent.java │ │ │ ├── erosion │ │ │ ├── AbstractGeyserboundPacketHandler.java │ │ │ ├── ErosionCancellationException.java │ │ │ ├── GeyserErosionPacketSender.java │ │ │ ├── GeyserboundHandshakePacketHandler.java │ │ │ ├── GeyserboundPacketHandlerImpl.java │ │ │ └── UnixSocketClientListener.java │ │ │ ├── event │ │ │ ├── GeyserEventBus.java │ │ │ ├── GeyserEventRegistrar.java │ │ │ ├── GeyserEventSubscriber.java │ │ │ └── type │ │ │ │ ├── GeyserBedrockPingEventImpl.java │ │ │ │ ├── GeyserDefineCommandsEventImpl.java │ │ │ │ ├── GeyserDefineCustomItemsEventImpl.java │ │ │ │ ├── GeyserDefineResourcePacksEventImpl.java │ │ │ │ ├── SessionDisconnectEventImpl.java │ │ │ │ └── SessionLoadResourcePacksEventImpl.java │ │ │ ├── extension │ │ │ ├── GeyserExtensionClassLoader.java │ │ │ ├── GeyserExtensionContainer.java │ │ │ ├── GeyserExtensionDescription.java │ │ │ ├── GeyserExtensionLoader.java │ │ │ ├── GeyserExtensionLogger.java │ │ │ ├── GeyserExtensionManager.java │ │ │ ├── command │ │ │ │ └── GeyserExtensionCommand.java │ │ │ └── event │ │ │ │ └── GeyserExtensionEventBus.java │ │ │ ├── impl │ │ │ ├── MinecraftVersionImpl.java │ │ │ └── camera │ │ │ │ ├── CameraDefinitions.java │ │ │ │ ├── GeyserCameraData.java │ │ │ │ ├── GeyserCameraFade.java │ │ │ │ └── GeyserCameraPosition.java │ │ │ ├── inventory │ │ │ ├── AnvilContainer.java │ │ │ ├── BeaconContainer.java │ │ │ ├── BedrockContainerSlot.java │ │ │ ├── CartographyContainer.java │ │ │ ├── Container.java │ │ │ ├── CrafterContainer.java │ │ │ ├── EnchantingContainer.java │ │ │ ├── Generic3X3Container.java │ │ │ ├── Generic9X3Container.java │ │ │ ├── GeyserEnchantOption.java │ │ │ ├── GeyserItemStack.java │ │ │ ├── Inventory.java │ │ │ ├── InventoryHolder.java │ │ │ ├── LecternContainer.java │ │ │ ├── MerchantContainer.java │ │ │ ├── PlayerInventory.java │ │ │ ├── SlotType.java │ │ │ ├── StonecutterContainer.java │ │ │ ├── click │ │ │ │ ├── Click.java │ │ │ │ └── ClickPlan.java │ │ │ ├── holder │ │ │ │ ├── BlockInventoryHolder.java │ │ │ │ └── InventoryHolder.java │ │ │ ├── item │ │ │ │ ├── BannerPattern.java │ │ │ │ ├── BedrockEnchantment.java │ │ │ │ ├── DyeColor.java │ │ │ │ ├── GeyserInstrument.java │ │ │ │ ├── Potion.java │ │ │ │ └── StoredItemMappings.java │ │ │ ├── recipe │ │ │ │ ├── GeyserRecipe.java │ │ │ │ ├── GeyserShapedRecipe.java │ │ │ │ ├── GeyserShapelessRecipe.java │ │ │ │ ├── GeyserSmithingRecipe.java │ │ │ │ ├── GeyserStonecutterData.java │ │ │ │ └── TrimRecipe.java │ │ │ └── updater │ │ │ │ ├── AnvilInventoryUpdater.java │ │ │ │ ├── ChestInventoryUpdater.java │ │ │ │ ├── ContainerInventoryUpdater.java │ │ │ │ ├── CrafterInventoryUpdater.java │ │ │ │ ├── HorseInventoryUpdater.java │ │ │ │ ├── InventoryUpdater.java │ │ │ │ └── UIInventoryUpdater.java │ │ │ ├── item │ │ │ ├── ArmorMaterial.java │ │ │ ├── GeyserCustomItemData.java │ │ │ ├── GeyserCustomItemOptions.java │ │ │ ├── GeyserCustomMappingData.java │ │ │ ├── GeyserNonVanillaCustomItemData.java │ │ │ ├── Items.java │ │ │ ├── TooltipOptions.java │ │ │ ├── components │ │ │ │ ├── Rarity.java │ │ │ │ └── WearableSlot.java │ │ │ ├── enchantment │ │ │ │ ├── Enchantment.java │ │ │ │ └── EnchantmentComponent.java │ │ │ ├── exception │ │ │ │ └── InvalidCustomMappingsFileException.java │ │ │ ├── hashing │ │ │ │ ├── ComponentHasher.java │ │ │ │ ├── DataComponentHashers.java │ │ │ │ ├── MapBuilder.java │ │ │ │ ├── MapHasher.java │ │ │ │ ├── MinecraftHashEncoder.java │ │ │ │ ├── MinecraftHasher.java │ │ │ │ ├── RegistryHasher.java │ │ │ │ └── data │ │ │ │ │ ├── ConsumeEffectType.java │ │ │ │ │ ├── FireworkExplosionShape.java │ │ │ │ │ ├── ItemContainerSlot.java │ │ │ │ │ └── entity │ │ │ │ │ ├── AxolotlVariant.java │ │ │ │ │ ├── FoxVariant.java │ │ │ │ │ ├── HorseVariant.java │ │ │ │ │ ├── LlamaVariant.java │ │ │ │ │ ├── MooshroomVariant.java │ │ │ │ │ ├── ParrotVariant.java │ │ │ │ │ ├── RabbitVariant.java │ │ │ │ │ ├── SalmonVariant.java │ │ │ │ │ ├── TropicalFishPattern.java │ │ │ │ │ └── VillagerVariant.java │ │ │ └── type │ │ │ │ ├── ArmorItem.java │ │ │ │ ├── ArrowItem.java │ │ │ │ ├── AxolotlBucketItem.java │ │ │ │ ├── BannerItem.java │ │ │ │ ├── BedrockRequiresTagItem.java │ │ │ │ ├── BlockItem.java │ │ │ │ ├── BoatItem.java │ │ │ │ ├── CompassItem.java │ │ │ │ ├── CrossbowItem.java │ │ │ │ ├── DecoratedPotItem.java │ │ │ │ ├── DyeItem.java │ │ │ │ ├── DyeableArmorItem.java │ │ │ │ ├── EnchantedBookItem.java │ │ │ │ ├── FilledMapItem.java │ │ │ │ ├── FireworkRocketItem.java │ │ │ │ ├── FireworkStarItem.java │ │ │ │ ├── FishingRodItem.java │ │ │ │ ├── GoatHornItem.java │ │ │ │ ├── Item.java │ │ │ │ ├── LightItem.java │ │ │ │ ├── MapItem.java │ │ │ │ ├── OminousBottleItem.java │ │ │ │ ├── PlayerHeadItem.java │ │ │ │ ├── PotionItem.java │ │ │ │ ├── ShieldItem.java │ │ │ │ ├── ShulkerBoxItem.java │ │ │ │ ├── SpawnEggItem.java │ │ │ │ ├── TippedArrowItem.java │ │ │ │ ├── TropicalFishBucketItem.java │ │ │ │ ├── WolfArmorItem.java │ │ │ │ ├── WritableBookItem.java │ │ │ │ └── WrittenBookItem.java │ │ │ ├── level │ │ │ ├── BedrockDimension.java │ │ │ ├── BedrockMapIcon.java │ │ │ ├── FireworkColor.java │ │ │ ├── GameRule.java │ │ │ ├── GeyserAdvancement.java │ │ │ ├── GeyserWorldManager.java │ │ │ ├── JavaDimension.java │ │ │ ├── JukeboxSong.java │ │ │ ├── MapColor.java │ │ │ ├── PaintingType.java │ │ │ ├── WorldManager.java │ │ │ ├── block │ │ │ │ ├── BlockStateValues.java │ │ │ │ ├── Blocks.java │ │ │ │ ├── Fluid.java │ │ │ │ ├── GeyserCustomBlockComponents.java │ │ │ │ ├── GeyserCustomBlockData.java │ │ │ │ ├── GeyserCustomBlockProperty.java │ │ │ │ ├── GeyserCustomBlockState.java │ │ │ │ ├── GeyserGeometryComponent.java │ │ │ │ ├── GeyserJavaBlockState.java │ │ │ │ ├── GeyserMaterialInstance.java │ │ │ │ ├── GeyserNonVanillaCustomBlockData.java │ │ │ │ ├── property │ │ │ │ │ ├── BasicEnumProperty.java │ │ │ │ │ ├── BooleanProperty.java │ │ │ │ │ ├── ChestType.java │ │ │ │ │ ├── EnumProperty.java │ │ │ │ │ ├── FrontAndTop.java │ │ │ │ │ ├── IntegerProperty.java │ │ │ │ │ ├── Properties.java │ │ │ │ │ └── Property.java │ │ │ │ └── type │ │ │ │ │ ├── BannerBlock.java │ │ │ │ │ ├── BedBlock.java │ │ │ │ │ ├── Block.java │ │ │ │ │ ├── BlockState.java │ │ │ │ │ ├── ButtonBlock.java │ │ │ │ │ ├── CauldronBlock.java │ │ │ │ │ ├── ChestBlock.java │ │ │ │ │ ├── DoorBlock.java │ │ │ │ │ ├── FlowerPotBlock.java │ │ │ │ │ ├── FurnaceBlock.java │ │ │ │ │ ├── HoneyBlock.java │ │ │ │ │ ├── LecternBlock.java │ │ │ │ │ ├── MovingPistonBlock.java │ │ │ │ │ ├── PistonBlock.java │ │ │ │ │ ├── PistonHeadBlock.java │ │ │ │ │ ├── SkullBlock.java │ │ │ │ │ ├── SpawnerBlock.java │ │ │ │ │ ├── TrapDoorBlock.java │ │ │ │ │ ├── WallSkullBlock.java │ │ │ │ │ └── WaterBlock.java │ │ │ ├── chunk │ │ │ │ ├── BlockStorage.java │ │ │ │ ├── GeyserChunk.java │ │ │ │ ├── GeyserChunkSection.java │ │ │ │ └── bitarray │ │ │ │ │ ├── BitArray.java │ │ │ │ │ ├── BitArrayVersion.java │ │ │ │ │ ├── PaddedBitArray.java │ │ │ │ │ ├── Pow2BitArray.java │ │ │ │ │ └── SingletonBitArray.java │ │ │ └── physics │ │ │ │ ├── Axis.java │ │ │ │ ├── BoundingBox.java │ │ │ │ ├── CollisionManager.java │ │ │ │ ├── CollisionResult.java │ │ │ │ ├── Direction.java │ │ │ │ └── PistonBehavior.java │ │ │ ├── network │ │ │ ├── CIDRMatcher.java │ │ │ ├── CodecProcessor.java │ │ │ ├── GameProtocol.java │ │ │ ├── GeyserBedrockPeer.java │ │ │ ├── GeyserServerInitializer.java │ │ │ ├── InvalidPacketHandler.java │ │ │ ├── LoggingPacketHandler.java │ │ │ ├── UpstreamPacketHandler.java │ │ │ └── netty │ │ │ │ ├── Bootstraps.java │ │ │ │ ├── ChannelWrapper.java │ │ │ │ ├── DefaultChannelPipelinePublic.java │ │ │ │ ├── GeyserInjector.java │ │ │ │ ├── GeyserServer.java │ │ │ │ ├── IoHandlerWrapper.java │ │ │ │ ├── LocalChannelWithRemoteAddress.java │ │ │ │ ├── LocalChannelWrapper.java │ │ │ │ ├── LocalServerChannelWrapper.java │ │ │ │ ├── LocalSession.java │ │ │ │ ├── WatchedSingleThreadIoEventLoop.java │ │ │ │ ├── handler │ │ │ │ ├── RakConnectionRequestHandler.java │ │ │ │ ├── RakGeyserRateLimiter.java │ │ │ │ └── RakPingHandler.java │ │ │ │ └── proxy │ │ │ │ ├── ProxyProtocolDecoder.java │ │ │ │ └── ProxyServerHandler.java │ │ │ ├── pack │ │ │ ├── GeyserResourcePack.java │ │ │ ├── GeyserResourcePackManifest.java │ │ │ ├── ResourcePackHolder.java │ │ │ ├── SkullResourcePackManager.java │ │ │ ├── option │ │ │ │ ├── GeyserPriorityOption.java │ │ │ │ ├── GeyserSubpackOption.java │ │ │ │ ├── GeyserUrlFallbackOption.java │ │ │ │ └── OptionHolder.java │ │ │ ├── path │ │ │ │ └── GeyserPathPackCodec.java │ │ │ └── url │ │ │ │ └── GeyserUrlPackCodec.java │ │ │ ├── ping │ │ │ ├── GeyserLegacyPingPassthrough.java │ │ │ ├── GeyserPingInfo.java │ │ │ └── IGeyserPingPassthrough.java │ │ │ ├── registry │ │ │ ├── AbstractMappedDeferredRegistry.java │ │ │ ├── AbstractMappedRegistry.java │ │ │ ├── ArrayRegistry.java │ │ │ ├── BlockRegistries.java │ │ │ ├── DeferredRegistry.java │ │ │ ├── IRegistry.java │ │ │ ├── ListDeferredRegistry.java │ │ │ ├── ListRegistry.java │ │ │ ├── MappedRegistry.java │ │ │ ├── PacketTranslatorRegistry.java │ │ │ ├── Registries.java │ │ │ ├── Registry.java │ │ │ ├── SimpleDeferredRegistry.java │ │ │ ├── SimpleMappedDeferredRegistry.java │ │ │ ├── SimpleMappedRegistry.java │ │ │ ├── SimpleRegistry.java │ │ │ ├── VersionedDeferredRegistry.java │ │ │ ├── VersionedRegistry.java │ │ │ ├── loader │ │ │ │ ├── AnnotatedRegistryLoader.java │ │ │ │ ├── BiomeIdentifierRegistryLoader.java │ │ │ │ ├── BiomeLoader.java │ │ │ │ ├── BlockEntityRegistryLoader.java │ │ │ │ ├── CollisionRegistryLoader.java │ │ │ │ ├── EffectRegistryLoader.java │ │ │ │ ├── MultiResourceRegistryLoader.java │ │ │ │ ├── NbtRegistryLoader.java │ │ │ │ ├── ParticleTypesRegistryLoader.java │ │ │ │ ├── PotionMixRegistryLoader.java │ │ │ │ ├── ProviderRegistryLoader.java │ │ │ │ ├── RecipeRegistryLoader.java │ │ │ │ ├── RegistryLoader.java │ │ │ │ ├── RegistryLoaders.java │ │ │ │ ├── ResourcePackLoader.java │ │ │ │ ├── SoundEventsRegistryLoader.java │ │ │ │ ├── SoundRegistryLoader.java │ │ │ │ └── SoundTranslatorRegistryLoader.java │ │ │ ├── mappings │ │ │ │ ├── MappingsConfigReader.java │ │ │ │ ├── util │ │ │ │ │ ├── CustomBlockComponentsMapping.java │ │ │ │ │ ├── CustomBlockMapping.java │ │ │ │ │ ├── CustomBlockStateBuilderMapping.java │ │ │ │ │ └── CustomBlockStateMapping.java │ │ │ │ └── versions │ │ │ │ │ ├── MappingsReader.java │ │ │ │ │ └── MappingsReader_v1.java │ │ │ ├── populator │ │ │ │ ├── BlockRegistryPopulator.java │ │ │ │ ├── CreativeItemRegistryPopulator.java │ │ │ │ ├── CustomBlockRegistryPopulator.java │ │ │ │ ├── CustomItemRegistryPopulator.java │ │ │ │ ├── CustomSkullRegistryPopulator.java │ │ │ │ ├── DataComponentRegistryPopulator.java │ │ │ │ ├── ItemRegistryPopulator.java │ │ │ │ ├── PacketRegistryPopulator.java │ │ │ │ ├── TagRegistryPopulator.java │ │ │ │ └── conversion │ │ │ │ │ ├── Conversion776_766.java │ │ │ │ │ ├── Conversion786_776.java │ │ │ │ │ └── ConversionHelper.java │ │ │ ├── provider │ │ │ │ └── ProviderSupplier.java │ │ │ └── type │ │ │ │ ├── BlockMappings.java │ │ │ │ ├── CustomSkull.java │ │ │ │ ├── GeyserBedrockBlock.java │ │ │ │ ├── GeyserMappingItem.java │ │ │ │ ├── ItemMapping.java │ │ │ │ ├── ItemMappings.java │ │ │ │ ├── NonVanillaItemRegistration.java │ │ │ │ ├── PaletteItem.java │ │ │ │ ├── ParticleMapping.java │ │ │ │ └── SoundMapping.java │ │ │ ├── scoreboard │ │ │ ├── Objective.java │ │ │ ├── ScoreReference.java │ │ │ ├── Scoreboard.java │ │ │ ├── ScoreboardUpdater.java │ │ │ ├── Team.java │ │ │ ├── UpdateType.java │ │ │ └── display │ │ │ │ ├── score │ │ │ │ ├── BelownameDisplayScore.java │ │ │ │ ├── DisplayScore.java │ │ │ │ ├── PlayerlistDisplayScore.java │ │ │ │ └── SidebarDisplayScore.java │ │ │ │ └── slot │ │ │ │ ├── BelownameDisplaySlot.java │ │ │ │ ├── DisplaySlot.java │ │ │ │ ├── PlayerlistDisplaySlot.java │ │ │ │ └── SidebarDisplaySlot.java │ │ │ ├── session │ │ │ ├── DownstreamSession.java │ │ │ ├── GeyserSession.java │ │ │ ├── GeyserSessionAdapter.java │ │ │ ├── PendingMicrosoftAuthentication.java │ │ │ ├── SessionDisconnectListener.java │ │ │ ├── SessionManager.java │ │ │ ├── UpstreamSession.java │ │ │ ├── auth │ │ │ │ ├── AuthData.java │ │ │ │ └── BedrockClientData.java │ │ │ └── cache │ │ │ │ ├── AdvancementsCache.java │ │ │ │ ├── BookEditCache.java │ │ │ │ ├── BossBar.java │ │ │ │ ├── BundleCache.java │ │ │ │ ├── ChunkCache.java │ │ │ │ ├── EntityCache.java │ │ │ │ ├── EntityEffectCache.java │ │ │ │ ├── FormCache.java │ │ │ │ ├── InputCache.java │ │ │ │ ├── LodestoneCache.java │ │ │ │ ├── PistonCache.java │ │ │ │ ├── PreferencesCache.java │ │ │ │ ├── RegistryCache.java │ │ │ │ ├── SkullCache.java │ │ │ │ ├── StructureBlockCache.java │ │ │ │ ├── TagCache.java │ │ │ │ ├── TeleportCache.java │ │ │ │ ├── WorldBorder.java │ │ │ │ ├── WorldCache.java │ │ │ │ ├── registry │ │ │ │ ├── JavaRegistries.java │ │ │ │ ├── JavaRegistry.java │ │ │ │ ├── JavaRegistryKey.java │ │ │ │ ├── RegistryEntryContext.java │ │ │ │ ├── RegistryEntryData.java │ │ │ │ ├── RegistryUnit.java │ │ │ │ └── SimpleJavaRegistry.java │ │ │ │ └── tags │ │ │ │ ├── BlockTag.java │ │ │ │ ├── EnchantmentTag.java │ │ │ │ ├── GeyserHolderSet.java │ │ │ │ ├── ItemTag.java │ │ │ │ └── Tag.java │ │ │ ├── skin │ │ │ ├── FakeHeadProvider.java │ │ │ ├── FloodgateSkinUploader.java │ │ │ ├── ProvidedSkins.java │ │ │ ├── SkinManager.java │ │ │ ├── SkinProvider.java │ │ │ └── SkullSkinManager.java │ │ │ ├── text │ │ │ ├── AsteriskSerializer.java │ │ │ ├── ChatColor.java │ │ │ ├── ChatDecoration.java │ │ │ ├── DummyLegacyHoverEventSerializer.java │ │ │ ├── GeyserLocale.java │ │ │ ├── GsonComponentSerializerWrapper.java │ │ │ ├── MinecraftLocale.java │ │ │ └── MinecraftTranslationRegistry.java │ │ │ ├── translator │ │ │ ├── collision │ │ │ │ ├── BlockCollision.java │ │ │ │ ├── CollisionRemapper.java │ │ │ │ ├── DirtPathCollision.java │ │ │ │ ├── DoorCollision.java │ │ │ │ ├── GlassPaneAndIronBarsCollision.java │ │ │ │ ├── OtherCollision.java │ │ │ │ ├── ScaffoldingCollision.java │ │ │ │ ├── SolidCollision.java │ │ │ │ └── TrapdoorCollision.java │ │ │ ├── entity │ │ │ │ └── EntityMetadataTranslator.java │ │ │ ├── inventory │ │ │ │ ├── AbstractBlockInventoryTranslator.java │ │ │ │ ├── AnvilInventoryTranslator.java │ │ │ │ ├── BaseInventoryTranslator.java │ │ │ │ ├── BeaconInventoryTranslator.java │ │ │ │ ├── BrewingInventoryTranslator.java │ │ │ │ ├── BundleInventoryTranslator.java │ │ │ │ ├── CartographyInventoryTranslator.java │ │ │ │ ├── CrafterInventoryTranslator.java │ │ │ │ ├── CraftingInventoryTranslator.java │ │ │ │ ├── EnchantingInventoryTranslator.java │ │ │ │ ├── Generic3X3InventoryTranslator.java │ │ │ │ ├── GrindstoneInventoryTranslator.java │ │ │ │ ├── HopperInventoryTranslator.java │ │ │ │ ├── InventoryTranslator.java │ │ │ │ ├── LecternInventoryTranslator.java │ │ │ │ ├── LoomInventoryTranslator.java │ │ │ │ ├── MerchantInventoryTranslator.java │ │ │ │ ├── OldSmithingTableTranslator.java │ │ │ │ ├── PlayerInventoryTranslator.java │ │ │ │ ├── ShulkerInventoryTranslator.java │ │ │ │ ├── SmithingInventoryTranslator.java │ │ │ │ ├── StonecutterInventoryTranslator.java │ │ │ │ ├── chest │ │ │ │ │ ├── ChestInventoryTranslator.java │ │ │ │ │ ├── DoubleChestInventoryTranslator.java │ │ │ │ │ └── SingleChestInventoryTranslator.java │ │ │ │ ├── furnace │ │ │ │ │ ├── AbstractFurnaceInventoryTranslator.java │ │ │ │ │ ├── BlastFurnaceInventoryTranslator.java │ │ │ │ │ ├── FurnaceInventoryTranslator.java │ │ │ │ │ └── SmokerInventoryTranslator.java │ │ │ │ └── horse │ │ │ │ │ ├── AbstractHorseInventoryTranslator.java │ │ │ │ │ ├── ChestedHorseInventoryTranslator.java │ │ │ │ │ ├── DonkeyInventoryTranslator.java │ │ │ │ │ ├── HorseInventoryTranslator.java │ │ │ │ │ └── LlamaInventoryTranslator.java │ │ │ ├── item │ │ │ │ ├── BedrockItemBuilder.java │ │ │ │ ├── CustomItemTranslator.java │ │ │ │ └── ItemTranslator.java │ │ │ ├── level │ │ │ │ ├── BiomeTranslator.java │ │ │ │ ├── block │ │ │ │ │ └── entity │ │ │ │ │ │ ├── BannerBlockEntityTranslator.java │ │ │ │ │ │ ├── BeaconBlockEntityTranslator.java │ │ │ │ │ │ ├── BedBlockEntityTranslator.java │ │ │ │ │ │ ├── BedrockChunkWantsBlockEntityTag.java │ │ │ │ │ │ ├── BlockEntity.java │ │ │ │ │ │ ├── BlockEntityTranslator.java │ │ │ │ │ │ ├── BrushableBlockEntityTranslator.java │ │ │ │ │ │ ├── CampfireBlockEntityTranslator.java │ │ │ │ │ │ ├── CommandBlockBlockEntityTranslator.java │ │ │ │ │ │ ├── DecoratedPotBlockEntityTranslator.java │ │ │ │ │ │ ├── DoubleChestBlockEntityTranslator.java │ │ │ │ │ │ ├── EmptyBlockEntityTranslator.java │ │ │ │ │ │ ├── EndGatewayBlockEntityTranslator.java │ │ │ │ │ │ ├── HangingSignBlockEntityTranslator.java │ │ │ │ │ │ ├── JigsawBlockBlockEntityTranslator.java │ │ │ │ │ │ ├── PistonBlockEntity.java │ │ │ │ │ │ ├── RequiresBlockState.java │ │ │ │ │ │ ├── ShulkerBoxBlockEntityTranslator.java │ │ │ │ │ │ ├── SignBlockEntityTranslator.java │ │ │ │ │ │ ├── SkullBlockEntityTranslator.java │ │ │ │ │ │ ├── SpawnerBlockEntityTranslator.java │ │ │ │ │ │ ├── StructureBlockBlockEntityTranslator.java │ │ │ │ │ │ ├── TrialSpawnerBlockEntityTranslator.java │ │ │ │ │ │ └── VaultBlockEntityTranslator.java │ │ │ │ └── event │ │ │ │ │ ├── LevelEventTranslator.java │ │ │ │ │ ├── PlaySoundEventTranslator.java │ │ │ │ │ ├── SoundEventEventTranslator.java │ │ │ │ │ └── SoundLevelEventTranslator.java │ │ │ ├── protocol │ │ │ │ ├── PacketTranslator.java │ │ │ │ ├── Translator.java │ │ │ │ ├── bedrock │ │ │ │ │ ├── BedrockAnimateTranslator.java │ │ │ │ │ ├── BedrockBlockEntityDataTranslator.java │ │ │ │ │ ├── BedrockBlockPickRequestTranslator.java │ │ │ │ │ ├── BedrockBookEditTranslator.java │ │ │ │ │ ├── BedrockCommandBlockUpdateTranslator.java │ │ │ │ │ ├── BedrockCommandRequestTranslator.java │ │ │ │ │ ├── BedrockContainerCloseTranslator.java │ │ │ │ │ ├── BedrockEmoteListTranslator.java │ │ │ │ │ ├── BedrockEntityPickRequestTranslator.java │ │ │ │ │ ├── BedrockFilterTextTranslator.java │ │ │ │ │ ├── BedrockInventoryTransactionTranslator.java │ │ │ │ │ ├── BedrockItemStackRequestTranslator.java │ │ │ │ │ ├── BedrockLecternUpdateTranslator.java │ │ │ │ │ ├── BedrockMobEquipmentTranslator.java │ │ │ │ │ ├── BedrockNetworkStackLatencyTranslator.java │ │ │ │ │ ├── BedrockPacketViolationWarningTranslator.java │ │ │ │ │ ├── BedrockPositionTrackingDBClientRequestTranslator.java │ │ │ │ │ ├── BedrockRequestChunkRadiusTranslator.java │ │ │ │ │ ├── BedrockRespawnTranslator.java │ │ │ │ │ ├── BedrockServerSettingsRequestTranslator.java │ │ │ │ │ ├── BedrockSetLocalPlayerAsInitializedTranslator.java │ │ │ │ │ ├── BedrockShowCreditsTranslator.java │ │ │ │ │ ├── BedrockStructureBlockUpdateTranslator.java │ │ │ │ │ ├── BedrockStructureTemplateDataRequestTranslator.java │ │ │ │ │ ├── BedrockTextTranslator.java │ │ │ │ │ ├── BedrockToggleCrafterSlotRequestTranslator.java │ │ │ │ │ ├── entity │ │ │ │ │ │ ├── BedrockEntityEventTranslator.java │ │ │ │ │ │ └── player │ │ │ │ │ │ │ ├── BedrockEmoteTranslator.java │ │ │ │ │ │ │ ├── BedrockInteractTranslator.java │ │ │ │ │ │ │ ├── BedrockPlayerActionTranslator.java │ │ │ │ │ │ │ ├── BedrockRequestPermissionsPacket.java │ │ │ │ │ │ │ ├── BedrockSetDefaultGameTypeTranslator.java │ │ │ │ │ │ │ ├── BedrockSetDifficultyTranslator.java │ │ │ │ │ │ │ ├── BedrockSetPlayerGameTypeTranslator.java │ │ │ │ │ │ │ ├── BedrockSetPlayerInventoryOptionsTranslator.java │ │ │ │ │ │ │ └── input │ │ │ │ │ │ │ ├── BedrockBlockActions.java │ │ │ │ │ │ │ ├── BedrockMovePlayer.java │ │ │ │ │ │ │ └── BedrockPlayerAuthInputTranslator.java │ │ │ │ │ └── world │ │ │ │ │ │ └── BedrockLevelSoundEventTranslator.java │ │ │ │ └── java │ │ │ │ │ ├── JavaAwardStatsTranslator.java │ │ │ │ │ ├── JavaBossEventTranslator.java │ │ │ │ │ ├── JavaChangeDifficultyTranslator.java │ │ │ │ │ ├── JavaClientboundResourcePackPushPacket.java │ │ │ │ │ ├── JavaCommandsTranslator.java │ │ │ │ │ ├── JavaCustomPayloadTranslator.java │ │ │ │ │ ├── JavaCustomQueryTranslator.java │ │ │ │ │ ├── JavaDisguisedChatTranslator.java │ │ │ │ │ ├── JavaFinishConfigurationTranslator.java │ │ │ │ │ ├── JavaKeepAliveTranslator.java │ │ │ │ │ ├── JavaLoginFinishedTranslator.java │ │ │ │ │ ├── JavaLoginTranslator.java │ │ │ │ │ ├── JavaPingTranslator.java │ │ │ │ │ ├── JavaPlayerChatTranslator.java │ │ │ │ │ ├── JavaRecipeBookAddTranslator.java │ │ │ │ │ ├── JavaRecipeBookRemoveTranslator.java │ │ │ │ │ ├── JavaRegistryDataTranslator.java │ │ │ │ │ ├── JavaRespawnTranslator.java │ │ │ │ │ ├── JavaSelectAdvancementsTabTranslator.java │ │ │ │ │ ├── JavaSelectKnownPacksTranslator.java │ │ │ │ │ ├── JavaStartConfigurationTranslator.java │ │ │ │ │ ├── JavaSystemChatTranslator.java │ │ │ │ │ ├── JavaTickingStateTranslator.java │ │ │ │ │ ├── JavaTickingStepTranslator.java │ │ │ │ │ ├── JavaUpdateAdvancementsTranslator.java │ │ │ │ │ ├── JavaUpdateEnabledFeaturesPacket.java │ │ │ │ │ ├── JavaUpdateRecipesTranslator.java │ │ │ │ │ ├── JavaUpdateTagsTranslator.java │ │ │ │ │ ├── entity │ │ │ │ │ ├── JavaAddEntityTranslator.java │ │ │ │ │ ├── JavaAnimateTranslator.java │ │ │ │ │ ├── JavaDamageEventTranslator.java │ │ │ │ │ ├── JavaEntityEventTranslator.java │ │ │ │ │ ├── JavaEntityPositionSyncTranslator.java │ │ │ │ │ ├── JavaMoveEntityPosRotTranslator.java │ │ │ │ │ ├── JavaMoveEntityPosTranslator.java │ │ │ │ │ ├── JavaMoveEntityRotTranslator.java │ │ │ │ │ ├── JavaMoveMinecartTranslator.java │ │ │ │ │ ├── JavaMoveVehicleTranslator.java │ │ │ │ │ ├── JavaRemoveEntitiesTranslator.java │ │ │ │ │ ├── JavaRemoveMobEffectTranslator.java │ │ │ │ │ ├── JavaRotateHeadTranslator.java │ │ │ │ │ ├── JavaSetEntityDataTranslator.java │ │ │ │ │ ├── JavaSetEntityLinkTranslator.java │ │ │ │ │ ├── JavaSetEntityMotionTranslator.java │ │ │ │ │ ├── JavaSetEquipmentTranslator.java │ │ │ │ │ ├── JavaSetPassengersTranslator.java │ │ │ │ │ ├── JavaSoundEntityTranslator.java │ │ │ │ │ ├── JavaTakeItemEntityTranslator.java │ │ │ │ │ ├── JavaTeleportEntityTranslator.java │ │ │ │ │ ├── JavaUpdateAttributesTranslator.java │ │ │ │ │ ├── JavaUpdateMobEffectTranslator.java │ │ │ │ │ └── player │ │ │ │ │ │ ├── JavaBlockChangedAckTranslator.java │ │ │ │ │ │ ├── JavaCookieRequestTranslator.java │ │ │ │ │ │ ├── JavaPlayerAbilitiesTranslator.java │ │ │ │ │ │ ├── JavaPlayerCombatKillTranslator.java │ │ │ │ │ │ ├── JavaPlayerInfoRemoveTranslator.java │ │ │ │ │ │ ├── JavaPlayerInfoUpdateTranslator.java │ │ │ │ │ │ ├── JavaPlayerLookAtTranslator.java │ │ │ │ │ │ ├── JavaPlayerPositionTranslator.java │ │ │ │ │ │ ├── JavaPlayerRotationTranslator.java │ │ │ │ │ │ ├── JavaSetExperienceTranslator.java │ │ │ │ │ │ ├── JavaSetHealthTranslator.java │ │ │ │ │ │ ├── JavaSetHeldSlotTranslator.java │ │ │ │ │ │ ├── JavaStoreCookieTranslator.java │ │ │ │ │ │ └── JavaTransferPacketTranslator.java │ │ │ │ │ ├── inventory │ │ │ │ │ ├── JavaContainerCloseTranslator.java │ │ │ │ │ ├── JavaContainerSetContentTranslator.java │ │ │ │ │ ├── JavaContainerSetDataTranslator.java │ │ │ │ │ ├── JavaContainerSetSlotTranslator.java │ │ │ │ │ ├── JavaHorseScreenOpenTranslator.java │ │ │ │ │ ├── JavaMerchantOffersTranslator.java │ │ │ │ │ ├── JavaOpenBookTranslator.java │ │ │ │ │ ├── JavaOpenScreenTranslator.java │ │ │ │ │ ├── JavaSetCursorItemTranslator.java │ │ │ │ │ └── JavaSetPlayerInventoryTranslator.java │ │ │ │ │ ├── level │ │ │ │ │ ├── JavaBlockDestructionTranslator.java │ │ │ │ │ ├── JavaBlockEntityDataTranslator.java │ │ │ │ │ ├── JavaBlockEventTranslator.java │ │ │ │ │ ├── JavaBlockUpdateTranslator.java │ │ │ │ │ ├── JavaChunkBatchFinishedTranslator.java │ │ │ │ │ ├── JavaCooldownTranslator.java │ │ │ │ │ ├── JavaExplodeTranslator.java │ │ │ │ │ ├── JavaForgetLevelChunkTranslator.java │ │ │ │ │ ├── JavaGameEventTranslator.java │ │ │ │ │ ├── JavaLevelChunkWithLightTranslator.java │ │ │ │ │ ├── JavaLevelEventTranslator.java │ │ │ │ │ ├── JavaLevelParticlesTranslator.java │ │ │ │ │ ├── JavaMapItemDataTranslator.java │ │ │ │ │ ├── JavaOpenSignEditorTranslator.java │ │ │ │ │ ├── JavaSectionBlocksUpdateTranslator.java │ │ │ │ │ ├── JavaSetChunkCacheCenterTranslator.java │ │ │ │ │ ├── JavaSetChunkCacheRadiusTranslator.java │ │ │ │ │ ├── JavaSetDefaultSpawnPositionTranslator.java │ │ │ │ │ ├── JavaSetTimeTranslator.java │ │ │ │ │ ├── JavaSoundTranslator.java │ │ │ │ │ ├── JavaStopSoundTranslator.java │ │ │ │ │ └── border │ │ │ │ │ │ ├── JavaInitializeBorderTranslator.java │ │ │ │ │ │ ├── JavaSetBorderCenterTranslator.java │ │ │ │ │ │ ├── JavaSetBorderLerpSizeTranslator.java │ │ │ │ │ │ ├── JavaSetBorderSizeTranslator.java │ │ │ │ │ │ ├── JavaSetBorderWarningDelayTranslator.java │ │ │ │ │ │ └── JavaSetBorderWarningDistanceTranslator.java │ │ │ │ │ ├── scoreboard │ │ │ │ │ ├── JavaResetScorePacket.java │ │ │ │ │ ├── JavaSetDisplayObjectiveTranslator.java │ │ │ │ │ ├── JavaSetObjectiveTranslator.java │ │ │ │ │ ├── JavaSetPlayerTeamTranslator.java │ │ │ │ │ └── JavaSetScoreTranslator.java │ │ │ │ │ └── title │ │ │ │ │ ├── JavaClearTitlesTranslator.java │ │ │ │ │ ├── JavaSetActionBarTextTranslator.java │ │ │ │ │ ├── JavaSetSubtitleTextTranslator.java │ │ │ │ │ ├── JavaSetTitleTextTranslator.java │ │ │ │ │ └── JavaSetTitlesAnimationTranslator.java │ │ │ ├── sound │ │ │ │ ├── BlockSoundInteractionTranslator.java │ │ │ │ ├── SoundInteractionTranslator.java │ │ │ │ ├── SoundTranslator.java │ │ │ │ └── block │ │ │ │ │ ├── BucketSoundInteractionTranslator.java │ │ │ │ │ ├── ButtonSoundInteractionTranslator.java │ │ │ │ │ ├── ComparatorSoundInteractionTranslator.java │ │ │ │ │ ├── FlintAndSteelInteractionTranslator.java │ │ │ │ │ ├── GrassPathInteractionTranslator.java │ │ │ │ │ ├── HoeInteractionTranslator.java │ │ │ │ │ ├── LeverSoundInteractionTranslator.java │ │ │ │ │ └── OpenableSoundInteractionTranslator.java │ │ │ └── text │ │ │ │ └── MessageTranslator.java │ │ │ └── util │ │ │ ├── AssetUtils.java │ │ │ ├── AttributeUtils.java │ │ │ ├── BlockEntityUtils.java │ │ │ ├── BlockUtils.java │ │ │ ├── ChunkUtils.java │ │ │ ├── CooldownUtils.java │ │ │ ├── CpuUtils.java │ │ │ ├── DimensionUtils.java │ │ │ ├── EntityUtils.java │ │ │ ├── EnvironmentUtils.java │ │ │ ├── FileUtils.java │ │ │ ├── InteractionResult.java │ │ │ ├── InteractiveTag.java │ │ │ ├── InventoryUtils.java │ │ │ ├── ItemUtils.java │ │ │ ├── LoginEncryptionUtils.java │ │ │ ├── LoopbackUtil.java │ │ │ ├── MathUtils.java │ │ │ ├── Metrics.java │ │ │ ├── MinecraftAuthLogger.java │ │ │ ├── MinecraftKey.java │ │ │ ├── NewsHandler.java │ │ │ ├── PlayerListUtils.java │ │ │ ├── PluginMessageUtils.java │ │ │ ├── SettingsUtils.java │ │ │ ├── SignUtils.java │ │ │ ├── SoundUtils.java │ │ │ ├── StatisticFormatters.java │ │ │ ├── StatisticsUtils.java │ │ │ ├── StructureBlockUtils.java │ │ │ ├── ThrowingBiConsumer.java │ │ │ ├── VersionCheckUtils.java │ │ │ ├── WebUtils.java │ │ │ └── thirdparty │ │ │ └── Fraction.java │ └── resources │ │ ├── assets │ │ └── geyser │ │ │ └── icon.png │ │ ├── bedrock │ │ ├── biome_definitions.dat │ │ ├── block_palette.1_21_50.nbt │ │ ├── block_palette.1_21_60.nbt │ │ ├── block_palette.1_21_70.nbt │ │ ├── block_palette.1_21_80.nbt │ │ ├── creative_items.1_21_50.json │ │ ├── creative_items.1_21_60.json │ │ ├── creative_items.1_21_70.json │ │ ├── creative_items.1_21_80.json │ │ ├── entity_identifiers.dat │ │ ├── item_components.nbt │ │ ├── item_tags.1_21_50.json │ │ ├── item_tags.1_21_60.json │ │ ├── item_tags.1_21_70.json │ │ ├── runtime_item_states.1_21_50.json │ │ ├── runtime_item_states.1_21_60.json │ │ ├── runtime_item_states.1_21_70.json │ │ ├── runtime_item_states.1_21_80.json │ │ ├── skin │ │ │ ├── geometry.humanoid.customskull.json │ │ │ ├── geometry.humanoid.wearingCustomSkull.json │ │ │ └── geometry.humanoid.wearingCustomSkullSlim.json │ │ ├── skull_resource_pack │ │ │ ├── animations │ │ │ │ ├── disable.animation.json │ │ │ │ └── player_skull.animation.json │ │ │ ├── attachables │ │ │ │ └── template_attachable.json │ │ │ ├── manifest.json │ │ │ ├── models │ │ │ │ └── blocks │ │ │ │ │ ├── player_skull.geo.json │ │ │ │ │ ├── player_skull_floor.geo.json │ │ │ │ │ ├── player_skull_hand.geo.json │ │ │ │ │ └── player_skull_wall.geo.json │ │ │ └── textures │ │ │ │ └── terrain_texture.json │ │ ├── skull_resource_pack_files.txt │ │ └── stripped_biome_definitions.json │ │ ├── config.yml │ │ ├── custom-skulls.yml │ │ ├── git.properties │ │ ├── java │ │ └── item_data_components.json │ │ └── permissions.yml │ └── test │ ├── java │ └── org │ │ └── geysermc │ │ └── geyser │ │ ├── network │ │ └── translators │ │ │ └── chat │ │ │ └── MessageTranslatorTest.java │ │ ├── registry │ │ └── loader │ │ │ └── ResourcePackLoaderTest.java │ │ ├── scoreboard │ │ └── network │ │ │ ├── NameVisibilityScoreboardTest.java │ │ │ ├── ScoreboardIssueTests.java │ │ │ ├── belowname │ │ │ └── BasicBelownameScoreboardTests.java │ │ │ ├── playerlist │ │ │ └── BasicPlayerlistScoreboardTests.java │ │ │ ├── server │ │ │ └── CubecraftScoreboardTest.java │ │ │ ├── sidebar │ │ │ ├── BasicSidebarScoreboardTests.java │ │ │ ├── OrderAndLimitSidebarScoreboardTests.java │ │ │ └── VanillaSidebarScoreboardTests.java │ │ │ └── util │ │ │ ├── AssertUtils.java │ │ │ ├── EmptyGeyserLogger.java │ │ │ ├── GeyserMockContext.java │ │ │ └── GeyserMockContextScoreboard.java │ │ └── translator │ │ └── inventory │ │ └── item │ │ └── CustomItemsTest.java │ └── resources │ ├── empty_pack.mcpack │ ├── encrypted_pack.zip │ └── encrypted_pack.zip.key ├── gradle.properties ├── gradle ├── libs.versions.toml └── wrapper │ ├── gradle-wrapper.jar │ └── gradle-wrapper.properties ├── gradlew ├── gradlew.bat ├── patches ├── 0001-refer-to-3851-pull-request-from-main-branch.patch └── 0002-By-refering-the-commit-4147-revert-the-mojang-login-.patch └── settings.gradle.kts /.editorconfig: -------------------------------------------------------------------------------- 1 | root = true 2 | 3 | [*] 4 | charset = utf-8 5 | indent_size = 4 6 | indent_style = space 7 | insert_final_newline = true 8 | tab_width = 4 9 | max_line_length = off 10 | 11 | [*.java] 12 | ij_java_class_count_to_use_import_on_demand = 9999 13 | ij_java_doc_align_exception_comments = false 14 | ij_java_doc_align_param_comments = false 15 | -------------------------------------------------------------------------------- /.github/ISSUE_TEMPLATE/config.yml: -------------------------------------------------------------------------------- 1 | blank_issues_enabled: false 2 | contact_links: 3 | - name: Common Issues 4 | url: https://wiki.geysermc.org/geyser/common-issues 5 | about: Check the common issues to see if you are not alone with that issue and see how you can fix them. 6 | - name: Frequently Asked Questions 7 | url: https://wiki.geysermc.org/geyser/faq 8 | about: Look at the FAQ page for answers to frequently asked questions. 9 | - name: Get help on the GeyserMC Discord server 10 | url: https://discord.gg/geysermc 11 | about: If your issue seems like it could possibly be an easy fix due to configuration, please hop on our Discord. 12 | -------------------------------------------------------------------------------- /.github/ISSUE_TEMPLATE/custom.md: -------------------------------------------------------------------------------- 1 | --- 2 | name: Custom issue template 3 | about: Describe this issue template's purpose here. 4 | title: '' 5 | labels: '' 6 | assignees: '' 7 | 8 | --- 9 | 10 | 11 | -------------------------------------------------------------------------------- /.github/ISSUE_TEMPLATE/feature_request.yml: -------------------------------------------------------------------------------- 1 | name: Feature request 2 | description: Suggest an idea for this project 3 | labels: "Feature Request" 4 | type: Feature 5 | body: 6 | - type: markdown 7 | attributes: 8 | value: | 9 | Thanks for taking the time to fill out this feature request for Geyser! Please fill out the following form to your best ability to help us understand your feature request and significantly improve the chance of getting added. 10 | For anything else than a feature request, use: [our Discord server](https://discord.gg/geysermc), [the FAQ](https://geysermc.org/wiki/geyser/faq) or the [Common Issues](https://geysermc.org/wiki/geyser/common-issues). 11 | - type: textarea 12 | attributes: 13 | label: What feature do you want to see added? 14 | description: A clear and concise description of your feature request. 15 | validations: 16 | required: true 17 | - type: textarea 18 | attributes: 19 | label: Are there any alternatives? 20 | description: List any alternatives you might have tried 21 | validations: 22 | required: true 23 | -------------------------------------------------------------------------------- /.github/workflows/build-remote.yml: -------------------------------------------------------------------------------- 1 | name: Build Remote 2 | 3 | on: 4 | workflow_call: 5 | inputs: 6 | repository: 7 | required: true 8 | description: 'The repo of the remote' 9 | type: string 10 | ref: 11 | required: true 12 | description: 'The ref of the remote' 13 | type: string 14 | 15 | permissions: {} 16 | 17 | jobs: 18 | build: 19 | runs-on: ubuntu-latest 20 | steps: 21 | - name: Set Build Number 22 | run: | 23 | echo "BUILD_NUMBER=${GITHUB_RUN_NUMBER}" >> $GITHUB_ENV 24 | 25 | - name: Setup Gradle 26 | uses: GeyserMC/actions/setup-gradle-composite@master 27 | with: 28 | checkout_repository: ${{ inputs.repository }} 29 | checkout_ref: ${{ inputs.ref }} 30 | setup-java_java-version: 21 31 | setup-gradle_cache-read-only: true 32 | 33 | - name: Build Geyser 34 | run: ./gradlew build 35 | 36 | - name: Archive Artifacts 37 | uses: GeyserMC/actions/upload-multi-artifact@master 38 | if: success() 39 | with: 40 | artifacts: | 41 | bootstrap/mod/fabric/build/libs/Geyser-Fabric.jar 42 | bootstrap/mod/neoforge/build/libs/Geyser-NeoForge.jar 43 | bootstrap/standalone/build/libs/Geyser-Standalone.jar 44 | bootstrap/spigot/build/libs/Geyser-Spigot.jar 45 | bootstrap/bungeecord/build/libs/Geyser-BungeeCord.jar 46 | bootstrap/velocity/build/libs/Geyser-Velocity.jar 47 | bootstrap/viaproxy/build/libs/Geyser-ViaProxy.jar -------------------------------------------------------------------------------- /.github/workflows/dispatch-preview.yml: -------------------------------------------------------------------------------- 1 | name: Dispatch Preview 2 | 3 | on: 4 | workflow_dispatch: 5 | inputs: 6 | runId: 7 | required: true 8 | description: 'ID of the action to pull artifacts from' 9 | build: 10 | required: true 11 | description: 'Build number for the release' 12 | version: 13 | required: true 14 | description: 'Version under which to upload to the Downloads API' 15 | 16 | jobs: 17 | dispatch-preview: 18 | # Allow access to secrets if we are uploading a preview 19 | secrets: inherit 20 | uses: GeyserMC/actions/.github/workflows/upload-preview.yml@master 21 | with: 22 | build: ${{ inputs.build }} 23 | version: ${{ inputs.version }} 24 | files: | 25 | bungeecord:Geyser-BungeeCord.jar 26 | fabric:Geyser-Fabric.jar 27 | neoforge:Geyser-NeoForge.jar 28 | spigot:Geyser-Spigot.jar 29 | standalone:Geyser-Standalone.jar 30 | velocity:Geyser-Velocity.jar 31 | viaproxy:Geyser-ViaProxy.jar 32 | project: geyserpreview 33 | runId: ${{ inputs.runId }} -------------------------------------------------------------------------------- /.github/workflows/pull-request.yml: -------------------------------------------------------------------------------- 1 | name: Process Pull Request 2 | 3 | on: 4 | pull_request_target: 5 | 6 | jobs: 7 | build: 8 | # Forbid access to secrets nor GH Token perms while building the PR 9 | permissions: {} 10 | secrets: {} 11 | uses: GeyserMC/Geyser/.github/workflows/build-remote.yml@master 12 | with: 13 | repository: ${{ github.event.pull_request.head.repo.full_name }} 14 | ref: ${{ github.event.pull_request.head.sha }} 15 | preview: 16 | needs: [build] 17 | if: >- 18 | contains(github.event.pull_request.labels.*.name, 'PR: Needs Testing') 19 | # Allow access to secrets if we are uploading a preview 20 | secrets: inherit 21 | uses: GeyserMC/actions/.github/workflows/upload-preview.yml@master 22 | with: 23 | build: ${{ github.run_number }} 24 | version: pr.${{ github.event.pull_request.number }} 25 | files: | 26 | bungeecord:Geyser-BungeeCord.jar 27 | fabric:Geyser-Fabric.jar 28 | neoforge:Geyser-NeoForge.jar 29 | spigot:Geyser-Spigot.jar 30 | standalone:Geyser-Standalone.jar 31 | velocity:Geyser-Velocity.jar 32 | viaproxy:Geyser-ViaProxy.jar 33 | project: geyserpreview 34 | runId: ${{ github.run_id }} -------------------------------------------------------------------------------- /.github/workflows/sync_with_upstream.yml: -------------------------------------------------------------------------------- 1 | name: Sync with Upstream 2 | 3 | on: 4 | schedule: 5 | - cron: '0 0 * * *' 6 | workflow_dispatch: 7 | 8 | jobs: 9 | sync: 10 | runs-on: ubuntu-latest 11 | 12 | steps: 13 | - name: Checkout repository 14 | uses: actions/checkout@v4 15 | with: 16 | fetch-depth: 0 17 | 18 | - name: Configure Git 19 | run: | 20 | git config user.name 'Shanwer' 21 | git config user.email 'Shanwer@qq.com' 22 | 23 | - name: Add upstream remote 24 | run: git remote add upstream https://github.com/GeyserMC/Geyser.git 25 | 26 | - name: Fetch upstream changes 27 | run: git fetch upstream 28 | 29 | - name: Merge upstream changes 30 | run: | 31 | git merge upstream/master || { 32 | echo "Merge conflict detected! Notifying for manual intervention." 33 | exit 1 34 | } 35 | 36 | - name: Push changes 37 | uses: ad-m/github-push-action@master 38 | with: 39 | github_token: ${{ secrets.GITHUB_TOKEN }} 40 | branch: 'master' 41 | -------------------------------------------------------------------------------- /.gitmodules: -------------------------------------------------------------------------------- 1 | [submodule "core/src/main/resources/mappings"] 2 | path = core/src/main/resources/mappings 3 | url = https://github.com/GeyserMC/mappings.git 4 | [submodule "core/src/main/resources/languages"] 5 | path = core/src/main/resources/languages 6 | url = https://github.com/Silverteal/geyser-languages-for-custom-yggdrasil.git 7 | -------------------------------------------------------------------------------- /.idea/copyright/Geyser.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 7 | -------------------------------------------------------------------------------- /.idea/copyright/profiles_settings.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- 1 | The MIT License 2 | 3 | Copyright (c) 2019-2024 GeyserMC. http://geysermc.org 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining a copy 6 | of this software and associated documentation files (the "Software"), to deal 7 | in the Software without restriction, including without limitation the rights 8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 9 | copies of the Software, and to permit persons to whom the Software is 10 | furnished to do so, subject to the following conditions: 11 | 12 | The above copyright notice and this permission notice shall be included in 13 | all copies or substantial portions of the Software. 14 | 15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 21 | THE SOFTWARE. 22 | -------------------------------------------------------------------------------- /ap/build.gradle.kts: -------------------------------------------------------------------------------- 1 | plugins { 2 | id("geyser.base-conventions") 3 | } 4 | -------------------------------------------------------------------------------- /ap/src/main/java/org/geysermc/geyser/processor/BlockEntityProcessor.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 2019-2022 GeyserMC. http://geysermc.org 3 | * 4 | * Permission is hereby granted, free of charge, to any person obtaining a copy 5 | * of this software and associated documentation files (the "Software"), to deal 6 | * in the Software without restriction, including without limitation the rights 7 | * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 8 | * copies of the Software, and to permit persons to whom the Software is 9 | * furnished to do so, subject to the following conditions: 10 | * 11 | * The above copyright notice and this permission notice shall be included in 12 | * all copies or substantial portions of the Software. 13 | * 14 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 15 | * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 16 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 17 | * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 18 | * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 19 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 20 | * THE SOFTWARE. 21 | * 22 | * @author GeyserMC 23 | * @link https://github.com/GeyserMC/Geyser 24 | */ 25 | 26 | package org.geysermc.geyser.processor; 27 | 28 | import javax.annotation.processing.SupportedAnnotationTypes; 29 | import javax.annotation.processing.SupportedSourceVersion; 30 | import javax.lang.model.SourceVersion; 31 | 32 | @SupportedAnnotationTypes("*") 33 | @SupportedSourceVersion(SourceVersion.RELEASE_17) 34 | public class BlockEntityProcessor extends ClassProcessor { 35 | public BlockEntityProcessor() { 36 | super("org.geysermc.geyser.translator.level.block.entity.BlockEntity"); 37 | } 38 | } 39 | -------------------------------------------------------------------------------- /ap/src/main/java/org/geysermc/geyser/processor/CollisionRemapperProcessor.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 2019-2022 GeyserMC. http://geysermc.org 3 | * 4 | * Permission is hereby granted, free of charge, to any person obtaining a copy 5 | * of this software and associated documentation files (the "Software"), to deal 6 | * in the Software without restriction, including without limitation the rights 7 | * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 8 | * copies of the Software, and to permit persons to whom the Software is 9 | * furnished to do so, subject to the following conditions: 10 | * 11 | * The above copyright notice and this permission notice shall be included in 12 | * all copies or substantial portions of the Software. 13 | * 14 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 15 | * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 16 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 17 | * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 18 | * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 19 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 20 | * THE SOFTWARE. 21 | * 22 | * @author GeyserMC 23 | * @link https://github.com/GeyserMC/Geyser 24 | */ 25 | 26 | package org.geysermc.geyser.processor; 27 | 28 | import javax.annotation.processing.SupportedAnnotationTypes; 29 | import javax.annotation.processing.SupportedSourceVersion; 30 | import javax.lang.model.SourceVersion; 31 | 32 | @SupportedAnnotationTypes("*") 33 | @SupportedSourceVersion(SourceVersion.RELEASE_17) 34 | public class CollisionRemapperProcessor extends ClassProcessor { 35 | public CollisionRemapperProcessor() { 36 | super("org.geysermc.geyser.translator.collision.CollisionRemapper"); 37 | } 38 | } 39 | -------------------------------------------------------------------------------- /ap/src/main/java/org/geysermc/geyser/processor/PacketTranslatorProcessor.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 2019-2022 GeyserMC. http://geysermc.org 3 | * 4 | * Permission is hereby granted, free of charge, to any person obtaining a copy 5 | * of this software and associated documentation files (the "Software"), to deal 6 | * in the Software without restriction, including without limitation the rights 7 | * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 8 | * copies of the Software, and to permit persons to whom the Software is 9 | * furnished to do so, subject to the following conditions: 10 | * 11 | * The above copyright notice and this permission notice shall be included in 12 | * all copies or substantial portions of the Software. 13 | * 14 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 15 | * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 16 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 17 | * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 18 | * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 19 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 20 | * THE SOFTWARE. 21 | * 22 | * @author GeyserMC 23 | * @link https://github.com/GeyserMC/Geyser 24 | */ 25 | 26 | package org.geysermc.geyser.processor; 27 | 28 | import javax.annotation.processing.SupportedAnnotationTypes; 29 | import javax.annotation.processing.SupportedSourceVersion; 30 | import javax.lang.model.SourceVersion; 31 | 32 | @SupportedAnnotationTypes("*") 33 | @SupportedSourceVersion(SourceVersion.RELEASE_17) 34 | public class PacketTranslatorProcessor extends ClassProcessor { 35 | public PacketTranslatorProcessor() { 36 | super("org.geysermc.geyser.translator.protocol.Translator"); 37 | } 38 | } 39 | -------------------------------------------------------------------------------- /ap/src/main/java/org/geysermc/geyser/processor/SoundHandlerProcessor.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 2019-2022 GeyserMC. http://geysermc.org 3 | * 4 | * Permission is hereby granted, free of charge, to any person obtaining a copy 5 | * of this software and associated documentation files (the "Software"), to deal 6 | * in the Software without restriction, including without limitation the rights 7 | * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 8 | * copies of the Software, and to permit persons to whom the Software is 9 | * furnished to do so, subject to the following conditions: 10 | * 11 | * The above copyright notice and this permission notice shall be included in 12 | * all copies or substantial portions of the Software. 13 | * 14 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 15 | * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 16 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 17 | * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 18 | * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 19 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 20 | * THE SOFTWARE. 21 | * 22 | * @author GeyserMC 23 | * @link https://github.com/GeyserMC/Geyser 24 | */ 25 | 26 | package org.geysermc.geyser.processor; 27 | 28 | import javax.annotation.processing.SupportedAnnotationTypes; 29 | import javax.annotation.processing.SupportedSourceVersion; 30 | import javax.lang.model.SourceVersion; 31 | 32 | @SupportedAnnotationTypes("*") 33 | @SupportedSourceVersion(SourceVersion.RELEASE_17) 34 | public class SoundHandlerProcessor extends ClassProcessor { 35 | public SoundHandlerProcessor() { 36 | super("org.geysermc.geyser.translator.sound.SoundTranslator"); 37 | } 38 | } 39 | -------------------------------------------------------------------------------- /ap/src/main/resources/META-INF/services/javax.annotation.processing.Processor: -------------------------------------------------------------------------------- 1 | org.geysermc.geyser.processor.BlockEntityProcessor 2 | org.geysermc.geyser.processor.CollisionRemapperProcessor 3 | org.geysermc.geyser.processor.PacketTranslatorProcessor 4 | org.geysermc.geyser.processor.SoundHandlerProcessor -------------------------------------------------------------------------------- /api/build.gradle.kts: -------------------------------------------------------------------------------- 1 | plugins { 2 | // Allow blossom to mark sources root of templates 3 | idea 4 | id("geyser.publish-conventions") 5 | alias(libs.plugins.blossom) 6 | } 7 | 8 | dependencies { 9 | api(libs.base.api) 10 | api(libs.math) 11 | } 12 | 13 | version = property("version")!! 14 | val apiVersion = (version as String).removeSuffix("-SNAPSHOT") 15 | 16 | sourceSets { 17 | main { 18 | blossom { 19 | javaSources { 20 | property("version", apiVersion) 21 | } 22 | } 23 | } 24 | } 25 | -------------------------------------------------------------------------------- /api/src/main/java/org/geysermc/geyser/api/bedrock/camera/CameraShake.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 2019-2023 GeyserMC. http://geysermc.org 3 | * 4 | * Permission is hereby granted, free of charge, to any person obtaining a copy 5 | * of this software and associated documentation files (the "Software"), to deal 6 | * in the Software without restriction, including without limitation the rights 7 | * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 8 | * copies of the Software, and to permit persons to whom the Software is 9 | * furnished to do so, subject to the following conditions: 10 | * 11 | * The above copyright notice and this permission notice shall be included in 12 | * all copies or substantial portions of the Software. 13 | * 14 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 15 | * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 16 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 17 | * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 18 | * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 19 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 20 | * THE SOFTWARE. 21 | * 22 | * @author GeyserMC 23 | * @link https://github.com/GeyserMC/Geyser 24 | */ 25 | 26 | package org.geysermc.geyser.api.bedrock.camera; 27 | 28 | /** 29 | * Represents a camera shake instruction. Can be sent in {@link CameraData#shakeCamera(float, float, CameraShake)} 30 | */ 31 | public enum CameraShake { 32 | POSITIONAL, 33 | ROTATIONAL 34 | } 35 | -------------------------------------------------------------------------------- /api/src/main/java/org/geysermc/geyser/api/block/custom/nonvanilla/JavaBoundingBox.java: -------------------------------------------------------------------------------- 1 | package org.geysermc.geyser.api.block.custom.nonvanilla; 2 | 3 | public record JavaBoundingBox(double middleX, double middleY, double middleZ, double sizeX, double sizeY, double sizeZ) { 4 | } 5 | -------------------------------------------------------------------------------- /api/src/main/java/org/geysermc/geyser/api/entity/type/GeyserEntity.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 2019-2023 GeyserMC. http://geysermc.org 3 | * 4 | * Permission is hereby granted, free of charge, to any person obtaining a copy 5 | * of this software and associated documentation files (the "Software"), to deal 6 | * in the Software without restriction, including without limitation the rights 7 | * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 8 | * copies of the Software, and to permit persons to whom the Software is 9 | * furnished to do so, subject to the following conditions: 10 | * 11 | * The above copyright notice and this permission notice shall be included in 12 | * all copies or substantial portions of the Software. 13 | * 14 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 15 | * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 16 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 17 | * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 18 | * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 19 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 20 | * THE SOFTWARE. 21 | * 22 | * @author GeyserMC 23 | * @link https://github.com/GeyserMC/Geyser 24 | */ 25 | 26 | package org.geysermc.geyser.api.entity.type; 27 | 28 | import org.checkerframework.checker.index.qual.NonNegative; 29 | 30 | /** 31 | * Represents a unique instance of an entity. Each {@link org.geysermc.geyser.api.connection.GeyserConnection} 32 | * have their own sets of entities - no two instances will share the same GeyserEntity instance. 33 | */ 34 | public interface GeyserEntity { 35 | /** 36 | * @return the entity ID that the server has assigned to this entity. 37 | */ 38 | @NonNegative 39 | int javaId(); 40 | } 41 | -------------------------------------------------------------------------------- /api/src/main/java/org/geysermc/geyser/api/entity/type/player/GeyserPlayerEntity.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 2019-2023 GeyserMC. http://geysermc.org 3 | * 4 | * Permission is hereby granted, free of charge, to any person obtaining a copy 5 | * of this software and associated documentation files (the "Software"), to deal 6 | * in the Software without restriction, including without limitation the rights 7 | * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 8 | * copies of the Software, and to permit persons to whom the Software is 9 | * furnished to do so, subject to the following conditions: 10 | * 11 | * The above copyright notice and this permission notice shall be included in 12 | * all copies or substantial portions of the Software. 13 | * 14 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 15 | * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 16 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 17 | * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 18 | * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 19 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 20 | * THE SOFTWARE. 21 | * 22 | * @author GeyserMC 23 | * @link https://github.com/GeyserMC/Geyser 24 | */ 25 | 26 | package org.geysermc.geyser.api.entity.type.player; 27 | 28 | import org.cloudburstmc.math.vector.Vector3f; 29 | import org.geysermc.geyser.api.entity.type.GeyserEntity; 30 | 31 | public interface GeyserPlayerEntity extends GeyserEntity { 32 | 33 | /** 34 | * Gets the position of the player, as it is known to the Java server. 35 | * 36 | * @return the player's position 37 | */ 38 | Vector3f position(); 39 | } 40 | -------------------------------------------------------------------------------- /api/src/main/java/org/geysermc/geyser/api/event/EventSubscriber.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 2019-2022 GeyserMC. http://geysermc.org 3 | * 4 | * Permission is hereby granted, free of charge, to any person obtaining a copy 5 | * of this software and associated documentation files (the "Software"), to deal 6 | * in the Software without restriction, including without limitation the rights 7 | * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 8 | * copies of the Software, and to permit persons to whom the Software is 9 | * furnished to do so, subject to the following conditions: 10 | * 11 | * The above copyright notice and this permission notice shall be included in 12 | * all copies or substantial portions of the Software. 13 | * 14 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 15 | * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 16 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 17 | * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 18 | * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 19 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 20 | * THE SOFTWARE. 21 | * 22 | * @author GeyserMC 23 | * @link https://github.com/GeyserMC/Geyser 24 | */ 25 | 26 | package org.geysermc.geyser.api.event; 27 | 28 | import org.geysermc.event.Event; 29 | import org.geysermc.event.subscribe.OwnedSubscriber; 30 | 31 | /** 32 | * Represents a subscribed listener to a {@link Event}. Wraps around 33 | * the event and is capable of unsubscribing from the event or give 34 | * information about it. 35 | * 36 | * @param the class of the event 37 | */ 38 | public interface EventSubscriber extends OwnedSubscriber { 39 | } 40 | -------------------------------------------------------------------------------- /api/src/main/java/org/geysermc/geyser/api/event/ExtensionEventSubscriber.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 2019-2022 GeyserMC. http://geysermc.org 3 | * 4 | * Permission is hereby granted, free of charge, to any person obtaining a copy 5 | * of this software and associated documentation files (the "Software"), to deal 6 | * in the Software without restriction, including without limitation the rights 7 | * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 8 | * copies of the Software, and to permit persons to whom the Software is 9 | * furnished to do so, subject to the following conditions: 10 | * 11 | * The above copyright notice and this permission notice shall be included in 12 | * all copies or substantial portions of the Software. 13 | * 14 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 15 | * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 16 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 17 | * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 18 | * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 19 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 20 | * THE SOFTWARE. 21 | * 22 | * @author GeyserMC 23 | * @link https://github.com/GeyserMC/Geyser 24 | */ 25 | 26 | package org.geysermc.geyser.api.event; 27 | 28 | import org.geysermc.event.Event; 29 | import org.geysermc.event.subscribe.Subscriber; 30 | 31 | public interface ExtensionEventSubscriber extends Subscriber { 32 | } 33 | -------------------------------------------------------------------------------- /api/src/main/java/org/geysermc/geyser/api/event/bedrock/SessionInitializeEvent.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 2019-2022 GeyserMC. http://geysermc.org 3 | * 4 | * Permission is hereby granted, free of charge, to any person obtaining a copy 5 | * of this software and associated documentation files (the "Software"), to deal 6 | * in the Software without restriction, including without limitation the rights 7 | * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 8 | * copies of the Software, and to permit persons to whom the Software is 9 | * furnished to do so, subject to the following conditions: 10 | * 11 | * The above copyright notice and this permission notice shall be included in 12 | * all copies or substantial portions of the Software. 13 | * 14 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 15 | * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 16 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 17 | * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 18 | * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 19 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 20 | * THE SOFTWARE. 21 | * 22 | * @author GeyserMC 23 | * @link https://github.com/GeyserMC/Geyser 24 | */ 25 | 26 | package org.geysermc.geyser.api.event.bedrock; 27 | 28 | import org.checkerframework.checker.nullness.qual.NonNull; 29 | import org.geysermc.geyser.api.connection.GeyserConnection; 30 | import org.geysermc.geyser.api.event.connection.ConnectionEvent; 31 | 32 | /** 33 | * Called when Geyser initialises a session for a new bedrock client. 34 | */ 35 | public final class SessionInitializeEvent extends ConnectionEvent { 36 | public SessionInitializeEvent(@NonNull GeyserConnection connection) { 37 | super(connection); 38 | } 39 | } 40 | -------------------------------------------------------------------------------- /api/src/main/java/org/geysermc/geyser/api/event/bedrock/SessionJoinEvent.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 2019-2023 GeyserMC. http://geysermc.org 3 | * 4 | * Permission is hereby granted, free of charge, to any person obtaining a copy 5 | * of this software and associated documentation files (the "Software"), to deal 6 | * in the Software without restriction, including without limitation the rights 7 | * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 8 | * copies of the Software, and to permit persons to whom the Software is 9 | * furnished to do so, subject to the following conditions: 10 | * 11 | * The above copyright notice and this permission notice shall be included in 12 | * all copies or substantial portions of the Software. 13 | * 14 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 15 | * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 16 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 17 | * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 18 | * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 19 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 20 | * THE SOFTWARE. 21 | * 22 | * @author GeyserMC 23 | * @link https://github.com/GeyserMC/Geyser 24 | */ 25 | 26 | package org.geysermc.geyser.api.event.bedrock; 27 | 28 | import org.checkerframework.checker.nullness.qual.NonNull; 29 | import org.geysermc.geyser.api.connection.GeyserConnection; 30 | import org.geysermc.geyser.api.event.connection.ConnectionEvent; 31 | 32 | /** 33 | * Called when Geyser session connected to a Java remote server and is in a play-ready state. 34 | * @since 2.1.1 35 | */ 36 | public final class SessionJoinEvent extends ConnectionEvent { 37 | public SessionJoinEvent(@NonNull GeyserConnection connection) { 38 | super(connection); 39 | } 40 | } 41 | -------------------------------------------------------------------------------- /api/src/main/java/org/geysermc/geyser/api/event/lifecycle/GeyserDefineCustomSkullsEvent.java: -------------------------------------------------------------------------------- 1 | package org.geysermc.geyser.api.event.lifecycle; 2 | 3 | import org.checkerframework.checker.nullness.qual.NonNull; 4 | import org.geysermc.event.Event; 5 | 6 | /** 7 | * Called on Geyser's startup when looking for custom skulls. Custom skulls must be registered through this event. 8 | *

9 | * This event will not be called if the "add-non-bedrock-items" setting is disabled in the Geyser config. 10 | */ 11 | public abstract class GeyserDefineCustomSkullsEvent implements Event { 12 | /** 13 | * The type of texture provided 14 | */ 15 | public enum SkullTextureType { 16 | USERNAME, 17 | UUID, 18 | PROFILE, 19 | SKIN_HASH 20 | } 21 | 22 | /** 23 | * Registers the given username, UUID, base64 encoded profile, or skin hash as a custom skull blocks 24 | * @param texture the username, UUID, base64 encoded profile, or skin hash 25 | * @param type the type of texture provided 26 | */ 27 | public abstract void register(@NonNull String texture, @NonNull SkullTextureType type); 28 | } 29 | -------------------------------------------------------------------------------- /api/src/main/java/org/geysermc/geyser/api/event/lifecycle/GeyserLoadResourcePacksEvent.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 2019-2022 GeyserMC. http://geysermc.org 3 | * 4 | * Permission is hereby granted, free of charge, to any person obtaining a copy 5 | * of this software and associated documentation files (the "Software"), to deal 6 | * in the Software without restriction, including without limitation the rights 7 | * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 8 | * copies of the Software, and to permit persons to whom the Software is 9 | * furnished to do so, subject to the following conditions: 10 | * 11 | * The above copyright notice and this permission notice shall be included in 12 | * all copies or substantial portions of the Software. 13 | * 14 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 15 | * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 16 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 17 | * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 18 | * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 19 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 20 | * THE SOFTWARE. 21 | * 22 | * @author GeyserMC 23 | * @link https://github.com/GeyserMC/Geyser 24 | */ 25 | 26 | package org.geysermc.geyser.api.event.lifecycle; 27 | 28 | import org.checkerframework.checker.nullness.qual.NonNull; 29 | import org.geysermc.event.Event; 30 | 31 | import java.nio.file.Path; 32 | import java.util.List; 33 | 34 | /** 35 | * @deprecated Use the {@link GeyserDefineResourcePacksEvent} instead. 36 | */ 37 | @Deprecated 38 | public record GeyserLoadResourcePacksEvent(@NonNull List resourcePacks) implements Event { 39 | } 40 | -------------------------------------------------------------------------------- /api/src/main/java/org/geysermc/geyser/api/event/lifecycle/GeyserShutdownEvent.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 2019-2022 GeyserMC. http://geysermc.org 3 | * 4 | * Permission is hereby granted, free of charge, to any person obtaining a copy 5 | * of this software and associated documentation files (the "Software"), to deal 6 | * in the Software without restriction, including without limitation the rights 7 | * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 8 | * copies of the Software, and to permit persons to whom the Software is 9 | * furnished to do so, subject to the following conditions: 10 | * 11 | * The above copyright notice and this permission notice shall be included in 12 | * all copies or substantial portions of the Software. 13 | * 14 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 15 | * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 16 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 17 | * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 18 | * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 19 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 20 | * THE SOFTWARE. 21 | * 22 | * @author GeyserMC 23 | * @link https://github.com/GeyserMC/Geyser 24 | */ 25 | 26 | package org.geysermc.geyser.api.event.lifecycle; 27 | 28 | import org.checkerframework.checker.nullness.qual.NonNull; 29 | import org.geysermc.event.Event; 30 | import org.geysermc.geyser.api.event.EventBus; 31 | import org.geysermc.geyser.api.event.EventRegistrar; 32 | import org.geysermc.geyser.api.extension.ExtensionManager; 33 | 34 | /** 35 | * Called when Geyser is shutting down. 36 | */ 37 | public record GeyserShutdownEvent(@NonNull ExtensionManager extensionManager, @NonNull EventBus eventBus) implements Event { 38 | } 39 | -------------------------------------------------------------------------------- /api/src/main/java/org/geysermc/geyser/api/pack/PathPackCodec.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 2019-2023 GeyserMC. http://geysermc.org 3 | * 4 | * Permission is hereby granted, free of charge, to any person obtaining a copy 5 | * of this software and associated documentation files (the "Software"), to deal 6 | * in the Software without restriction, including without limitation the rights 7 | * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 8 | * copies of the Software, and to permit persons to whom the Software is 9 | * furnished to do so, subject to the following conditions: 10 | * 11 | * The above copyright notice and this permission notice shall be included in 12 | * all copies or substantial portions of the Software. 13 | * 14 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 15 | * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 16 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 17 | * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 18 | * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 19 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 20 | * THE SOFTWARE. 21 | * 22 | * @author GeyserMC 23 | * @link https://github.com/GeyserMC/Geyser 24 | */ 25 | 26 | package org.geysermc.geyser.api.pack; 27 | 28 | import org.checkerframework.checker.nullness.qual.NonNull; 29 | 30 | import java.nio.file.Path; 31 | 32 | /** 33 | * Represents a pack codec that creates a resource 34 | * pack from a path on the filesystem. 35 | * @since 2.1.1 36 | */ 37 | public abstract class PathPackCodec extends PackCodec { 38 | 39 | /** 40 | * Gets the path of the resource pack. 41 | * 42 | * @return the path of the resource pack 43 | * @since 2.1.1 44 | */ 45 | @NonNull 46 | public abstract Path path(); 47 | } 48 | -------------------------------------------------------------------------------- /api/src/main/java/org/geysermc/geyser/api/skin/Cape.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 2024 GeyserMC. http://geysermc.org 3 | * 4 | * Permission is hereby granted, free of charge, to any person obtaining a copy 5 | * of this software and associated documentation files (the "Software"), to deal 6 | * in the Software without restriction, including without limitation the rights 7 | * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 8 | * copies of the Software, and to permit persons to whom the Software is 9 | * furnished to do so, subject to the following conditions: 10 | * 11 | * The above copyright notice and this permission notice shall be included in 12 | * all copies or substantial portions of the Software. 13 | * 14 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 15 | * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 16 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 17 | * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 18 | * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 19 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 20 | * THE SOFTWARE. 21 | * 22 | * @author GeyserMC 23 | * @link https://github.com/GeyserMC/Geyser 24 | */ 25 | 26 | package org.geysermc.geyser.api.skin; 27 | 28 | /** 29 | * Represents a cape. 30 | * 31 | * @param textureUrl The URL of the cape texture 32 | * @param capeId The ID of the cape 33 | * @param capeData The raw cape image data in ARGB format 34 | * @param failed If the cape failed to load, this is for things like fallback capes 35 | */ 36 | public record Cape(String textureUrl, String capeId, byte[] capeData, boolean failed) { 37 | public Cape(String textureUrl, String capeId, byte[] capeData) { 38 | this(textureUrl, capeId, capeData, false); 39 | } 40 | } 41 | -------------------------------------------------------------------------------- /api/src/main/java/org/geysermc/geyser/api/skin/Skin.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 2024 GeyserMC. http://geysermc.org 3 | * 4 | * Permission is hereby granted, free of charge, to any person obtaining a copy 5 | * of this software and associated documentation files (the "Software"), to deal 6 | * in the Software without restriction, including without limitation the rights 7 | * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 8 | * copies of the Software, and to permit persons to whom the Software is 9 | * furnished to do so, subject to the following conditions: 10 | * 11 | * The above copyright notice and this permission notice shall be included in 12 | * all copies or substantial portions of the Software. 13 | * 14 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 15 | * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 16 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 17 | * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 18 | * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 19 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 20 | * THE SOFTWARE. 21 | * 22 | * @author GeyserMC 23 | * @link https://github.com/GeyserMC/Geyser 24 | */ 25 | 26 | package org.geysermc.geyser.api.skin; 27 | 28 | /** 29 | * Represents a skin. 30 | * 31 | * @param textureUrl The URL/ID of the skin texture 32 | * @param skinData The raw skin image data in ARGB 33 | * @param failed If the skin failed to load, this is for things like fallback skins 34 | */ 35 | public record Skin(String textureUrl, byte[] skinData, boolean failed) { 36 | public Skin(String textureUrl, byte[] skinData) { 37 | this(textureUrl, skinData, false); 38 | } 39 | } 40 | -------------------------------------------------------------------------------- /api/src/main/java/org/geysermc/geyser/api/skin/SkinData.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 2024 GeyserMC. http://geysermc.org 3 | * 4 | * Permission is hereby granted, free of charge, to any person obtaining a copy 5 | * of this software and associated documentation files (the "Software"), to deal 6 | * in the Software without restriction, including without limitation the rights 7 | * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 8 | * copies of the Software, and to permit persons to whom the Software is 9 | * furnished to do so, subject to the following conditions: 10 | * 11 | * The above copyright notice and this permission notice shall be included in 12 | * all copies or substantial portions of the Software. 13 | * 14 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 15 | * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 16 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 17 | * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 18 | * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 19 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 20 | * THE SOFTWARE. 21 | * 22 | * @author GeyserMC 23 | * @link https://github.com/GeyserMC/Geyser 24 | */ 25 | 26 | package org.geysermc.geyser.api.skin; 27 | 28 | /** 29 | * Represents a full package of {@link Skin}, {@link Cape}, and {@link SkinGeometry}. 30 | */ 31 | public record SkinData(Skin skin, Cape cape, SkinGeometry geometry) { 32 | } 33 | -------------------------------------------------------------------------------- /bootstrap/bungeecord/src/main/java/org/geysermc/geyser/platform/bungeecord/GeyserBungeeMain.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 2019-2022 GeyserMC. http://geysermc.org 3 | * 4 | * Permission is hereby granted, free of charge, to any person obtaining a copy 5 | * of this software and associated documentation files (the "Software"), to deal 6 | * in the Software without restriction, including without limitation the rights 7 | * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 8 | * copies of the Software, and to permit persons to whom the Software is 9 | * furnished to do so, subject to the following conditions: 10 | * 11 | * The above copyright notice and this permission notice shall be included in 12 | * all copies or substantial portions of the Software. 13 | * 14 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 15 | * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 16 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 17 | * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 18 | * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 19 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 20 | * THE SOFTWARE. 21 | * 22 | * @author GeyserMC 23 | * @link https://github.com/GeyserMC/Geyser 24 | */ 25 | 26 | package org.geysermc.geyser.platform.bungeecord; 27 | 28 | import org.geysermc.geyser.GeyserMain; 29 | 30 | public class GeyserBungeeMain extends GeyserMain { 31 | 32 | public static void main(String[] args) { 33 | new GeyserBungeeMain().displayMessage(); 34 | } 35 | 36 | public String getPluginType() { 37 | return "BungeeCord"; 38 | } 39 | 40 | public String getPluginFolder() { 41 | return "plugins"; 42 | } 43 | } 44 | -------------------------------------------------------------------------------- /bootstrap/bungeecord/src/main/resources/bungee.yml: -------------------------------------------------------------------------------- 1 | main: org.geysermc.geyser.platform.bungeecord.GeyserBungeePlugin 2 | name: ${name}-BungeeCord 3 | author: ${author} 4 | website: ${url} 5 | version: ${version} -------------------------------------------------------------------------------- /bootstrap/mod/build.gradle.kts: -------------------------------------------------------------------------------- 1 | plugins { 2 | id("geyser.modded-conventions") 3 | } 4 | 5 | architectury { 6 | common("neoforge", "fabric") 7 | } 8 | 9 | loom { 10 | mixin.defaultRefmapName.set("geyser-refmap.json") 11 | } 12 | 13 | afterEvaluate { 14 | // We don't need these 15 | tasks.named("remapModrinthJar").configure { 16 | enabled = false 17 | } 18 | } 19 | 20 | dependencies { 21 | api(projects.core) 22 | compileOnly(libs.mixin) 23 | compileOnly(libs.mixinextras) 24 | 25 | // Only here to suppress "unknown enum constant EnvType.CLIENT" warnings. DO NOT USE! 26 | compileOnly(libs.fabric.loader) 27 | } 28 | -------------------------------------------------------------------------------- /bootstrap/mod/fabric/gradle.properties: -------------------------------------------------------------------------------- 1 | loom.platform=fabric -------------------------------------------------------------------------------- /bootstrap/mod/fabric/src/main/java/org/geysermc/geyser/platform/fabric/GeyserFabricMain.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 2019-2022 GeyserMC. http://geysermc.org 3 | * 4 | * Permission is hereby granted, free of charge, to any person obtaining a copy 5 | * of this software and associated documentation files (the "Software"), to deal 6 | * in the Software without restriction, including without limitation the rights 7 | * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 8 | * copies of the Software, and to permit persons to whom the Software is 9 | * furnished to do so, subject to the following conditions: 10 | * 11 | * The above copyright notice and this permission notice shall be included in 12 | * all copies or substantial portions of the Software. 13 | * 14 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 15 | * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 16 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 17 | * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 18 | * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 19 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 20 | * THE SOFTWARE. 21 | * 22 | * @author GeyserMC 23 | * @link https://github.com/GeyserMC/Geyser 24 | */ 25 | 26 | package org.geysermc.geyser.platform.fabric; 27 | 28 | import org.geysermc.geyser.GeyserMain; 29 | 30 | public class GeyserFabricMain extends GeyserMain { 31 | 32 | public static void main(String[] args) { 33 | new GeyserFabricMain().displayMessage(); 34 | } 35 | 36 | @Override 37 | public String getPluginType() { 38 | return "Fabric"; 39 | } 40 | 41 | @Override 42 | public String getPluginFolder() { 43 | return "mods"; 44 | } 45 | } 46 | -------------------------------------------------------------------------------- /bootstrap/mod/fabric/src/main/resources/fabric.mod.json: -------------------------------------------------------------------------------- 1 | { 2 | "schemaVersion": 1, 3 | "id": "${id}-fabric", 4 | "version": "${version}", 5 | "name": "${name}-Fabric", 6 | "description": "A bridge/proxy allowing you to connect to Minecraft: Java Edition servers with Minecraft: Bedrock Edition. ", 7 | "authors": [ 8 | "${author}" 9 | ], 10 | "contact": { 11 | "website": "${url}", 12 | "repo": "https://github.com/GeyserMC/Geyser" 13 | }, 14 | "license": "MIT", 15 | "icon": "assets/geyser/icon.png", 16 | "environment": "*", 17 | "entrypoints": { 18 | "main": [ 19 | "org.geysermc.geyser.platform.fabric.GeyserFabricBootstrap" 20 | ] 21 | }, 22 | "mixins": [ 23 | "geyser.mixins.json" 24 | ], 25 | "depends": { 26 | "fabricloader": ">=0.16.7", 27 | "fabric-api": "*", 28 | "minecraft": ">=1.21.5" 29 | } 30 | } 31 | -------------------------------------------------------------------------------- /bootstrap/mod/neoforge/gradle.properties: -------------------------------------------------------------------------------- 1 | loom.platform=neoforge -------------------------------------------------------------------------------- /bootstrap/mod/neoforge/src/main/java/org/geysermc/geyser/platform/neoforge/GeyserNeoForgeMain.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 2019-2023 GeyserMC. http://geysermc.org 3 | * 4 | * Permission is hereby granted, free of charge, to any person obtaining a copy 5 | * of this software and associated documentation files (the "Software"), to deal 6 | * in the Software without restriction, including without limitation the rights 7 | * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 8 | * copies of the Software, and to permit persons to whom the Software is 9 | * furnished to do so, subject to the following conditions: 10 | * 11 | * The above copyright notice and this permission notice shall be included in 12 | * all copies or substantial portions of the Software. 13 | * 14 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 15 | * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 16 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 17 | * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 18 | * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 19 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 20 | * THE SOFTWARE. 21 | * 22 | * @author GeyserMC 23 | * @link https://github.com/GeyserMC/Geyser 24 | */ 25 | 26 | package org.geysermc.geyser.platform.neoforge; 27 | 28 | import org.geysermc.geyser.GeyserMain; 29 | 30 | public class GeyserNeoForgeMain extends GeyserMain { 31 | 32 | public static void main(String[] args) { 33 | new GeyserNeoForgeMain().displayMessage(); 34 | } 35 | 36 | @Override 37 | public String getPluginType() { 38 | return "NeoForge"; 39 | } 40 | 41 | @Override 42 | public String getPluginFolder() { 43 | return "mods"; 44 | } 45 | } 46 | -------------------------------------------------------------------------------- /bootstrap/mod/neoforge/src/main/java/org/geysermc/geyser/platform/neoforge/ModConstants.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 2019-2023 GeyserMC. http://geysermc.org 3 | * 4 | * Permission is hereby granted, free of charge, to any person obtaining a copy 5 | * of this software and associated documentation files (the "Software"), to deal 6 | * in the Software without restriction, including without limitation the rights 7 | * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 8 | * copies of the Software, and to permit persons to whom the Software is 9 | * furnished to do so, subject to the following conditions: 10 | * 11 | * The above copyright notice and this permission notice shall be included in 12 | * all copies or substantial portions of the Software. 13 | * 14 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 15 | * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 16 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 17 | * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 18 | * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 19 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 20 | * THE SOFTWARE. 21 | * 22 | * @author GeyserMC 23 | * @link https://github.com/GeyserMC/Geyser 24 | */ 25 | 26 | package org.geysermc.geyser.platform.neoforge; 27 | 28 | public class ModConstants { 29 | public static final String MOD_ID = "geyser_neoforge"; 30 | } 31 | -------------------------------------------------------------------------------- /bootstrap/mod/neoforge/src/main/resources/META-INF/neoforge.mods.toml: -------------------------------------------------------------------------------- 1 | modLoader="javafml" 2 | loaderVersion="[1,)" 3 | license="MIT" 4 | [[mods]] 5 | modId="geyser_neoforge" 6 | version="${version}" 7 | displayName="Geyser" 8 | displayURL="https://geysermc.org/" 9 | logoFile= "../assets/geyser/icon.png" 10 | authors="GeyserMC" 11 | description="${description}" 12 | [[mixins]] 13 | config = "geyser.mixins.json" 14 | [[mixins]] 15 | config = "geyser_neoforge.mixins.json" 16 | [[dependencies.geyser_neoforge]] 17 | modId="neoforge" 18 | type="required" 19 | versionRange="[21.5.0-beta,)" 20 | ordering="NONE" 21 | side="BOTH" 22 | [[dependencies.geyser_neoforge]] 23 | modId="minecraft" 24 | type="required" 25 | versionRange="[1.21.5,)" 26 | ordering="NONE" 27 | side="BOTH" 28 | -------------------------------------------------------------------------------- /bootstrap/mod/neoforge/src/main/resources/geyser_neoforge.mixins.json: -------------------------------------------------------------------------------- 1 | { 2 | "required": true, 3 | "minVersion": "0.8", 4 | "package": "org.geysermc.geyser.platform.neoforge.mixin", 5 | "compatibilityLevel": "JAVA_17", 6 | "mixins": [ 7 | "PermissionNodeMixin" 8 | ], 9 | "injectors": { 10 | "defaultRequire": 1 11 | } 12 | } 13 | -------------------------------------------------------------------------------- /bootstrap/mod/src/main/java/org/geysermc/geyser/platform/mod/GeyserChannelGetter.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 2019-2023 GeyserMC. http://geysermc.org 3 | * 4 | * Permission is hereby granted, free of charge, to any person obtaining a copy 5 | * of this software and associated documentation files (the "Software"), to deal 6 | * in the Software without restriction, including without limitation the rights 7 | * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 8 | * copies of the Software, and to permit persons to whom the Software is 9 | * furnished to do so, subject to the following conditions: 10 | * 11 | * The above copyright notice and this permission notice shall be included in 12 | * all copies or substantial portions of the Software. 13 | * 14 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 15 | * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 16 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 17 | * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 18 | * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 19 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 20 | * THE SOFTWARE. 21 | * 22 | * @author GeyserMC 23 | * @link https://github.com/GeyserMC/Geyser 24 | */ 25 | 26 | package org.geysermc.geyser.platform.mod; 27 | 28 | import io.netty.channel.ChannelFuture; 29 | 30 | import java.util.List; 31 | 32 | /** 33 | * Represents a getter to the server channels in the connection listener class. 34 | */ 35 | public interface GeyserChannelGetter { 36 | 37 | /** 38 | * Returns the channels. 39 | * 40 | * @return The channels. 41 | */ 42 | List geyser$getChannels(); 43 | } 44 | -------------------------------------------------------------------------------- /bootstrap/mod/src/main/resources/geyser.mixins.json: -------------------------------------------------------------------------------- 1 | { 2 | "required": true, 3 | "minVersion": "0.8", 4 | "package": "org.geysermc.geyser.platform.mod.mixin", 5 | "compatibilityLevel": "JAVA_17", 6 | "mixins": [ 7 | "server.BlockPlaceMixin", 8 | "server.PistonBaseBlockMixin", 9 | "server.ServerConnectionListenerMixin" 10 | ], 11 | "server": [ 12 | "server.DedicatedServerMixin" 13 | ], 14 | "client": [ 15 | "client.IntegratedServerMixin" 16 | ], 17 | "injectors": { 18 | "defaultRequire": 1 19 | } 20 | } 21 | -------------------------------------------------------------------------------- /bootstrap/spigot/src/main/java/org/geysermc/geyser/platform/spigot/GeyserSpigotMain.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 2019-2022 GeyserMC. http://geysermc.org 3 | * 4 | * Permission is hereby granted, free of charge, to any person obtaining a copy 5 | * of this software and associated documentation files (the "Software"), to deal 6 | * in the Software without restriction, including without limitation the rights 7 | * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 8 | * copies of the Software, and to permit persons to whom the Software is 9 | * furnished to do so, subject to the following conditions: 10 | * 11 | * The above copyright notice and this permission notice shall be included in 12 | * all copies or substantial portions of the Software. 13 | * 14 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 15 | * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 16 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 17 | * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 18 | * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 19 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 20 | * THE SOFTWARE. 21 | * 22 | * @author GeyserMC 23 | * @link https://github.com/GeyserMC/Geyser 24 | */ 25 | 26 | package org.geysermc.geyser.platform.spigot; 27 | 28 | import org.geysermc.geyser.GeyserMain; 29 | 30 | public class GeyserSpigotMain extends GeyserMain { 31 | 32 | public static void main(String[] args) { 33 | new GeyserSpigotMain().displayMessage(); 34 | } 35 | 36 | public String getPluginType() { 37 | return "Spigot or Paper (recommended)"; 38 | } 39 | 40 | public String getPluginFolder() { 41 | return "plugins"; 42 | } 43 | } 44 | -------------------------------------------------------------------------------- /bootstrap/spigot/src/main/resources/plugin.yml: -------------------------------------------------------------------------------- 1 | main: org.geysermc.geyser.platform.spigot.GeyserSpigotPlugin 2 | name: ${name}-Spigot 3 | author: ${author} 4 | website: ${url} 5 | version: ${version} 6 | softdepend: ["ViaVersion", "floodgate"] 7 | api-version: 1.13 8 | folia-supported: true 9 | -------------------------------------------------------------------------------- /bootstrap/standalone/build.gradle.kts: -------------------------------------------------------------------------------- 1 | import com.github.jengelman.gradle.plugins.shadow.transformers.Log4j2PluginsCacheFileTransformer 2 | 3 | plugins { 4 | application 5 | id("geyser.platform-conventions") 6 | } 7 | 8 | dependencies { 9 | api(projects.core) 10 | 11 | implementation(libs.terminalconsoleappender) { 12 | exclude("org.apache.logging.log4j") 13 | exclude("org.jline") 14 | } 15 | 16 | implementation(libs.bundles.jline) 17 | 18 | implementation(libs.bundles.log4j) 19 | } 20 | 21 | application { 22 | mainClass.set("org.geysermc.geyser.platform.standalone.GeyserStandaloneBootstrap") 23 | } 24 | 25 | tasks.named("jar") { 26 | manifest { 27 | // log4j provides multi-release java 9 code which resolves https://github.com/GeyserMC/Geyser/issues/3693 28 | attributes("Multi-Release" to true) 29 | } 30 | } 31 | 32 | tasks.withType { 33 | archiveBaseName.set("Geyser-Standalone") 34 | 35 | // temporary measure - incubator's io_uring is not compatible with 4.2.1 36 | dependencies { 37 | exclude(dependency("io.netty.incubator:.*")) 38 | } 39 | 40 | transform(Log4j2PluginsCacheFileTransformer()) 41 | } 42 | 43 | tasks.named("run") { 44 | val dir = projectDir.resolve("run") 45 | dir.mkdirs() 46 | jvmArgs("-Dio.netty.leakDetection.level=PARANOID") 47 | workingDir = dir 48 | 49 | standardInput = System.`in` 50 | } 51 | -------------------------------------------------------------------------------- /bootstrap/standalone/src/main/java/org/geysermc/geyser/platform/standalone/GeyserStandaloneDumpInfo.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 2019-2022 GeyserMC. http://geysermc.org 3 | * 4 | * Permission is hereby granted, free of charge, to any person obtaining a copy 5 | * of this software and associated documentation files (the "Software"), to deal 6 | * in the Software without restriction, including without limitation the rights 7 | * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 8 | * copies of the Software, and to permit persons to whom the Software is 9 | * furnished to do so, subject to the following conditions: 10 | * 11 | * The above copyright notice and this permission notice shall be included in 12 | * all copies or substantial portions of the Software. 13 | * 14 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 15 | * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 16 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 17 | * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 18 | * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 19 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 20 | * THE SOFTWARE. 21 | * 22 | * @author GeyserMC 23 | * @link https://github.com/GeyserMC/Geyser 24 | */ 25 | 26 | package org.geysermc.geyser.platform.standalone; 27 | 28 | import lombok.Getter; 29 | import org.geysermc.geyser.dump.BootstrapDumpInfo; 30 | 31 | @Getter 32 | public class GeyserStandaloneDumpInfo extends BootstrapDumpInfo { 33 | private final boolean isGui; 34 | 35 | GeyserStandaloneDumpInfo(GeyserStandaloneBootstrap bootstrap) { 36 | super(); 37 | this.isGui = bootstrap.isUseGui(); 38 | } 39 | } 40 | -------------------------------------------------------------------------------- /bootstrap/standalone/src/main/resources/log4j2.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | -------------------------------------------------------------------------------- /bootstrap/velocity/src/main/java/org/geysermc/geyser/platform/velocity/GeyserVelocityMain.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 2019-2022 GeyserMC. http://geysermc.org 3 | * 4 | * Permission is hereby granted, free of charge, to any person obtaining a copy 5 | * of this software and associated documentation files (the "Software"), to deal 6 | * in the Software without restriction, including without limitation the rights 7 | * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 8 | * copies of the Software, and to permit persons to whom the Software is 9 | * furnished to do so, subject to the following conditions: 10 | * 11 | * The above copyright notice and this permission notice shall be included in 12 | * all copies or substantial portions of the Software. 13 | * 14 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 15 | * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 16 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 17 | * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 18 | * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 19 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 20 | * THE SOFTWARE. 21 | * 22 | * @author GeyserMC 23 | * @link https://github.com/GeyserMC/Geyser 24 | */ 25 | 26 | package org.geysermc.geyser.platform.velocity; 27 | 28 | import org.geysermc.geyser.GeyserMain; 29 | 30 | public class GeyserVelocityMain extends GeyserMain { 31 | 32 | public static void main(String[] args) { 33 | new GeyserVelocityMain().displayMessage(); 34 | } 35 | 36 | public String getPluginType() { 37 | return "Velocity"; 38 | } 39 | 40 | public String getPluginFolder() { 41 | return "plugins"; 42 | } 43 | } 44 | -------------------------------------------------------------------------------- /bootstrap/viaproxy/build.gradle.kts: -------------------------------------------------------------------------------- 1 | plugins { 2 | id("geyser.platform-conventions") 3 | } 4 | 5 | dependencies { 6 | api(projects.core) 7 | 8 | compileOnlyApi(libs.viaproxy) 9 | } 10 | 11 | platformRelocate("net.kyori") 12 | platformRelocate("org.yaml") 13 | platformRelocate("it.unimi.dsi.fastutil") 14 | platformRelocate("org.cloudburstmc.netty") 15 | platformRelocate("org.incendo") 16 | platformRelocate("io.leangen.geantyref") // provided by cloud, should also be relocated 17 | 18 | // These dependencies are already present on the platform 19 | provided(libs.viaproxy) 20 | 21 | tasks.withType { 22 | manifest.attributes["Main-Class"] = "org.geysermc.geyser.platform.viaproxy.GeyserViaProxyMain" 23 | } 24 | 25 | tasks.withType { 26 | archiveBaseName.set("Geyser-ViaProxy") 27 | 28 | dependencies { 29 | exclude(dependency("com.google.*:.*")) 30 | exclude(dependency("io.netty:.*")) 31 | exclude(dependency("io.netty.incubator:.*")) 32 | exclude(dependency("org.slf4j:.*")) 33 | exclude(dependency("org.ow2.asm:.*")) 34 | } 35 | } 36 | -------------------------------------------------------------------------------- /bootstrap/viaproxy/src/main/java/org/geysermc/geyser/platform/viaproxy/GeyserViaProxyMain.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 2019-2023 GeyserMC. http://geysermc.org 3 | * 4 | * Permission is hereby granted, free of charge, to any person obtaining a copy 5 | * of this software and associated documentation files (the "Software"), to deal 6 | * in the Software without restriction, including without limitation the rights 7 | * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 8 | * copies of the Software, and to permit persons to whom the Software is 9 | * furnished to do so, subject to the following conditions: 10 | * 11 | * The above copyright notice and this permission notice shall be included in 12 | * all copies or substantial portions of the Software. 13 | * 14 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 15 | * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 16 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 17 | * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 18 | * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 19 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 20 | * THE SOFTWARE. 21 | * 22 | * @author GeyserMC 23 | * @link https://github.com/GeyserMC/Geyser 24 | */ 25 | 26 | package org.geysermc.geyser.platform.viaproxy; 27 | 28 | import org.geysermc.geyser.GeyserMain; 29 | 30 | public class GeyserViaProxyMain extends GeyserMain { 31 | 32 | public static void main(String[] args) { 33 | new GeyserViaProxyMain().displayMessage(); 34 | } 35 | 36 | public String getPluginType() { 37 | return "ViaProxy"; 38 | } 39 | 40 | public String getPluginFolder() { 41 | return "plugins"; 42 | } 43 | 44 | } 45 | -------------------------------------------------------------------------------- /bootstrap/viaproxy/src/main/resources/viaproxy.yml: -------------------------------------------------------------------------------- 1 | name: "${name}-ViaProxy" 2 | version: "${version}" 3 | author: "${author}" 4 | main: "org.geysermc.geyser.platform.viaproxy.GeyserViaProxyPlugin" 5 | min-version: "3.3.2" 6 | -------------------------------------------------------------------------------- /build-logic/build.gradle.kts: -------------------------------------------------------------------------------- 1 | plugins { 2 | `kotlin-dsl` 3 | } 4 | 5 | repositories { 6 | gradlePluginPortal() 7 | 8 | maven("https://repo.opencollab.dev/maven-snapshots/") 9 | maven("https://maven.fabricmc.net/") 10 | maven("https://maven.neoforged.net/releases") 11 | maven("https://maven.architectury.dev/") 12 | } 13 | 14 | dependencies { 15 | // This is for the LibsAccessor.kt hack 16 | // this is OK as long as the same version catalog is used in the main build and build-logic 17 | // see https://github.com/gradle/gradle/issues/15383#issuecomment-779893192 18 | implementation(files(libs.javaClass.superclass.protectionDomain.codeSource.location)) 19 | 20 | // This is for applying plugins, and using the version from the libs.versions.toml 21 | // Unfortunately they still need to be applied by their string name in the convention scripts. 22 | implementation(libs.lombok) 23 | implementation(libs.indra) 24 | implementation(libs.shadow) 25 | implementation(libs.architectury.plugin) 26 | implementation(libs.architectury.loom) 27 | implementation(libs.minotaur) 28 | } 29 | -------------------------------------------------------------------------------- /build-logic/settings.gradle.kts: -------------------------------------------------------------------------------- 1 | @file:Suppress("UnstableApiUsage") 2 | 3 | dependencyResolutionManagement { 4 | versionCatalogs { 5 | create("libs") { 6 | from(files("../gradle/libs.versions.toml")) 7 | } 8 | } 9 | } 10 | 11 | rootProject.name = "build-logic" 12 | -------------------------------------------------------------------------------- /build-logic/src/main/kotlin/LibsAccessor.kt: -------------------------------------------------------------------------------- 1 | import org.gradle.accessors.dm.LibrariesForLibs 2 | import org.gradle.api.Project 3 | import org.gradle.kotlin.dsl.getByType 4 | 5 | val Project.libs: LibrariesForLibs 6 | get() = rootProject.extensions.getByType() -------------------------------------------------------------------------------- /build-logic/src/main/kotlin/geyser.modrinth-uploading-conventions.gradle.kts: -------------------------------------------------------------------------------- 1 | plugins { 2 | id("com.modrinth.minotaur") 3 | } 4 | 5 | // Ensure that the readme is synched 6 | tasks.modrinth.get().dependsOn(tasks.modrinthSyncBody) 7 | 8 | modrinth { 9 | token.set(System.getenv("MODRINTH_TOKEN") ?: "") // Even though this is the default value, apparently this prevents GitHub Actions caching the token? 10 | debugMode.set(System.getenv("MODRINTH_TOKEN") == null) 11 | projectId.set("geyser") 12 | versionName.set(versionName(project)) 13 | versionNumber.set(projectVersion(project)) 14 | versionType.set("beta") 15 | changelog.set(System.getenv("CHANGELOG") ?: "") 16 | gameVersions.add(libs.minecraft.get().version as String) 17 | failSilently.set(true) 18 | 19 | syncBodyFrom.set(rootProject.file("README.md").readText()) 20 | } 21 | -------------------------------------------------------------------------------- /build-logic/src/main/kotlin/geyser.platform-conventions.gradle.kts: -------------------------------------------------------------------------------- 1 | plugins { 2 | id("geyser.publish-conventions") 3 | id("io.freefair.lombok") 4 | } 5 | 6 | tasks { 7 | processResources { 8 | // Spigot, BungeeCord, Velocity, Fabric, ViaProxy, NeoForge 9 | filesMatching(listOf("plugin.yml", "bungee.yml", "velocity-plugin.json", "fabric.mod.json", "viaproxy.yml", "META-INF/neoforge.mods.toml")) { 10 | expand( 11 | "id" to "geyser", 12 | "name" to "Geyser", 13 | "version" to project.version, 14 | "description" to project.description, 15 | "url" to "https://geysermc.org", 16 | "author" to "GeyserMC" 17 | ) 18 | } 19 | } 20 | } 21 | -------------------------------------------------------------------------------- /build-logic/src/main/kotlin/geyser.publish-conventions.gradle.kts: -------------------------------------------------------------------------------- 1 | plugins { 2 | id("geyser.shadow-conventions") 3 | id("net.kyori.indra.publishing") 4 | } 5 | 6 | indra { 7 | publishSnapshotsTo("geysermc", "https://repo.opencollab.dev/maven-snapshots") 8 | publishReleasesTo("geysermc", "https://repo.opencollab.dev/maven-releases") 9 | } 10 | 11 | publishing { 12 | // skip shadow jar from publishing. Workaround for https://github.com/johnrengelman/shadow/issues/651 13 | val javaComponent = project.components["java"] as AdhocComponentWithVariants 14 | javaComponent.withVariantsFromConfiguration(configurations["shadowRuntimeElements"]) { skip() } 15 | } -------------------------------------------------------------------------------- /build-logic/src/main/kotlin/geyser.shadow-conventions.gradle.kts: -------------------------------------------------------------------------------- 1 | import com.github.jengelman.gradle.plugins.shadow.tasks.ShadowJar 2 | 3 | plugins { 4 | id("geyser.base-conventions") 5 | id("com.github.johnrengelman.shadow") 6 | } 7 | 8 | tasks { 9 | named("jar") { 10 | from(project.rootProject.file("LICENSE")) 11 | } 12 | val shadowJar = named("shadowJar") { 13 | archiveBaseName.set(project.name) 14 | archiveVersion.set("") 15 | archiveClassifier.set("") 16 | 17 | val sJar: ShadowJar = this 18 | 19 | doFirst { 20 | providedDependencies[project.name]?.forEach { string -> 21 | sJar.dependencies { 22 | println("Excluding $string from ${project.name}") 23 | exclude(dependency(string)) 24 | } 25 | } 26 | 27 | sJar.dependencies { 28 | exclude(dependency("org.checkerframework:checker-qual:.*")) 29 | exclude(dependency("org.jetbrains:annotations:.*")) 30 | } 31 | } 32 | } 33 | named("build") { 34 | dependsOn(shadowJar) 35 | } 36 | } -------------------------------------------------------------------------------- /build.gradle.kts: -------------------------------------------------------------------------------- 1 | plugins { 2 | // Ensure AP works in eclipse (no effect on other IDEs) 3 | eclipse 4 | id("geyser.base-conventions") 5 | } 6 | -------------------------------------------------------------------------------- /common/build.gradle.kts: -------------------------------------------------------------------------------- 1 | plugins { 2 | id("geyser.publish-conventions") 3 | id("io.freefair.lombok") 4 | } 5 | 6 | dependencies { 7 | api(libs.cumulus) 8 | api(libs.gson) 9 | } 10 | 11 | indra { 12 | javaVersions { 13 | target(8) 14 | } 15 | } 16 | -------------------------------------------------------------------------------- /common/src/main/java/org/geysermc/floodgate/crypto/Base64Topping.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 2019-2022 GeyserMC. http://geysermc.org 3 | * 4 | * Permission is hereby granted, free of charge, to any person obtaining a copy 5 | * of this software and associated documentation files (the "Software"), to deal 6 | * in the Software without restriction, including without limitation the rights 7 | * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 8 | * copies of the Software, and to permit persons to whom the Software is 9 | * furnished to do so, subject to the following conditions: 10 | * 11 | * The above copyright notice and this permission notice shall be included in 12 | * all copies or substantial portions of the Software. 13 | * 14 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 15 | * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 16 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 17 | * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 18 | * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 19 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 20 | * THE SOFTWARE. 21 | * 22 | * @author GeyserMC 23 | * @link https://github.com/GeyserMC/Geyser 24 | */ 25 | 26 | package org.geysermc.floodgate.crypto; 27 | 28 | import java.util.Base64; 29 | 30 | public final class Base64Topping implements Topping { 31 | @Override 32 | public byte[] encode(byte[] data) { 33 | return Base64.getEncoder().encode(data); 34 | } 35 | 36 | @Override 37 | public byte[] decode(byte[] data) { 38 | return Base64.getDecoder().decode(data); 39 | } 40 | } 41 | -------------------------------------------------------------------------------- /common/src/main/java/org/geysermc/floodgate/crypto/KeyProducer.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 2019-2022 GeyserMC. http://geysermc.org 3 | * 4 | * Permission is hereby granted, free of charge, to any person obtaining a copy 5 | * of this software and associated documentation files (the "Software"), to deal 6 | * in the Software without restriction, including without limitation the rights 7 | * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 8 | * copies of the Software, and to permit persons to whom the Software is 9 | * furnished to do so, subject to the following conditions: 10 | * 11 | * The above copyright notice and this permission notice shall be included in 12 | * all copies or substantial portions of the Software. 13 | * 14 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 15 | * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 16 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 17 | * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 18 | * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 19 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 20 | * THE SOFTWARE. 21 | * 22 | * @author GeyserMC 23 | * @link https://github.com/GeyserMC/Geyser 24 | */ 25 | 26 | package org.geysermc.floodgate.crypto; 27 | 28 | import java.io.IOException; 29 | import java.nio.file.Files; 30 | import java.nio.file.Path; 31 | import java.security.Key; 32 | 33 | public interface KeyProducer { 34 | @SuppressWarnings("unused") Key produce(); 35 | Key produceFrom(byte[] keyFileData); 36 | 37 | default Key produceFrom(Path keyFileLocation) throws IOException { 38 | return produceFrom(Files.readAllBytes(keyFileLocation)); 39 | } 40 | } 41 | -------------------------------------------------------------------------------- /common/src/main/java/org/geysermc/floodgate/crypto/Topping.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 2019-2022 GeyserMC. http://geysermc.org 3 | * 4 | * Permission is hereby granted, free of charge, to any person obtaining a copy 5 | * of this software and associated documentation files (the "Software"), to deal 6 | * in the Software without restriction, including without limitation the rights 7 | * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 8 | * copies of the Software, and to permit persons to whom the Software is 9 | * furnished to do so, subject to the following conditions: 10 | * 11 | * The above copyright notice and this permission notice shall be included in 12 | * all copies or substantial portions of the Software. 13 | * 14 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 15 | * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 16 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 17 | * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 18 | * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 19 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 20 | * THE SOFTWARE. 21 | * 22 | * @author GeyserMC 23 | * @link https://github.com/GeyserMC/Geyser 24 | */ 25 | 26 | package org.geysermc.floodgate.crypto; 27 | 28 | public interface Topping { 29 | byte[] encode(byte[] data); 30 | byte[] decode(byte[] data); 31 | } 32 | -------------------------------------------------------------------------------- /common/src/main/java/org/geysermc/floodgate/news/data/CheckAfterData.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 2019-2022 GeyserMC. http://geysermc.org 3 | * 4 | * Permission is hereby granted, free of charge, to any person obtaining a copy 5 | * of this software and associated documentation files (the "Software"), to deal 6 | * in the Software without restriction, including without limitation the rights 7 | * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 8 | * copies of the Software, and to permit persons to whom the Software is 9 | * furnished to do so, subject to the following conditions: 10 | * 11 | * The above copyright notice and this permission notice shall be included in 12 | * all copies or substantial portions of the Software. 13 | * 14 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 15 | * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 16 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 17 | * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 18 | * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 19 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 20 | * THE SOFTWARE. 21 | * 22 | * @author GeyserMC 23 | * @link https://github.com/GeyserMC/Geyser 24 | */ 25 | 26 | package org.geysermc.floodgate.news.data; 27 | 28 | import com.google.gson.JsonObject; 29 | 30 | public final class CheckAfterData implements ItemData { 31 | private long checkAfter; 32 | 33 | private CheckAfterData() {} 34 | 35 | public static CheckAfterData read(JsonObject data) { 36 | CheckAfterData checkAfterData = new CheckAfterData(); 37 | checkAfterData.checkAfter = data.get("check_after").getAsLong(); 38 | return checkAfterData; 39 | } 40 | 41 | public long getCheckAfter() { 42 | return checkAfter; 43 | } 44 | } 45 | -------------------------------------------------------------------------------- /common/src/main/java/org/geysermc/floodgate/news/data/ItemData.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 2019-2022 GeyserMC. http://geysermc.org 3 | * 4 | * Permission is hereby granted, free of charge, to any person obtaining a copy 5 | * of this software and associated documentation files (the "Software"), to deal 6 | * in the Software without restriction, including without limitation the rights 7 | * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 8 | * copies of the Software, and to permit persons to whom the Software is 9 | * furnished to do so, subject to the following conditions: 10 | * 11 | * The above copyright notice and this permission notice shall be included in 12 | * all copies or substantial portions of the Software. 13 | * 14 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 15 | * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 16 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 17 | * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 18 | * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 19 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 20 | * THE SOFTWARE. 21 | * 22 | * @author GeyserMC 23 | * @link https://github.com/GeyserMC/Geyser 24 | */ 25 | 26 | package org.geysermc.floodgate.news.data; 27 | 28 | public interface ItemData { 29 | } 30 | -------------------------------------------------------------------------------- /common/src/main/java/org/geysermc/floodgate/util/FloodgateInfoHolder.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 2019-2022 GeyserMC. http://geysermc.org 3 | * 4 | * Permission is hereby granted, free of charge, to any person obtaining a copy 5 | * of this software and associated documentation files (the "Software"), to deal 6 | * in the Software without restriction, including without limitation the rights 7 | * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 8 | * copies of the Software, and to permit persons to whom the Software is 9 | * furnished to do so, subject to the following conditions: 10 | * 11 | * The above copyright notice and this permission notice shall be included in 12 | * all copies or substantial portions of the Software. 13 | * 14 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 15 | * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 16 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 17 | * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 18 | * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 19 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 20 | * THE SOFTWARE. 21 | * 22 | * @author GeyserMC 23 | * @link https://github.com/GeyserMC/Geyser 24 | */ 25 | 26 | package org.geysermc.floodgate.util; 27 | 28 | import lombok.Getter; 29 | import lombok.Setter; 30 | 31 | import java.util.Properties; 32 | 33 | public final class FloodgateInfoHolder { 34 | @Getter 35 | @Setter 36 | private static Object config; 37 | @Getter 38 | @Setter 39 | private static Properties gitProperties; 40 | } 41 | -------------------------------------------------------------------------------- /common/src/main/java/org/geysermc/floodgate/util/InputMode.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 2019-2022 GeyserMC. http://geysermc.org 3 | * 4 | * Permission is hereby granted, free of charge, to any person obtaining a copy 5 | * of this software and associated documentation files (the "Software"), to deal 6 | * in the Software without restriction, including without limitation the rights 7 | * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 8 | * copies of the Software, and to permit persons to whom the Software is 9 | * furnished to do so, subject to the following conditions: 10 | * 11 | * The above copyright notice and this permission notice shall be included in 12 | * all copies or substantial portions of the Software. 13 | * 14 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 15 | * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 16 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 17 | * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 18 | * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 19 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 20 | * THE SOFTWARE. 21 | * 22 | * @author GeyserMC 23 | * @link https://github.com/GeyserMC/Geyser 24 | */ 25 | 26 | package org.geysermc.floodgate.util; 27 | 28 | public enum InputMode { 29 | UNKNOWN, 30 | KEYBOARD_MOUSE, 31 | TOUCH, 32 | CONTROLLER, 33 | VR; 34 | 35 | private static final InputMode[] VALUES = values(); 36 | 37 | /** 38 | * Get the InputMode instance from the identifier. 39 | * 40 | * @param id the InputMode identifier 41 | * @return The InputMode or {@link #UNKNOWN} if the DeviceOs wasn't found 42 | */ 43 | public static InputMode fromId(int id) { 44 | return VALUES.length > id ? VALUES[id] : VALUES[0]; 45 | } 46 | } -------------------------------------------------------------------------------- /common/src/main/java/org/geysermc/floodgate/util/InvalidFormatException.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 2019-2022 GeyserMC. http://geysermc.org 3 | * 4 | * Permission is hereby granted, free of charge, to any person obtaining a copy 5 | * of this software and associated documentation files (the "Software"), to deal 6 | * in the Software without restriction, including without limitation the rights 7 | * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 8 | * copies of the Software, and to permit persons to whom the Software is 9 | * furnished to do so, subject to the following conditions: 10 | * 11 | * The above copyright notice and this permission notice shall be included in 12 | * all copies or substantial portions of the Software. 13 | * 14 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 15 | * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 16 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 17 | * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 18 | * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 19 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 20 | * THE SOFTWARE. 21 | * 22 | * @author GeyserMC 23 | * @link https://github.com/GeyserMC/Geyser 24 | */ 25 | 26 | package org.geysermc.floodgate.util; 27 | 28 | public class InvalidFormatException extends Exception { 29 | 30 | private static final long serialVersionUID = 1L; 31 | 32 | public InvalidFormatException(String message) { 33 | super(message); 34 | } 35 | } 36 | -------------------------------------------------------------------------------- /common/src/main/java/org/geysermc/floodgate/util/UiProfile.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 2019-2022 GeyserMC. http://geysermc.org 3 | * 4 | * Permission is hereby granted, free of charge, to any person obtaining a copy 5 | * of this software and associated documentation files (the "Software"), to deal 6 | * in the Software without restriction, including without limitation the rights 7 | * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 8 | * copies of the Software, and to permit persons to whom the Software is 9 | * furnished to do so, subject to the following conditions: 10 | * 11 | * The above copyright notice and this permission notice shall be included in 12 | * all copies or substantial portions of the Software. 13 | * 14 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 15 | * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 16 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 17 | * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 18 | * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 19 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 20 | * THE SOFTWARE. 21 | * 22 | * @author GeyserMC 23 | * @link https://github.com/GeyserMC/Geyser 24 | */ 25 | 26 | package org.geysermc.floodgate.util; 27 | 28 | import org.checkerframework.checker.nullness.qual.NonNull; 29 | 30 | public enum UiProfile { 31 | CLASSIC, 32 | POCKET; 33 | 34 | private static final UiProfile[] VALUES = values(); 35 | 36 | /** 37 | * Get the UiProfile instance from the identifier. 38 | * 39 | * @param id the UiProfile identifier 40 | * @return The UiProfile or {@link #CLASSIC} if the UiProfile wasn't found 41 | */ 42 | public static @NonNull UiProfile fromId(int id) { 43 | return VALUES.length > id ? VALUES[id] : VALUES[0]; 44 | } 45 | } 46 | -------------------------------------------------------------------------------- /core/src/main/java/org/geysermc/geyser/entity/properties/type/BooleanProperty.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 2019-2024 GeyserMC. http://geysermc.org 3 | * 4 | * Permission is hereby granted, free of charge, to any person obtaining a copy 5 | * of this software and associated documentation files (the "Software"), to deal 6 | * in the Software without restriction, including without limitation the rights 7 | * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 8 | * copies of the Software, and to permit persons to whom the Software is 9 | * furnished to do so, subject to the following conditions: 10 | * 11 | * The above copyright notice and this permission notice shall be included in 12 | * all copies or substantial portions of the Software. 13 | * 14 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 15 | * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 16 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 17 | * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 18 | * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 19 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 20 | * THE SOFTWARE. 21 | * 22 | * @author GeyserMC 23 | * @link https://github.com/GeyserMC/Geyser 24 | */ 25 | 26 | package org.geysermc.geyser.entity.properties.type; 27 | 28 | import org.cloudburstmc.nbt.NbtMap; 29 | 30 | public class BooleanProperty implements PropertyType { 31 | private final String name; 32 | 33 | public BooleanProperty(String name) { 34 | this.name = name; 35 | } 36 | 37 | @Override 38 | public NbtMap nbtMap() { 39 | return NbtMap.builder() 40 | .putString("name", name) 41 | .putInt("type", 2) 42 | .build(); 43 | } 44 | } -------------------------------------------------------------------------------- /core/src/main/java/org/geysermc/geyser/entity/properties/type/PropertyType.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 2019-2024 GeyserMC. http://geysermc.org 3 | * 4 | * Permission is hereby granted, free of charge, to any person obtaining a copy 5 | * of this software and associated documentation files (the "Software"), to deal 6 | * in the Software without restriction, including without limitation the rights 7 | * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 8 | * copies of the Software, and to permit persons to whom the Software is 9 | * furnished to do so, subject to the following conditions: 10 | * 11 | * The above copyright notice and this permission notice shall be included in 12 | * all copies or substantial portions of the Software. 13 | * 14 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 15 | * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 16 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 17 | * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 18 | * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 19 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 20 | * THE SOFTWARE. 21 | * 22 | * @author GeyserMC 23 | * @link https://github.com/GeyserMC/Geyser 24 | */ 25 | 26 | package org.geysermc.geyser.entity.properties.type; 27 | 28 | import org.cloudburstmc.nbt.NbtMap; 29 | 30 | public interface PropertyType { 31 | NbtMap nbtMap(); 32 | } -------------------------------------------------------------------------------- /core/src/main/java/org/geysermc/geyser/entity/type/Leashable.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 2024 GeyserMC. http://geysermc.org 3 | * 4 | * Permission is hereby granted, free of charge, to any person obtaining a copy 5 | * of this software and associated documentation files (the "Software"), to deal 6 | * in the Software without restriction, including without limitation the rights 7 | * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 8 | * copies of the Software, and to permit persons to whom the Software is 9 | * furnished to do so, subject to the following conditions: 10 | * 11 | * The above copyright notice and this permission notice shall be included in 12 | * all copies or substantial portions of the Software. 13 | * 14 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 15 | * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 16 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 17 | * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 18 | * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 19 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 20 | * THE SOFTWARE. 21 | * 22 | * @author GeyserMC 23 | * @link https://github.com/GeyserMC/Geyser 24 | */ 25 | 26 | package org.geysermc.geyser.entity.type; 27 | 28 | /** 29 | * I can haz lead 30 | * (The item, not the mineral) 31 | */ 32 | public interface Leashable { 33 | void setLeashHolderBedrockId(long bedrockId); 34 | 35 | long leashHolderBedrockId(); 36 | 37 | default boolean canBeLeashed() { 38 | return isNotLeashed(); 39 | } 40 | 41 | default boolean isNotLeashed() { 42 | return leashHolderBedrockId() == -1L; 43 | } 44 | } 45 | -------------------------------------------------------------------------------- /core/src/main/java/org/geysermc/geyser/entity/vehicle/ClientVehicle.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 2019-2023 GeyserMC. http://geysermc.org 3 | * 4 | * Permission is hereby granted, free of charge, to any person obtaining a copy 5 | * of this software and associated documentation files (the "Software"), to deal 6 | * in the Software without restriction, including without limitation the rights 7 | * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 8 | * copies of the Software, and to permit persons to whom the Software is 9 | * furnished to do so, subject to the following conditions: 10 | * 11 | * The above copyright notice and this permission notice shall be included in 12 | * all copies or substantial portions of the Software. 13 | * 14 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 15 | * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 16 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 17 | * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 18 | * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 19 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 20 | * THE SOFTWARE. 21 | * 22 | * @author GeyserMC 23 | * @link https://github.com/GeyserMC/Geyser 24 | */ 25 | 26 | package org.geysermc.geyser.entity.vehicle; 27 | 28 | import org.cloudburstmc.math.vector.Vector2f; 29 | 30 | public interface ClientVehicle { 31 | VehicleComponent getVehicleComponent(); 32 | 33 | Vector2f getAdjustedInput(Vector2f input); 34 | 35 | float getVehicleSpeed(); 36 | 37 | boolean isClientControlled(); 38 | 39 | default boolean canWalkOnLava() { 40 | return false; 41 | } 42 | 43 | default boolean canClimb() { 44 | return true; 45 | } 46 | } 47 | -------------------------------------------------------------------------------- /core/src/main/java/org/geysermc/geyser/erosion/ErosionCancellationException.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 2024 GeyserMC. http://geysermc.org 3 | * 4 | * Permission is hereby granted, free of charge, to any person obtaining a copy 5 | * of this software and associated documentation files (the "Software"), to deal 6 | * in the Software without restriction, including without limitation the rights 7 | * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 8 | * copies of the Software, and to permit persons to whom the Software is 9 | * furnished to do so, subject to the following conditions: 10 | * 11 | * The above copyright notice and this permission notice shall be included in 12 | * all copies or substantial portions of the Software. 13 | * 14 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 15 | * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 16 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 17 | * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 18 | * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 19 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 20 | * THE SOFTWARE. 21 | * 22 | * @author GeyserMC 23 | * @link https://github.com/GeyserMC/Geyser 24 | */ 25 | 26 | package org.geysermc.geyser.erosion; 27 | 28 | import java.io.Serial; 29 | import java.util.concurrent.CancellationException; 30 | 31 | public class ErosionCancellationException extends CancellationException { 32 | @Serial 33 | private static final long serialVersionUID = 1L; 34 | } 35 | -------------------------------------------------------------------------------- /core/src/main/java/org/geysermc/geyser/event/GeyserEventRegistrar.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 2019-2022 GeyserMC. http://geysermc.org 3 | * 4 | * Permission is hereby granted, free of charge, to any person obtaining a copy 5 | * of this software and associated documentation files (the "Software"), to deal 6 | * in the Software without restriction, including without limitation the rights 7 | * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 8 | * copies of the Software, and to permit persons to whom the Software is 9 | * furnished to do so, subject to the following conditions: 10 | * 11 | * The above copyright notice and this permission notice shall be included in 12 | * all copies or substantial portions of the Software. 13 | * 14 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 15 | * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 16 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 17 | * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 18 | * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 19 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 20 | * THE SOFTWARE. 21 | * 22 | * @author GeyserMC 23 | * @link https://github.com/GeyserMC/Geyser 24 | */ 25 | 26 | package org.geysermc.geyser.event; 27 | 28 | import org.geysermc.geyser.api.event.EventRegistrar; 29 | 30 | public record GeyserEventRegistrar(Object owner) implements EventRegistrar { 31 | 32 | @Override 33 | public String toString() { 34 | return "GeyserEventRegistrar{" + 35 | "owner=" + this.owner + 36 | '}'; 37 | } 38 | } 39 | -------------------------------------------------------------------------------- /core/src/main/java/org/geysermc/geyser/impl/MinecraftVersionImpl.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 2019-2024 GeyserMC. http://geysermc.org 3 | * 4 | * Permission is hereby granted, free of charge, to any person obtaining a copy 5 | * of this software and associated documentation files (the "Software"), to deal 6 | * in the Software without restriction, including without limitation the rights 7 | * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 8 | * copies of the Software, and to permit persons to whom the Software is 9 | * furnished to do so, subject to the following conditions: 10 | * 11 | * The above copyright notice and this permission notice shall be included in 12 | * all copies or substantial portions of the Software. 13 | * 14 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 15 | * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 16 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 17 | * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 18 | * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 19 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 20 | * THE SOFTWARE. 21 | * 22 | * @author GeyserMC 23 | * @link https://github.com/GeyserMC/Geyser 24 | */ 25 | 26 | package org.geysermc.geyser.impl; 27 | 28 | import org.geysermc.geyser.api.util.MinecraftVersion; 29 | 30 | public record MinecraftVersionImpl(String versionString, int protocolVersion) implements MinecraftVersion { 31 | } 32 | -------------------------------------------------------------------------------- /core/src/main/java/org/geysermc/geyser/inventory/BeaconContainer.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 2019-2022 GeyserMC. http://geysermc.org 3 | * 4 | * Permission is hereby granted, free of charge, to any person obtaining a copy 5 | * of this software and associated documentation files (the "Software"), to deal 6 | * in the Software without restriction, including without limitation the rights 7 | * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 8 | * copies of the Software, and to permit persons to whom the Software is 9 | * furnished to do so, subject to the following conditions: 10 | * 11 | * The above copyright notice and this permission notice shall be included in 12 | * all copies or substantial portions of the Software. 13 | * 14 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 15 | * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 16 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 17 | * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 18 | * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 19 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 20 | * THE SOFTWARE. 21 | * 22 | * @author GeyserMC 23 | * @link https://github.com/GeyserMC/Geyser 24 | */ 25 | 26 | package org.geysermc.geyser.inventory; 27 | 28 | import lombok.Getter; 29 | import lombok.Setter; 30 | import org.geysermc.geyser.session.GeyserSession; 31 | import org.geysermc.mcprotocollib.protocol.data.game.inventory.ContainerType; 32 | 33 | @Getter 34 | @Setter 35 | public class BeaconContainer extends Container { 36 | private int primaryId; 37 | private int secondaryId; 38 | 39 | public BeaconContainer(GeyserSession session, String title, int id, int size, ContainerType containerType) { 40 | super(session, title, id, size, containerType); 41 | } 42 | } 43 | -------------------------------------------------------------------------------- /core/src/main/java/org/geysermc/geyser/inventory/BedrockContainerSlot.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 2019-2022 GeyserMC. http://geysermc.org 3 | * 4 | * Permission is hereby granted, free of charge, to any person obtaining a copy 5 | * of this software and associated documentation files (the "Software"), to deal 6 | * in the Software without restriction, including without limitation the rights 7 | * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 8 | * copies of the Software, and to permit persons to whom the Software is 9 | * furnished to do so, subject to the following conditions: 10 | * 11 | * The above copyright notice and this permission notice shall be included in 12 | * all copies or substantial portions of the Software. 13 | * 14 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 15 | * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 16 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 17 | * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 18 | * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 19 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 20 | * THE SOFTWARE. 21 | * 22 | * @author GeyserMC 23 | * @link https://github.com/GeyserMC/Geyser 24 | */ 25 | 26 | package org.geysermc.geyser.inventory; 27 | 28 | import org.cloudburstmc.protocol.bedrock.data.inventory.ContainerSlotType; 29 | 30 | public record BedrockContainerSlot(ContainerSlotType container, int slot) { 31 | } 32 | -------------------------------------------------------------------------------- /core/src/main/java/org/geysermc/geyser/inventory/CartographyContainer.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 2019-2022 GeyserMC. http://geysermc.org 3 | * 4 | * Permission is hereby granted, free of charge, to any person obtaining a copy 5 | * of this software and associated documentation files (the "Software"), to deal 6 | * in the Software without restriction, including without limitation the rights 7 | * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 8 | * copies of the Software, and to permit persons to whom the Software is 9 | * furnished to do so, subject to the following conditions: 10 | * 11 | * The above copyright notice and this permission notice shall be included in 12 | * all copies or substantial portions of the Software. 13 | * 14 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 15 | * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 16 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 17 | * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 18 | * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 19 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 20 | * THE SOFTWARE. 21 | * 22 | * @author GeyserMC 23 | * @link https://github.com/GeyserMC/Geyser 24 | */ 25 | 26 | package org.geysermc.geyser.inventory; 27 | 28 | import org.geysermc.geyser.session.GeyserSession; 29 | import org.geysermc.mcprotocollib.protocol.data.game.inventory.ContainerType; 30 | 31 | public class CartographyContainer extends Container { 32 | public CartographyContainer(GeyserSession session, String title, int id, int size, ContainerType containerType) { 33 | super(session, title, id, size, containerType); 34 | } 35 | } 36 | -------------------------------------------------------------------------------- /core/src/main/java/org/geysermc/geyser/inventory/SlotType.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 2019-2022 GeyserMC. http://geysermc.org 3 | * 4 | * Permission is hereby granted, free of charge, to any person obtaining a copy 5 | * of this software and associated documentation files (the "Software"), to deal 6 | * in the Software without restriction, including without limitation the rights 7 | * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 8 | * copies of the Software, and to permit persons to whom the Software is 9 | * furnished to do so, subject to the following conditions: 10 | * 11 | * The above copyright notice and this permission notice shall be included in 12 | * all copies or substantial portions of the Software. 13 | * 14 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 15 | * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 16 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 17 | * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 18 | * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 19 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 20 | * THE SOFTWARE. 21 | * 22 | * @author GeyserMC 23 | * @link https://github.com/GeyserMC/Geyser 24 | */ 25 | 26 | package org.geysermc.geyser.inventory; 27 | 28 | public enum SlotType { 29 | NORMAL, 30 | OUTPUT, 31 | FURNACE_OUTPUT 32 | } 33 | -------------------------------------------------------------------------------- /core/src/main/java/org/geysermc/geyser/inventory/recipe/GeyserRecipe.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 2019-2022 GeyserMC. http://geysermc.org 3 | * 4 | * Permission is hereby granted, free of charge, to any person obtaining a copy 5 | * of this software and associated documentation files (the "Software"), to deal 6 | * in the Software without restriction, including without limitation the rights 7 | * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 8 | * copies of the Software, and to permit persons to whom the Software is 9 | * furnished to do so, subject to the following conditions: 10 | * 11 | * The above copyright notice and this permission notice shall be included in 12 | * all copies or substantial portions of the Software. 13 | * 14 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 15 | * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 16 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 17 | * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 18 | * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 19 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 20 | * THE SOFTWARE. 21 | * 22 | * @author GeyserMC 23 | * @link https://github.com/GeyserMC/Geyser 24 | */ 25 | 26 | package org.geysermc.geyser.inventory.recipe; 27 | 28 | import org.geysermc.mcprotocollib.protocol.data.game.recipe.display.slot.SlotDisplay; 29 | 30 | /** 31 | * A more compact version of {@link org.geysermc.mcprotocollib.protocol.data.game.recipe.display.RecipeDisplay}. 32 | */ 33 | public interface GeyserRecipe { 34 | /** 35 | * Whether the recipe is flexible or not in which items can be placed where. 36 | */ 37 | boolean isShaped(); 38 | 39 | SlotDisplay result(); 40 | } 41 | -------------------------------------------------------------------------------- /core/src/main/java/org/geysermc/geyser/inventory/recipe/GeyserStonecutterData.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 2019-2022 GeyserMC. http://geysermc.org 3 | * 4 | * Permission is hereby granted, free of charge, to any person obtaining a copy 5 | * of this software and associated documentation files (the "Software"), to deal 6 | * in the Software without restriction, including without limitation the rights 7 | * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 8 | * copies of the Software, and to permit persons to whom the Software is 9 | * furnished to do so, subject to the following conditions: 10 | * 11 | * The above copyright notice and this permission notice shall be included in 12 | * all copies or substantial portions of the Software. 13 | * 14 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 15 | * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 16 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 17 | * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 18 | * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 19 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 20 | * THE SOFTWARE. 21 | * 22 | * @author GeyserMC 23 | * @link https://github.com/GeyserMC/Geyser 24 | */ 25 | 26 | package org.geysermc.geyser.inventory.recipe; 27 | 28 | import org.geysermc.mcprotocollib.protocol.data.game.item.ItemStack; 29 | import org.checkerframework.checker.nullness.qual.Nullable; 30 | 31 | /** 32 | * @param buttonId the button that needs to be pressed for Java Edition to accept this item. 33 | * @param output the expected output of this item when cut. 34 | */ 35 | public record GeyserStonecutterData(int buttonId, @Nullable ItemStack output) { 36 | } 37 | -------------------------------------------------------------------------------- /core/src/main/java/org/geysermc/geyser/item/GeyserCustomMappingData.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 2019-2022 GeyserMC. http://geysermc.org 3 | * 4 | * Permission is hereby granted, free of charge, to any person obtaining a copy 5 | * of this software and associated documentation files (the "Software"), to deal 6 | * in the Software without restriction, including without limitation the rights 7 | * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 8 | * copies of the Software, and to permit persons to whom the Software is 9 | * furnished to do so, subject to the following conditions: 10 | * 11 | * The above copyright notice and this permission notice shall be included in 12 | * all copies or substantial portions of the Software. 13 | * 14 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 15 | * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 16 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 17 | * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 18 | * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 19 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 20 | * THE SOFTWARE. 21 | * 22 | * @author GeyserMC 23 | * @link https://github.com/GeyserMC/Geyser 24 | */ 25 | 26 | package org.geysermc.geyser.item; 27 | 28 | import org.cloudburstmc.protocol.bedrock.data.definitions.ItemDefinition; 29 | 30 | public record GeyserCustomMappingData(ItemDefinition itemDefinition, String stringId, int integerId) { 31 | } 32 | -------------------------------------------------------------------------------- /core/src/main/java/org/geysermc/geyser/item/components/WearableSlot.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 2019-2022 GeyserMC. http://geysermc.org 3 | * 4 | * Permission is hereby granted, free of charge, to any person obtaining a copy 5 | * of this software and associated documentation files (the "Software"), to deal 6 | * in the Software without restriction, including without limitation the rights 7 | * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 8 | * copies of the Software, and to permit persons to whom the Software is 9 | * furnished to do so, subject to the following conditions: 10 | * 11 | * The above copyright notice and this permission notice shall be included in 12 | * all copies or substantial portions of the Software. 13 | * 14 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 15 | * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 16 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 17 | * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 18 | * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 19 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 20 | * THE SOFTWARE. 21 | * 22 | * @author GeyserMC 23 | * @link https://github.com/GeyserMC/Geyser 24 | */ 25 | 26 | package org.geysermc.geyser.item.components; 27 | 28 | import org.cloudburstmc.nbt.NbtMap; 29 | 30 | import java.util.Locale; 31 | 32 | public enum WearableSlot { 33 | HEAD, 34 | CHEST, 35 | LEGS, 36 | FEET; 37 | 38 | private final NbtMap slotNbt; 39 | 40 | WearableSlot() { 41 | this.slotNbt = NbtMap.builder().putString("slot", "slot.armor." + this.name().toLowerCase(Locale.ROOT)).build(); 42 | } 43 | 44 | public NbtMap getSlotNbt() { 45 | return slotNbt; 46 | } 47 | } 48 | -------------------------------------------------------------------------------- /core/src/main/java/org/geysermc/geyser/item/enchantment/EnchantmentComponent.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 2024 GeyserMC. http://geysermc.org 3 | * 4 | * Permission is hereby granted, free of charge, to any person obtaining a copy 5 | * of this software and associated documentation files (the "Software"), to deal 6 | * in the Software without restriction, including without limitation the rights 7 | * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 8 | * copies of the Software, and to permit persons to whom the Software is 9 | * furnished to do so, subject to the following conditions: 10 | * 11 | * The above copyright notice and this permission notice shall be included in 12 | * all copies or substantial portions of the Software. 13 | * 14 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 15 | * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 16 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 17 | * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 18 | * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 19 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 20 | * THE SOFTWARE. 21 | * 22 | * @author GeyserMC 23 | * @link https://github.com/GeyserMC/Geyser 24 | */ 25 | 26 | package org.geysermc.geyser.item.enchantment; 27 | 28 | public class EnchantmentComponent { 29 | /** 30 | * Singleton with no additional data 31 | */ 32 | public static final EnchantmentComponent PREVENT_ARMOR_CHANGE = new EnchantmentComponent(); 33 | } 34 | -------------------------------------------------------------------------------- /core/src/main/java/org/geysermc/geyser/item/exception/InvalidCustomMappingsFileException.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 2019-2022 GeyserMC. http://geysermc.org 3 | * 4 | * Permission is hereby granted, free of charge, to any person obtaining a copy 5 | * of this software and associated documentation files (the "Software"), to deal 6 | * in the Software without restriction, including without limitation the rights 7 | * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 8 | * copies of the Software, and to permit persons to whom the Software is 9 | * furnished to do so, subject to the following conditions: 10 | * 11 | * The above copyright notice and this permission notice shall be included in 12 | * all copies or substantial portions of the Software. 13 | * 14 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 15 | * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 16 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 17 | * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 18 | * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 19 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 20 | * THE SOFTWARE. 21 | * 22 | * @author GeyserMC 23 | * @link https://github.com/GeyserMC/Geyser 24 | */ 25 | 26 | package org.geysermc.geyser.item.exception; 27 | 28 | import java.io.Serial; 29 | 30 | public class InvalidCustomMappingsFileException extends Exception { 31 | 32 | @Serial 33 | private static final long serialVersionUID = 1L; 34 | 35 | public InvalidCustomMappingsFileException(String message) { 36 | super(message); 37 | } 38 | } 39 | -------------------------------------------------------------------------------- /core/src/main/java/org/geysermc/geyser/item/hashing/data/FireworkExplosionShape.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 2025 GeyserMC. http://geysermc.org 3 | * 4 | * Permission is hereby granted, free of charge, to any person obtaining a copy 5 | * of this software and associated documentation files (the "Software"), to deal 6 | * in the Software without restriction, including without limitation the rights 7 | * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 8 | * copies of the Software, and to permit persons to whom the Software is 9 | * furnished to do so, subject to the following conditions: 10 | * 11 | * The above copyright notice and this permission notice shall be included in 12 | * all copies or substantial portions of the Software. 13 | * 14 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 15 | * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 16 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 17 | * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 18 | * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 19 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 20 | * THE SOFTWARE. 21 | * 22 | * @author GeyserMC 23 | * @link https://github.com/GeyserMC/Geyser 24 | */ 25 | 26 | package org.geysermc.geyser.item.hashing.data; 27 | 28 | // Ordered and named by Java ID 29 | public enum FireworkExplosionShape { 30 | SMALL_BALL, 31 | LARGE_BALL, 32 | STAR, 33 | CREEPER, 34 | BURST 35 | } 36 | -------------------------------------------------------------------------------- /core/src/main/java/org/geysermc/geyser/item/hashing/data/ItemContainerSlot.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 2025 GeyserMC. http://geysermc.org 3 | * 4 | * Permission is hereby granted, free of charge, to any person obtaining a copy 5 | * of this software and associated documentation files (the "Software"), to deal 6 | * in the Software without restriction, including without limitation the rights 7 | * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 8 | * copies of the Software, and to permit persons to whom the Software is 9 | * furnished to do so, subject to the following conditions: 10 | * 11 | * The above copyright notice and this permission notice shall be included in 12 | * all copies or substantial portions of the Software. 13 | * 14 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 15 | * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 16 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 17 | * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 18 | * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 19 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 20 | * THE SOFTWARE. 21 | * 22 | * @author GeyserMC 23 | * @link https://github.com/GeyserMC/Geyser 24 | */ 25 | 26 | package org.geysermc.geyser.item.hashing.data; 27 | 28 | import org.geysermc.mcprotocollib.protocol.data.game.item.ItemStack; 29 | 30 | public record ItemContainerSlot(int index, ItemStack item) { 31 | } 32 | -------------------------------------------------------------------------------- /core/src/main/java/org/geysermc/geyser/item/hashing/data/entity/AxolotlVariant.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 2025 GeyserMC. http://geysermc.org 3 | * 4 | * Permission is hereby granted, free of charge, to any person obtaining a copy 5 | * of this software and associated documentation files (the "Software"), to deal 6 | * in the Software without restriction, including without limitation the rights 7 | * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 8 | * copies of the Software, and to permit persons to whom the Software is 9 | * furnished to do so, subject to the following conditions: 10 | * 11 | * The above copyright notice and this permission notice shall be included in 12 | * all copies or substantial portions of the Software. 13 | * 14 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 15 | * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 16 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 17 | * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 18 | * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 19 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 20 | * THE SOFTWARE. 21 | * 22 | * @author GeyserMC 23 | * @link https://github.com/GeyserMC/Geyser 24 | */ 25 | 26 | package org.geysermc.geyser.item.hashing.data.entity; 27 | 28 | // Ordered and named by Java ID 29 | public enum AxolotlVariant { 30 | LUCY, 31 | WILD, 32 | GOLD, 33 | CYAN, 34 | BLUE 35 | } 36 | -------------------------------------------------------------------------------- /core/src/main/java/org/geysermc/geyser/item/hashing/data/entity/FoxVariant.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 2025 GeyserMC. http://geysermc.org 3 | * 4 | * Permission is hereby granted, free of charge, to any person obtaining a copy 5 | * of this software and associated documentation files (the "Software"), to deal 6 | * in the Software without restriction, including without limitation the rights 7 | * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 8 | * copies of the Software, and to permit persons to whom the Software is 9 | * furnished to do so, subject to the following conditions: 10 | * 11 | * The above copyright notice and this permission notice shall be included in 12 | * all copies or substantial portions of the Software. 13 | * 14 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 15 | * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 16 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 17 | * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 18 | * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 19 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 20 | * THE SOFTWARE. 21 | * 22 | * @author GeyserMC 23 | * @link https://github.com/GeyserMC/Geyser 24 | */ 25 | 26 | package org.geysermc.geyser.item.hashing.data.entity; 27 | 28 | // Ordered and named by Java ID 29 | public enum FoxVariant { 30 | RED, 31 | SNOW 32 | } 33 | -------------------------------------------------------------------------------- /core/src/main/java/org/geysermc/geyser/item/hashing/data/entity/HorseVariant.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 2025 GeyserMC. http://geysermc.org 3 | * 4 | * Permission is hereby granted, free of charge, to any person obtaining a copy 5 | * of this software and associated documentation files (the "Software"), to deal 6 | * in the Software without restriction, including without limitation the rights 7 | * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 8 | * copies of the Software, and to permit persons to whom the Software is 9 | * furnished to do so, subject to the following conditions: 10 | * 11 | * The above copyright notice and this permission notice shall be included in 12 | * all copies or substantial portions of the Software. 13 | * 14 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 15 | * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 16 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 17 | * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 18 | * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 19 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 20 | * THE SOFTWARE. 21 | * 22 | * @author GeyserMC 23 | * @link https://github.com/GeyserMC/Geyser 24 | */ 25 | 26 | package org.geysermc.geyser.item.hashing.data.entity; 27 | 28 | // Ordered and named by Java ID 29 | public enum HorseVariant { 30 | WHITE, 31 | CREAMY, 32 | CHESTNUT, 33 | BROWN, 34 | BLACK, 35 | GRAY, 36 | DARK_BROWN 37 | } 38 | -------------------------------------------------------------------------------- /core/src/main/java/org/geysermc/geyser/item/hashing/data/entity/LlamaVariant.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 2025 GeyserMC. http://geysermc.org 3 | * 4 | * Permission is hereby granted, free of charge, to any person obtaining a copy 5 | * of this software and associated documentation files (the "Software"), to deal 6 | * in the Software without restriction, including without limitation the rights 7 | * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 8 | * copies of the Software, and to permit persons to whom the Software is 9 | * furnished to do so, subject to the following conditions: 10 | * 11 | * The above copyright notice and this permission notice shall be included in 12 | * all copies or substantial portions of the Software. 13 | * 14 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 15 | * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 16 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 17 | * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 18 | * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 19 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 20 | * THE SOFTWARE. 21 | * 22 | * @author GeyserMC 23 | * @link https://github.com/GeyserMC/Geyser 24 | */ 25 | 26 | package org.geysermc.geyser.item.hashing.data.entity; 27 | 28 | // Ordered and named by Java ID 29 | public enum LlamaVariant { 30 | CREAMY, 31 | WHITE, 32 | BROWN, 33 | GRAY 34 | } 35 | -------------------------------------------------------------------------------- /core/src/main/java/org/geysermc/geyser/item/hashing/data/entity/MooshroomVariant.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 2025 GeyserMC. http://geysermc.org 3 | * 4 | * Permission is hereby granted, free of charge, to any person obtaining a copy 5 | * of this software and associated documentation files (the "Software"), to deal 6 | * in the Software without restriction, including without limitation the rights 7 | * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 8 | * copies of the Software, and to permit persons to whom the Software is 9 | * furnished to do so, subject to the following conditions: 10 | * 11 | * The above copyright notice and this permission notice shall be included in 12 | * all copies or substantial portions of the Software. 13 | * 14 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 15 | * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 16 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 17 | * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 18 | * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 19 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 20 | * THE SOFTWARE. 21 | * 22 | * @author GeyserMC 23 | * @link https://github.com/GeyserMC/Geyser 24 | */ 25 | 26 | package org.geysermc.geyser.item.hashing.data.entity; 27 | 28 | // Ordered and named by Java ID 29 | public enum MooshroomVariant { 30 | RED, 31 | BROWN 32 | } 33 | -------------------------------------------------------------------------------- /core/src/main/java/org/geysermc/geyser/item/hashing/data/entity/ParrotVariant.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 2025 GeyserMC. http://geysermc.org 3 | * 4 | * Permission is hereby granted, free of charge, to any person obtaining a copy 5 | * of this software and associated documentation files (the "Software"), to deal 6 | * in the Software without restriction, including without limitation the rights 7 | * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 8 | * copies of the Software, and to permit persons to whom the Software is 9 | * furnished to do so, subject to the following conditions: 10 | * 11 | * The above copyright notice and this permission notice shall be included in 12 | * all copies or substantial portions of the Software. 13 | * 14 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 15 | * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 16 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 17 | * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 18 | * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 19 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 20 | * THE SOFTWARE. 21 | * 22 | * @author GeyserMC 23 | * @link https://github.com/GeyserMC/Geyser 24 | */ 25 | 26 | package org.geysermc.geyser.item.hashing.data.entity; 27 | 28 | // Ordered and named by Java ID 29 | public enum ParrotVariant { 30 | RED_BLUE, 31 | BLUE, 32 | GREEN, 33 | YELLOW_BLUE, 34 | GRAY 35 | } 36 | -------------------------------------------------------------------------------- /core/src/main/java/org/geysermc/geyser/item/hashing/data/entity/SalmonVariant.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 2025 GeyserMC. http://geysermc.org 3 | * 4 | * Permission is hereby granted, free of charge, to any person obtaining a copy 5 | * of this software and associated documentation files (the "Software"), to deal 6 | * in the Software without restriction, including without limitation the rights 7 | * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 8 | * copies of the Software, and to permit persons to whom the Software is 9 | * furnished to do so, subject to the following conditions: 10 | * 11 | * The above copyright notice and this permission notice shall be included in 12 | * all copies or substantial portions of the Software. 13 | * 14 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 15 | * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 16 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 17 | * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 18 | * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 19 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 20 | * THE SOFTWARE. 21 | * 22 | * @author GeyserMC 23 | * @link https://github.com/GeyserMC/Geyser 24 | */ 25 | 26 | package org.geysermc.geyser.item.hashing.data.entity; 27 | 28 | // Ordered and named by Java ID 29 | public enum SalmonVariant { 30 | SMALL, 31 | MEDIUM, 32 | LARGE 33 | } 34 | -------------------------------------------------------------------------------- /core/src/main/java/org/geysermc/geyser/item/hashing/data/entity/VillagerVariant.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 2025 GeyserMC. http://geysermc.org 3 | * 4 | * Permission is hereby granted, free of charge, to any person obtaining a copy 5 | * of this software and associated documentation files (the "Software"), to deal 6 | * in the Software without restriction, including without limitation the rights 7 | * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 8 | * copies of the Software, and to permit persons to whom the Software is 9 | * furnished to do so, subject to the following conditions: 10 | * 11 | * The above copyright notice and this permission notice shall be included in 12 | * all copies or substantial portions of the Software. 13 | * 14 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 15 | * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 16 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 17 | * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 18 | * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 19 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 20 | * THE SOFTWARE. 21 | * 22 | * @author GeyserMC 23 | * @link https://github.com/GeyserMC/Geyser 24 | */ 25 | 26 | package org.geysermc.geyser.item.hashing.data.entity; 27 | 28 | // Ordered and named by Java ID 29 | public enum VillagerVariant { 30 | DESERT, 31 | JUNGLE, 32 | PLAINS, 33 | SAVANNA, 34 | SNOW, 35 | SWAMP, 36 | TAIGA 37 | } 38 | -------------------------------------------------------------------------------- /core/src/main/java/org/geysermc/geyser/item/type/BedrockRequiresTagItem.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 2024 GeyserMC. http://geysermc.org 3 | * 4 | * Permission is hereby granted, free of charge, to any person obtaining a copy 5 | * of this software and associated documentation files (the "Software"), to deal 6 | * in the Software without restriction, including without limitation the rights 7 | * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 8 | * copies of the Software, and to permit persons to whom the Software is 9 | * furnished to do so, subject to the following conditions: 10 | * 11 | * The above copyright notice and this permission notice shall be included in 12 | * all copies or substantial portions of the Software. 13 | * 14 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 15 | * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 16 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 17 | * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 18 | * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 19 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 20 | * THE SOFTWARE. 21 | * 22 | * @author GeyserMC 23 | * @link https://github.com/GeyserMC/Geyser 24 | */ 25 | 26 | package org.geysermc.geyser.item.type; 27 | 28 | // Whether this item should have its NBT data kept in the recipe book. 29 | public interface BedrockRequiresTagItem { 30 | } 31 | -------------------------------------------------------------------------------- /core/src/main/java/org/geysermc/geyser/item/type/BoatItem.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 2019-2023 GeyserMC. http://geysermc.org 3 | * 4 | * Permission is hereby granted, free of charge, to any person obtaining a copy 5 | * of this software and associated documentation files (the "Software"), to deal 6 | * in the Software without restriction, including without limitation the rights 7 | * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 8 | * copies of the Software, and to permit persons to whom the Software is 9 | * furnished to do so, subject to the following conditions: 10 | * 11 | * The above copyright notice and this permission notice shall be included in 12 | * all copies or substantial portions of the Software. 13 | * 14 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 15 | * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 16 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 17 | * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 18 | * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 19 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 20 | * THE SOFTWARE. 21 | * 22 | * @author GeyserMC 23 | * @link https://github.com/GeyserMC/Geyser 24 | */ 25 | 26 | package org.geysermc.geyser.item.type; 27 | 28 | public class BoatItem extends Item { 29 | public BoatItem(String javaIdentifier, Builder builder) { 30 | super(javaIdentifier, builder); 31 | } 32 | } 33 | -------------------------------------------------------------------------------- /core/src/main/java/org/geysermc/geyser/item/type/DyeItem.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 2019-2022 GeyserMC. http://geysermc.org 3 | * 4 | * Permission is hereby granted, free of charge, to any person obtaining a copy 5 | * of this software and associated documentation files (the "Software"), to deal 6 | * in the Software without restriction, including without limitation the rights 7 | * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 8 | * copies of the Software, and to permit persons to whom the Software is 9 | * furnished to do so, subject to the following conditions: 10 | * 11 | * The above copyright notice and this permission notice shall be included in 12 | * all copies or substantial portions of the Software. 13 | * 14 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 15 | * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 16 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 17 | * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 18 | * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 19 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 20 | * THE SOFTWARE. 21 | * 22 | * @author GeyserMC 23 | * @link https://github.com/GeyserMC/Geyser 24 | */ 25 | 26 | package org.geysermc.geyser.item.type; 27 | 28 | public class DyeItem extends Item { 29 | private final int dyeColor; 30 | 31 | public DyeItem(String javaIdentifier, int dyeColor, Builder builder) { 32 | super(javaIdentifier, builder); 33 | this.dyeColor = dyeColor; 34 | } 35 | 36 | public int dyeColor() { 37 | return dyeColor; 38 | } 39 | } 40 | -------------------------------------------------------------------------------- /core/src/main/java/org/geysermc/geyser/item/type/SpawnEggItem.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 2019-2022 GeyserMC. http://geysermc.org 3 | * 4 | * Permission is hereby granted, free of charge, to any person obtaining a copy 5 | * of this software and associated documentation files (the "Software"), to deal 6 | * in the Software without restriction, including without limitation the rights 7 | * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 8 | * copies of the Software, and to permit persons to whom the Software is 9 | * furnished to do so, subject to the following conditions: 10 | * 11 | * The above copyright notice and this permission notice shall be included in 12 | * all copies or substantial portions of the Software. 13 | * 14 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 15 | * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 16 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 17 | * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 18 | * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 19 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 20 | * THE SOFTWARE. 21 | * 22 | * @author GeyserMC 23 | * @link https://github.com/GeyserMC/Geyser 24 | */ 25 | 26 | package org.geysermc.geyser.item.type; 27 | 28 | public class SpawnEggItem extends Item { 29 | public SpawnEggItem(String javaIdentifier, Builder builder) { 30 | super(javaIdentifier, builder); 31 | } 32 | } 33 | -------------------------------------------------------------------------------- /core/src/main/java/org/geysermc/geyser/level/block/Fluid.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 2019-2023 GeyserMC. http://geysermc.org 3 | * 4 | * Permission is hereby granted, free of charge, to any person obtaining a copy 5 | * of this software and associated documentation files (the "Software"), to deal 6 | * in the Software without restriction, including without limitation the rights 7 | * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 8 | * copies of the Software, and to permit persons to whom the Software is 9 | * furnished to do so, subject to the following conditions: 10 | * 11 | * The above copyright notice and this permission notice shall be included in 12 | * all copies or substantial portions of the Software. 13 | * 14 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 15 | * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 16 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 17 | * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 18 | * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 19 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 20 | * THE SOFTWARE. 21 | * 22 | * @author GeyserMC 23 | * @link https://github.com/GeyserMC/Geyser 24 | */ 25 | 26 | package org.geysermc.geyser.level.block; 27 | 28 | public enum Fluid { 29 | WATER, 30 | LAVA, 31 | EMPTY 32 | } 33 | -------------------------------------------------------------------------------- /core/src/main/java/org/geysermc/geyser/level/block/property/BooleanProperty.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 2024 GeyserMC. http://geysermc.org 3 | * 4 | * Permission is hereby granted, free of charge, to any person obtaining a copy 5 | * of this software and associated documentation files (the "Software"), to deal 6 | * in the Software without restriction, including without limitation the rights 7 | * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 8 | * copies of the Software, and to permit persons to whom the Software is 9 | * furnished to do so, subject to the following conditions: 10 | * 11 | * The above copyright notice and this permission notice shall be included in 12 | * all copies or substantial portions of the Software. 13 | * 14 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 15 | * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 16 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 17 | * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 18 | * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 19 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 20 | * THE SOFTWARE. 21 | * 22 | * @author GeyserMC 23 | * @link https://github.com/GeyserMC/Geyser 24 | */ 25 | 26 | package org.geysermc.geyser.level.block.property; 27 | 28 | public final class BooleanProperty extends Property { 29 | private BooleanProperty(String name) { 30 | super(name); 31 | } 32 | 33 | @Override 34 | public int valuesCount() { 35 | return 2; 36 | } 37 | 38 | @Override 39 | public int indexOf(Boolean value) { 40 | return value ? 0 : 1; 41 | } 42 | 43 | public static BooleanProperty create(String name) { 44 | return new BooleanProperty(name); 45 | } 46 | } 47 | -------------------------------------------------------------------------------- /core/src/main/java/org/geysermc/geyser/level/block/property/ChestType.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 2024 GeyserMC. http://geysermc.org 3 | * 4 | * Permission is hereby granted, free of charge, to any person obtaining a copy 5 | * of this software and associated documentation files (the "Software"), to deal 6 | * in the Software without restriction, including without limitation the rights 7 | * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 8 | * copies of the Software, and to permit persons to whom the Software is 9 | * furnished to do so, subject to the following conditions: 10 | * 11 | * The above copyright notice and this permission notice shall be included in 12 | * all copies or substantial portions of the Software. 13 | * 14 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 15 | * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 16 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 17 | * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 18 | * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 19 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 20 | * THE SOFTWARE. 21 | * 22 | * @author GeyserMC 23 | * @link https://github.com/GeyserMC/Geyser 24 | */ 25 | 26 | package org.geysermc.geyser.level.block.property; 27 | 28 | public enum ChestType { 29 | SINGLE, 30 | LEFT, 31 | RIGHT; 32 | 33 | public static final ChestType[] VALUES = values(); 34 | } 35 | -------------------------------------------------------------------------------- /core/src/main/java/org/geysermc/geyser/level/block/property/Property.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 2024 GeyserMC. http://geysermc.org 3 | * 4 | * Permission is hereby granted, free of charge, to any person obtaining a copy 5 | * of this software and associated documentation files (the "Software"), to deal 6 | * in the Software without restriction, including without limitation the rights 7 | * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 8 | * copies of the Software, and to permit persons to whom the Software is 9 | * furnished to do so, subject to the following conditions: 10 | * 11 | * The above copyright notice and this permission notice shall be included in 12 | * all copies or substantial portions of the Software. 13 | * 14 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 15 | * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 16 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 17 | * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 18 | * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 19 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 20 | * THE SOFTWARE. 21 | * 22 | * @author GeyserMC 23 | * @link https://github.com/GeyserMC/Geyser 24 | */ 25 | 26 | package org.geysermc.geyser.level.block.property; 27 | 28 | public abstract class Property> { 29 | private final String name; 30 | 31 | protected Property(String name) { 32 | this.name = name; 33 | } 34 | 35 | public String name() { 36 | return name; 37 | } 38 | 39 | public abstract int valuesCount(); 40 | 41 | public abstract int indexOf(T value); 42 | 43 | @Override 44 | public String toString() { 45 | return getClass().getSimpleName() + "[" + name + "]"; 46 | } 47 | } 48 | -------------------------------------------------------------------------------- /core/src/main/java/org/geysermc/geyser/level/block/type/BannerBlock.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 2024 GeyserMC. http://geysermc.org 3 | * 4 | * Permission is hereby granted, free of charge, to any person obtaining a copy 5 | * of this software and associated documentation files (the "Software"), to deal 6 | * in the Software without restriction, including without limitation the rights 7 | * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 8 | * copies of the Software, and to permit persons to whom the Software is 9 | * furnished to do so, subject to the following conditions: 10 | * 11 | * The above copyright notice and this permission notice shall be included in 12 | * all copies or substantial portions of the Software. 13 | * 14 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 15 | * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 16 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 17 | * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 18 | * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 19 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 20 | * THE SOFTWARE. 21 | * 22 | * @author GeyserMC 23 | * @link https://github.com/GeyserMC/Geyser 24 | */ 25 | 26 | package org.geysermc.geyser.level.block.type; 27 | 28 | public class BannerBlock extends Block { 29 | private final int dyeColor; 30 | 31 | public BannerBlock(String javaIdentifier, int dyeColor, Builder builder) { 32 | super(javaIdentifier, builder); 33 | this.dyeColor = dyeColor; 34 | } 35 | 36 | public int dyeColor() { 37 | return dyeColor; 38 | } 39 | } 40 | -------------------------------------------------------------------------------- /core/src/main/java/org/geysermc/geyser/level/block/type/BedBlock.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 2024 GeyserMC. http://geysermc.org 3 | * 4 | * Permission is hereby granted, free of charge, to any person obtaining a copy 5 | * of this software and associated documentation files (the "Software"), to deal 6 | * in the Software without restriction, including without limitation the rights 7 | * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 8 | * copies of the Software, and to permit persons to whom the Software is 9 | * furnished to do so, subject to the following conditions: 10 | * 11 | * The above copyright notice and this permission notice shall be included in 12 | * all copies or substantial portions of the Software. 13 | * 14 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 15 | * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 16 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 17 | * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 18 | * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 19 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 20 | * THE SOFTWARE. 21 | * 22 | * @author GeyserMC 23 | * @link https://github.com/GeyserMC/Geyser 24 | */ 25 | 26 | package org.geysermc.geyser.level.block.type; 27 | 28 | public class BedBlock extends Block { 29 | private final int dyeColor; 30 | 31 | public BedBlock(String javaIdentifier, int dyeColor, Builder builder) { 32 | super(javaIdentifier, builder); 33 | this.dyeColor = dyeColor; 34 | } 35 | 36 | public int dyeColor() { 37 | return dyeColor; 38 | } 39 | } 40 | -------------------------------------------------------------------------------- /core/src/main/java/org/geysermc/geyser/level/block/type/ButtonBlock.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 2025 GeyserMC. http://geysermc.org 3 | * 4 | * Permission is hereby granted, free of charge, to any person obtaining a copy 5 | * of this software and associated documentation files (the "Software"), to deal 6 | * in the Software without restriction, including without limitation the rights 7 | * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 8 | * copies of the Software, and to permit persons to whom the Software is 9 | * furnished to do so, subject to the following conditions: 10 | * 11 | * The above copyright notice and this permission notice shall be included in 12 | * all copies or substantial portions of the Software. 13 | * 14 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 15 | * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 16 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 17 | * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 18 | * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 19 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 20 | * THE SOFTWARE. 21 | * 22 | * @author GeyserMC 23 | * @link https://github.com/GeyserMC/Geyser 24 | */ 25 | 26 | package org.geysermc.geyser.level.block.type; 27 | 28 | public class ButtonBlock extends Block { 29 | public ButtonBlock(String javaIdentifier, Builder builder) { 30 | super(javaIdentifier, builder); 31 | } 32 | } 33 | -------------------------------------------------------------------------------- /core/src/main/java/org/geysermc/geyser/level/block/type/FurnaceBlock.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 2024 GeyserMC. http://geysermc.org 3 | * 4 | * Permission is hereby granted, free of charge, to any person obtaining a copy 5 | * of this software and associated documentation files (the "Software"), to deal 6 | * in the Software without restriction, including without limitation the rights 7 | * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 8 | * copies of the Software, and to permit persons to whom the Software is 9 | * furnished to do so, subject to the following conditions: 10 | * 11 | * The above copyright notice and this permission notice shall be included in 12 | * all copies or substantial portions of the Software. 13 | * 14 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 15 | * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 16 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 17 | * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 18 | * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 19 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 20 | * THE SOFTWARE. 21 | * 22 | * @author GeyserMC 23 | * @link https://github.com/GeyserMC/Geyser 24 | */ 25 | 26 | package org.geysermc.geyser.level.block.type; 27 | 28 | import org.geysermc.geyser.level.block.property.Properties; 29 | import org.geysermc.geyser.level.physics.Direction; 30 | 31 | public class FurnaceBlock extends Block { 32 | public FurnaceBlock(String javaIdentifier, Builder builder) { 33 | super(javaIdentifier, builder); 34 | } 35 | 36 | @Override 37 | protected BlockState setDefaultState(BlockState firstState) { 38 | // Both furnace minecart states look north. 39 | return firstState.withValue(Properties.HORIZONTAL_FACING, Direction.NORTH); 40 | } 41 | } 42 | -------------------------------------------------------------------------------- /core/src/main/java/org/geysermc/geyser/level/block/type/HoneyBlock.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 2024 GeyserMC. http://geysermc.org 3 | * 4 | * Permission is hereby granted, free of charge, to any person obtaining a copy 5 | * of this software and associated documentation files (the "Software"), to deal 6 | * in the Software without restriction, including without limitation the rights 7 | * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 8 | * copies of the Software, and to permit persons to whom the Software is 9 | * furnished to do so, subject to the following conditions: 10 | * 11 | * The above copyright notice and this permission notice shall be included in 12 | * all copies or substantial portions of the Software. 13 | * 14 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 15 | * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 16 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 17 | * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 18 | * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 19 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 20 | * THE SOFTWARE. 21 | * 22 | * @author GeyserMC 23 | * @link https://github.com/GeyserMC/Geyser 24 | */ 25 | 26 | package org.geysermc.geyser.level.block.type; 27 | 28 | public class HoneyBlock extends Block { 29 | public HoneyBlock(String javaIdentifier, Builder builder) { 30 | super(javaIdentifier, builder); 31 | } 32 | } 33 | -------------------------------------------------------------------------------- /core/src/main/java/org/geysermc/geyser/level/block/type/SpawnerBlock.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 2024 GeyserMC. http://geysermc.org 3 | * 4 | * Permission is hereby granted, free of charge, to any person obtaining a copy 5 | * of this software and associated documentation files (the "Software"), to deal 6 | * in the Software without restriction, including without limitation the rights 7 | * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 8 | * copies of the Software, and to permit persons to whom the Software is 9 | * furnished to do so, subject to the following conditions: 10 | * 11 | * The above copyright notice and this permission notice shall be included in 12 | * all copies or substantial portions of the Software. 13 | * 14 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 15 | * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 16 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 17 | * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 18 | * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 19 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 20 | * THE SOFTWARE. 21 | * 22 | * @author GeyserMC 23 | * @link https://github.com/GeyserMC/Geyser 24 | */ 25 | 26 | package org.geysermc.geyser.level.block.type; 27 | 28 | public class SpawnerBlock extends Block { 29 | public SpawnerBlock(String javaIdentifier, Builder builder) { 30 | super(javaIdentifier, builder); 31 | } 32 | } 33 | -------------------------------------------------------------------------------- /core/src/main/java/org/geysermc/geyser/level/block/type/TrapDoorBlock.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 2024 GeyserMC. http://geysermc.org 3 | * 4 | * Permission is hereby granted, free of charge, to any person obtaining a copy 5 | * of this software and associated documentation files (the "Software"), to deal 6 | * in the Software without restriction, including without limitation the rights 7 | * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 8 | * copies of the Software, and to permit persons to whom the Software is 9 | * furnished to do so, subject to the following conditions: 10 | * 11 | * The above copyright notice and this permission notice shall be included in 12 | * all copies or substantial portions of the Software. 13 | * 14 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 15 | * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 16 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 17 | * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 18 | * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 19 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 20 | * THE SOFTWARE. 21 | * 22 | * @author GeyserMC 23 | * @link https://github.com/GeyserMC/Geyser 24 | */ 25 | 26 | package org.geysermc.geyser.level.block.type; 27 | 28 | public class TrapDoorBlock extends Block { 29 | public TrapDoorBlock(String javaIdentifier, Builder builder) { 30 | super(javaIdentifier, builder); 31 | } 32 | } 33 | -------------------------------------------------------------------------------- /core/src/main/java/org/geysermc/geyser/level/block/type/WaterBlock.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 2024 GeyserMC. http://geysermc.org 3 | * 4 | * Permission is hereby granted, free of charge, to any person obtaining a copy 5 | * of this software and associated documentation files (the "Software"), to deal 6 | * in the Software without restriction, including without limitation the rights 7 | * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 8 | * copies of the Software, and to permit persons to whom the Software is 9 | * furnished to do so, subject to the following conditions: 10 | * 11 | * The above copyright notice and this permission notice shall be included in 12 | * all copies or substantial portions of the Software. 13 | * 14 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 15 | * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 16 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 17 | * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 18 | * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 19 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 20 | * THE SOFTWARE. 21 | * 22 | * @author GeyserMC 23 | * @link https://github.com/GeyserMC/Geyser 24 | */ 25 | 26 | package org.geysermc.geyser.level.block.type; 27 | 28 | public class WaterBlock extends Block { 29 | public WaterBlock(String javaIdentifier, Builder builder) { 30 | super(javaIdentifier, builder); 31 | } 32 | } 33 | -------------------------------------------------------------------------------- /core/src/main/java/org/geysermc/geyser/level/chunk/GeyserChunk.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 2019-2022 GeyserMC. http://geysermc.org 3 | * 4 | * Permission is hereby granted, free of charge, to any person obtaining a copy 5 | * of this software and associated documentation files (the "Software"), to deal 6 | * in the Software without restriction, including without limitation the rights 7 | * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 8 | * copies of the Software, and to permit persons to whom the Software is 9 | * furnished to do so, subject to the following conditions: 10 | * 11 | * The above copyright notice and this permission notice shall be included in 12 | * all copies or substantial portions of the Software. 13 | * 14 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 15 | * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 16 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 17 | * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 18 | * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 19 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 20 | * THE SOFTWARE. 21 | * 22 | * @author GeyserMC 23 | * @link https://github.com/GeyserMC/Geyser 24 | */ 25 | 26 | package org.geysermc.geyser.level.chunk; 27 | 28 | import org.geysermc.mcprotocollib.protocol.data.game.chunk.DataPalette; 29 | 30 | /** 31 | * Acts as a lightweight chunk class that doesn't store biomes, heightmaps or block entities. 32 | */ 33 | public record GeyserChunk(DataPalette[] sections) { 34 | 35 | public static GeyserChunk from(DataPalette[] sections) { 36 | return new GeyserChunk(sections); 37 | } 38 | } 39 | -------------------------------------------------------------------------------- /core/src/main/java/org/geysermc/geyser/level/physics/Axis.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 2019-2022 GeyserMC. http://geysermc.org 3 | * 4 | * Permission is hereby granted, free of charge, to any person obtaining a copy 5 | * of this software and associated documentation files (the "Software"), to deal 6 | * in the Software without restriction, including without limitation the rights 7 | * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 8 | * copies of the Software, and to permit persons to whom the Software is 9 | * furnished to do so, subject to the following conditions: 10 | * 11 | * The above copyright notice and this permission notice shall be included in 12 | * all copies or substantial portions of the Software. 13 | * 14 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 15 | * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 16 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 17 | * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 18 | * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 19 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 20 | * THE SOFTWARE. 21 | * 22 | * @author GeyserMC 23 | * @link https://github.com/GeyserMC/Geyser 24 | */ 25 | 26 | package org.geysermc.geyser.level.physics; 27 | 28 | import org.cloudburstmc.math.vector.Vector3d; 29 | 30 | public enum Axis { 31 | X, Y, Z; 32 | 33 | public static final Axis[] VALUES = values(); 34 | 35 | /** 36 | * @param vector The vector 37 | * @return The component of the vector in this axis 38 | */ 39 | public double choose(Vector3d vector) { 40 | return switch (this) { 41 | case X -> vector.getX(); 42 | case Y -> vector.getY(); 43 | case Z -> vector.getZ(); 44 | }; 45 | } 46 | } 47 | -------------------------------------------------------------------------------- /core/src/main/java/org/geysermc/geyser/level/physics/CollisionResult.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 2024 GeyserMC. http://geysermc.org 3 | * 4 | * Permission is hereby granted, free of charge, to any person obtaining a copy 5 | * of this software and associated documentation files (the "Software"), to deal 6 | * in the Software without restriction, including without limitation the rights 7 | * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 8 | * copies of the Software, and to permit persons to whom the Software is 9 | * furnished to do so, subject to the following conditions: 10 | * 11 | * The above copyright notice and this permission notice shall be included in 12 | * all copies or substantial portions of the Software. 13 | * 14 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 15 | * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 16 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 17 | * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 18 | * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 19 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 20 | * THE SOFTWARE. 21 | * 22 | * @author GeyserMC 23 | * @link https://github.com/GeyserMC/Geyser 24 | */ 25 | 26 | package org.geysermc.geyser.level.physics; 27 | 28 | import net.kyori.adventure.util.TriState; 29 | import org.cloudburstmc.math.vector.Vector3d; 30 | 31 | /** 32 | * Holds the result of a collision check. 33 | */ 34 | public record CollisionResult(Vector3d correctedMovement, TriState onGround) { 35 | } 36 | -------------------------------------------------------------------------------- /core/src/main/java/org/geysermc/geyser/network/netty/DefaultChannelPipelinePublic.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 2019-2022 GeyserMC. http://geysermc.org 3 | * 4 | * Permission is hereby granted, free of charge, to any person obtaining a copy 5 | * of this software and associated documentation files (the "Software"), to deal 6 | * in the Software without restriction, including without limitation the rights 7 | * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 8 | * copies of the Software, and to permit persons to whom the Software is 9 | * furnished to do so, subject to the following conditions: 10 | * 11 | * The above copyright notice and this permission notice shall be included in 12 | * all copies or substantial portions of the Software. 13 | * 14 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 15 | * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 16 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 17 | * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 18 | * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 19 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 20 | * THE SOFTWARE. 21 | * 22 | * @author GeyserMC 23 | * @link https://github.com/GeyserMC/Geyser 24 | */ 25 | 26 | package org.geysermc.geyser.network.netty; 27 | 28 | import io.netty.channel.Channel; 29 | import io.netty.channel.DefaultChannelPipeline; 30 | 31 | /** 32 | * Exists solely to make DefaultChannelPipeline's protected constructor public 33 | */ 34 | public class DefaultChannelPipelinePublic extends DefaultChannelPipeline { 35 | public DefaultChannelPipelinePublic(Channel channel) { 36 | super(channel); 37 | } 38 | } 39 | -------------------------------------------------------------------------------- /core/src/main/java/org/geysermc/geyser/registry/loader/MultiResourceRegistryLoader.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 2019-2022 GeyserMC. http://geysermc.org 3 | * 4 | * Permission is hereby granted, free of charge, to any person obtaining a copy 5 | * of this software and associated documentation files (the "Software"), to deal 6 | * in the Software without restriction, including without limitation the rights 7 | * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 8 | * copies of the Software, and to permit persons to whom the Software is 9 | * furnished to do so, subject to the following conditions: 10 | * 11 | * The above copyright notice and this permission notice shall be included in 12 | * all copies or substantial portions of the Software. 13 | * 14 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 15 | * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 16 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 17 | * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 18 | * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 19 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 20 | * THE SOFTWARE. 21 | * 22 | * @author GeyserMC 23 | * @link https://github.com/GeyserMC/Geyser 24 | */ 25 | 26 | package org.geysermc.geyser.registry.loader; 27 | 28 | import it.unimi.dsi.fastutil.Pair; 29 | 30 | /** 31 | * A RegistryLoader that loads data from two different locations, yet with the same input type. 32 | * 33 | * @param the input type 34 | * @param the value 35 | */ 36 | public abstract class MultiResourceRegistryLoader implements RegistryLoader, V> { 37 | } -------------------------------------------------------------------------------- /core/src/main/java/org/geysermc/geyser/registry/provider/ProviderSupplier.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 2019-2022 GeyserMC. http://geysermc.org 3 | * 4 | * Permission is hereby granted, free of charge, to any person obtaining a copy 5 | * of this software and associated documentation files (the "Software"), to deal 6 | * in the Software without restriction, including without limitation the rights 7 | * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 8 | * copies of the Software, and to permit persons to whom the Software is 9 | * furnished to do so, subject to the following conditions: 10 | * 11 | * The above copyright notice and this permission notice shall be included in 12 | * all copies or substantial portions of the Software. 13 | * 14 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 15 | * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 16 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 17 | * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 18 | * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 19 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 20 | * THE SOFTWARE. 21 | * 22 | * @author GeyserMC 23 | * @link https://github.com/GeyserMC/Geyser 24 | */ 25 | 26 | package org.geysermc.geyser.registry.provider; 27 | 28 | public interface ProviderSupplier { 29 | 30 | Object create(Object... args); 31 | } 32 | -------------------------------------------------------------------------------- /core/src/main/java/org/geysermc/geyser/registry/type/NonVanillaItemRegistration.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 2019-2022 GeyserMC. http://geysermc.org 3 | * 4 | * Permission is hereby granted, free of charge, to any person obtaining a copy 5 | * of this software and associated documentation files (the "Software"), to deal 6 | * in the Software without restriction, including without limitation the rights 7 | * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 8 | * copies of the Software, and to permit persons to whom the Software is 9 | * furnished to do so, subject to the following conditions: 10 | * 11 | * The above copyright notice and this permission notice shall be included in 12 | * all copies or substantial portions of the Software. 13 | * 14 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 15 | * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 16 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 17 | * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 18 | * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 19 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 20 | * THE SOFTWARE. 21 | * 22 | * @author GeyserMC 23 | * @link https://github.com/GeyserMC/Geyser 24 | */ 25 | 26 | package org.geysermc.geyser.registry.type; 27 | 28 | import org.geysermc.geyser.item.type.Item; 29 | 30 | /** 31 | * The return data of a successful registration of a custom item. 32 | */ 33 | public record NonVanillaItemRegistration(Item javaItem, ItemMapping mapping) { 34 | } 35 | -------------------------------------------------------------------------------- /core/src/main/java/org/geysermc/geyser/registry/type/PaletteItem.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 2019-2022 GeyserMC. http://geysermc.org 3 | * 4 | * Permission is hereby granted, free of charge, to any person obtaining a copy 5 | * of this software and associated documentation files (the "Software"), to deal 6 | * in the Software without restriction, including without limitation the rights 7 | * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 8 | * copies of the Software, and to permit persons to whom the Software is 9 | * furnished to do so, subject to the following conditions: 10 | * 11 | * The above copyright notice and this permission notice shall be included in 12 | * all copies or substantial portions of the Software. 13 | * 14 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 15 | * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 16 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 17 | * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 18 | * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 19 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 20 | * THE SOFTWARE. 21 | * 22 | * @author GeyserMC 23 | * @link https://github.com/GeyserMC/Geyser 24 | */ 25 | 26 | package org.geysermc.geyser.registry.type; 27 | 28 | import lombok.Data; 29 | 30 | @Data 31 | public class PaletteItem { 32 | String name; 33 | int id; 34 | int version; 35 | boolean componentBased; 36 | } 37 | -------------------------------------------------------------------------------- /core/src/main/java/org/geysermc/geyser/registry/type/ParticleMapping.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 2019-2022 GeyserMC. http://geysermc.org 3 | * 4 | * Permission is hereby granted, free of charge, to any person obtaining a copy 5 | * of this software and associated documentation files (the "Software"), to deal 6 | * in the Software without restriction, including without limitation the rights 7 | * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 8 | * copies of the Software, and to permit persons to whom the Software is 9 | * furnished to do so, subject to the following conditions: 10 | * 11 | * The above copyright notice and this permission notice shall be included in 12 | * all copies or substantial portions of the Software. 13 | * 14 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 15 | * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 16 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 17 | * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 18 | * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 19 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 20 | * THE SOFTWARE. 21 | * 22 | * @author GeyserMC 23 | * @link https://github.com/GeyserMC/Geyser 24 | */ 25 | 26 | package org.geysermc.geyser.registry.type; 27 | 28 | import org.checkerframework.checker.nullness.qual.Nullable; 29 | import org.cloudburstmc.protocol.bedrock.data.LevelEventType; 30 | 31 | public record ParticleMapping(@Nullable LevelEventType levelEventType, @Nullable String identifier) { 32 | } -------------------------------------------------------------------------------- /core/src/main/java/org/geysermc/geyser/scoreboard/UpdateType.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 2019-2022 GeyserMC. http://geysermc.org 3 | * 4 | * Permission is hereby granted, free of charge, to any person obtaining a copy 5 | * of this software and associated documentation files (the "Software"), to deal 6 | * in the Software without restriction, including without limitation the rights 7 | * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 8 | * copies of the Software, and to permit persons to whom the Software is 9 | * furnished to do so, subject to the following conditions: 10 | * 11 | * The above copyright notice and this permission notice shall be included in 12 | * all copies or substantial portions of the Software. 13 | * 14 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 15 | * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 16 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 17 | * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 18 | * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 19 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 20 | * THE SOFTWARE. 21 | * 22 | * @author GeyserMC 23 | * @link https://github.com/GeyserMC/Geyser 24 | */ 25 | 26 | package org.geysermc.geyser.scoreboard; 27 | 28 | public enum UpdateType { 29 | REMOVE, 30 | /** 31 | * Nothing has changed, it's cool 32 | */ 33 | NOTHING, 34 | ADD, 35 | /** 36 | * Hey, something has been updated!
37 | * Only used in {@link Objective Objective} 38 | */ 39 | UPDATE 40 | } 41 | -------------------------------------------------------------------------------- /core/src/main/java/org/geysermc/geyser/session/auth/AuthData.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 2019-2022 GeyserMC. http://geysermc.org 3 | * 4 | * Permission is hereby granted, free of charge, to any person obtaining a copy 5 | * of this software and associated documentation files (the "Software"), to deal 6 | * in the Software without restriction, including without limitation the rights 7 | * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 8 | * copies of the Software, and to permit persons to whom the Software is 9 | * furnished to do so, subject to the following conditions: 10 | * 11 | * The above copyright notice and this permission notice shall be included in 12 | * all copies or substantial portions of the Software. 13 | * 14 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 15 | * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 16 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 17 | * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 18 | * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 19 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 20 | * THE SOFTWARE. 21 | * 22 | * @author GeyserMC 23 | * @link https://github.com/GeyserMC/Geyser 24 | */ 25 | 26 | package org.geysermc.geyser.session.auth; 27 | 28 | import java.util.UUID; 29 | 30 | public record AuthData(String name, UUID uuid, String xuid) { 31 | } 32 | -------------------------------------------------------------------------------- /core/src/main/java/org/geysermc/geyser/session/cache/registry/RegistryEntryData.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 2025 GeyserMC. http://geysermc.org 3 | * 4 | * Permission is hereby granted, free of charge, to any person obtaining a copy 5 | * of this software and associated documentation files (the "Software"), to deal 6 | * in the Software without restriction, including without limitation the rights 7 | * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 8 | * copies of the Software, and to permit persons to whom the Software is 9 | * furnished to do so, subject to the following conditions: 10 | * 11 | * The above copyright notice and this permission notice shall be included in 12 | * all copies or substantial portions of the Software. 13 | * 14 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 15 | * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 16 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 17 | * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 18 | * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 19 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 20 | * THE SOFTWARE. 21 | * 22 | * @author GeyserMC 23 | * @link https://github.com/GeyserMC/Geyser 24 | */ 25 | 26 | package org.geysermc.geyser.session.cache.registry; 27 | 28 | import net.kyori.adventure.key.Key; 29 | 30 | public record RegistryEntryData(Key key, T data) { 31 | } 32 | -------------------------------------------------------------------------------- /core/src/main/java/org/geysermc/geyser/session/cache/registry/RegistryUnit.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 2025 GeyserMC. http://geysermc.org 3 | * 4 | * Permission is hereby granted, free of charge, to any person obtaining a copy 5 | * of this software and associated documentation files (the "Software"), to deal 6 | * in the Software without restriction, including without limitation the rights 7 | * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 8 | * copies of the Software, and to permit persons to whom the Software is 9 | * furnished to do so, subject to the following conditions: 10 | * 11 | * The above copyright notice and this permission notice shall be included in 12 | * all copies or substantial portions of the Software. 13 | * 14 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 15 | * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 16 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 17 | * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 18 | * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 19 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 20 | * THE SOFTWARE. 21 | * 22 | * @author GeyserMC 23 | * @link https://github.com/GeyserMC/Geyser 24 | */ 25 | 26 | package org.geysermc.geyser.session.cache.registry; 27 | 28 | /** 29 | * Used with {@link org.geysermc.geyser.session.cache.RegistryCache.RegistryReader#UNIT} to load registries without loading any data. 30 | * 31 | *

This is usually done when registries need to be loaded to make ID->key or key->ID conversions, but actual data isn't needed.

32 | */ 33 | public enum RegistryUnit { 34 | INSTANCE 35 | } 36 | -------------------------------------------------------------------------------- /core/src/main/java/org/geysermc/geyser/session/cache/tags/Tag.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 2024 GeyserMC. http://geysermc.org 3 | * 4 | * Permission is hereby granted, free of charge, to any person obtaining a copy 5 | * of this software and associated documentation files (the "Software"), to deal 6 | * in the Software without restriction, including without limitation the rights 7 | * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 8 | * copies of the Software, and to permit persons to whom the Software is 9 | * furnished to do so, subject to the following conditions: 10 | * 11 | * The above copyright notice and this permission notice shall be included in 12 | * all copies or substantial portions of the Software. 13 | * 14 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 15 | * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 16 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 17 | * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 18 | * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 19 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 20 | * THE SOFTWARE. 21 | * 22 | * @author GeyserMC 23 | * @link https://github.com/GeyserMC/Geyser 24 | */ 25 | 26 | package org.geysermc.geyser.session.cache.tags; 27 | 28 | import net.kyori.adventure.key.Key; 29 | import org.geysermc.geyser.session.cache.registry.JavaRegistryKey; 30 | 31 | /** 32 | * A tag in any of the registries that tags are loaded for by Geyser. 33 | */ 34 | public record Tag(JavaRegistryKey registry, Key tag) { 35 | } 36 | -------------------------------------------------------------------------------- /core/src/main/java/org/geysermc/geyser/translator/collision/OtherCollision.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 2019-2022 GeyserMC. http://geysermc.org 3 | * 4 | * Permission is hereby granted, free of charge, to any person obtaining a copy 5 | * of this software and associated documentation files (the "Software"), to deal 6 | * in the Software without restriction, including without limitation the rights 7 | * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 8 | * copies of the Software, and to permit persons to whom the Software is 9 | * furnished to do so, subject to the following conditions: 10 | * 11 | * The above copyright notice and this permission notice shall be included in 12 | * all copies or substantial portions of the Software. 13 | * 14 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 15 | * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 16 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 17 | * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 18 | * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 19 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 20 | * THE SOFTWARE. 21 | * 22 | * @author GeyserMC 23 | * @link https://github.com/GeyserMC/Geyser 24 | */ 25 | 26 | package org.geysermc.geyser.translator.collision; 27 | 28 | import lombok.EqualsAndHashCode; 29 | import org.geysermc.geyser.level.physics.BoundingBox; 30 | 31 | @EqualsAndHashCode(callSuper = true) 32 | public class OtherCollision extends BlockCollision { 33 | 34 | public OtherCollision(BoundingBox[] boundingBoxes) { 35 | super(boundingBoxes); 36 | } 37 | } 38 | -------------------------------------------------------------------------------- /core/src/main/java/org/geysermc/geyser/translator/inventory/horse/DonkeyInventoryTranslator.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 2019-2022 GeyserMC. http://geysermc.org 3 | * 4 | * Permission is hereby granted, free of charge, to any person obtaining a copy 5 | * of this software and associated documentation files (the "Software"), to deal 6 | * in the Software without restriction, including without limitation the rights 7 | * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 8 | * copies of the Software, and to permit persons to whom the Software is 9 | * furnished to do so, subject to the following conditions: 10 | * 11 | * The above copyright notice and this permission notice shall be included in 12 | * all copies or substantial portions of the Software. 13 | * 14 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 15 | * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 16 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 17 | * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 18 | * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 19 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 20 | * THE SOFTWARE. 21 | * 22 | * @author GeyserMC 23 | * @link https://github.com/GeyserMC/Geyser 24 | */ 25 | 26 | package org.geysermc.geyser.translator.inventory.horse; 27 | 28 | public class DonkeyInventoryTranslator extends ChestedHorseInventoryTranslator { 29 | public DonkeyInventoryTranslator(int size) { 30 | super(size, 0); 31 | } 32 | } 33 | -------------------------------------------------------------------------------- /core/src/main/java/org/geysermc/geyser/translator/inventory/horse/LlamaInventoryTranslator.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 2019-2022 GeyserMC. http://geysermc.org 3 | * 4 | * Permission is hereby granted, free of charge, to any person obtaining a copy 5 | * of this software and associated documentation files (the "Software"), to deal 6 | * in the Software without restriction, including without limitation the rights 7 | * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 8 | * copies of the Software, and to permit persons to whom the Software is 9 | * furnished to do so, subject to the following conditions: 10 | * 11 | * The above copyright notice and this permission notice shall be included in 12 | * all copies or substantial portions of the Software. 13 | * 14 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 15 | * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 16 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 17 | * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 18 | * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 19 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 20 | * THE SOFTWARE. 21 | * 22 | * @author GeyserMC 23 | * @link https://github.com/GeyserMC/Geyser 24 | */ 25 | 26 | package org.geysermc.geyser.translator.inventory.horse; 27 | 28 | public class LlamaInventoryTranslator extends ChestedHorseInventoryTranslator { 29 | public LlamaInventoryTranslator(int size) { 30 | super(size, 1); 31 | } 32 | } 33 | -------------------------------------------------------------------------------- /core/src/main/java/org/geysermc/geyser/translator/level/block/entity/BlockEntity.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 2019-2022 GeyserMC. http://geysermc.org 3 | * 4 | * Permission is hereby granted, free of charge, to any person obtaining a copy 5 | * of this software and associated documentation files (the "Software"), to deal 6 | * in the Software without restriction, including without limitation the rights 7 | * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 8 | * copies of the Software, and to permit persons to whom the Software is 9 | * furnished to do so, subject to the following conditions: 10 | * 11 | * The above copyright notice and this permission notice shall be included in 12 | * all copies or substantial portions of the Software. 13 | * 14 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 15 | * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 16 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 17 | * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 18 | * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 19 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 20 | * THE SOFTWARE. 21 | * 22 | * @author GeyserMC 23 | * @link https://github.com/GeyserMC/Geyser 24 | */ 25 | 26 | package org.geysermc.geyser.translator.level.block.entity; 27 | 28 | import org.geysermc.mcprotocollib.protocol.data.game.level.block.BlockEntityType; 29 | 30 | import java.lang.annotation.Retention; 31 | import java.lang.annotation.RetentionPolicy; 32 | 33 | @Retention(value = RetentionPolicy.RUNTIME) 34 | public @interface BlockEntity { 35 | 36 | /** 37 | * The Java block entity type 38 | * @return the type of the block entity 39 | */ 40 | BlockEntityType[] type(); 41 | } 42 | -------------------------------------------------------------------------------- /core/src/main/java/org/geysermc/geyser/translator/level/block/entity/EmptyBlockEntityTranslator.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 2019-2022 GeyserMC. http://geysermc.org 3 | * 4 | * Permission is hereby granted, free of charge, to any person obtaining a copy 5 | * of this software and associated documentation files (the "Software"), to deal 6 | * in the Software without restriction, including without limitation the rights 7 | * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 8 | * copies of the Software, and to permit persons to whom the Software is 9 | * furnished to do so, subject to the following conditions: 10 | * 11 | * The above copyright notice and this permission notice shall be included in 12 | * all copies or substantial portions of the Software. 13 | * 14 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 15 | * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 16 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 17 | * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 18 | * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 19 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 20 | * THE SOFTWARE. 21 | * 22 | * @author GeyserMC 23 | * @link https://github.com/GeyserMC/Geyser 24 | */ 25 | 26 | package org.geysermc.geyser.translator.level.block.entity; 27 | 28 | import org.cloudburstmc.nbt.NbtMap; 29 | import org.cloudburstmc.nbt.NbtMapBuilder; 30 | import org.geysermc.geyser.level.block.type.BlockState; 31 | import org.geysermc.geyser.session.GeyserSession; 32 | 33 | public class EmptyBlockEntityTranslator extends BlockEntityTranslator { 34 | @Override 35 | public void translateTag(GeyserSession session, NbtMapBuilder bedrockNbt, NbtMap javaNbt, BlockState blockState) { 36 | } 37 | } 38 | -------------------------------------------------------------------------------- /core/src/main/java/org/geysermc/geyser/translator/level/block/entity/HangingSignBlockEntityTranslator.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 2019-2023 GeyserMC. http://geysermc.org 3 | * 4 | * Permission is hereby granted, free of charge, to any person obtaining a copy 5 | * of this software and associated documentation files (the "Software"), to deal 6 | * in the Software without restriction, including without limitation the rights 7 | * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 8 | * copies of the Software, and to permit persons to whom the Software is 9 | * furnished to do so, subject to the following conditions: 10 | * 11 | * The above copyright notice and this permission notice shall be included in 12 | * all copies or substantial portions of the Software. 13 | * 14 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 15 | * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 16 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 17 | * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 18 | * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 19 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 20 | * THE SOFTWARE. 21 | * 22 | * @author GeyserMC 23 | * @link https://github.com/GeyserMC/Geyser 24 | */ 25 | 26 | package org.geysermc.geyser.translator.level.block.entity; 27 | 28 | import org.geysermc.geyser.util.SignUtils; 29 | import org.geysermc.mcprotocollib.protocol.data.game.level.block.BlockEntityType; 30 | 31 | @BlockEntity(type = BlockEntityType.HANGING_SIGN) 32 | public class HangingSignBlockEntityTranslator extends SignBlockEntityTranslator { 33 | 34 | @Override 35 | public int signWidthMax() { 36 | return SignUtils.HANGING_SIGN_WIDTH_MAX; // Smaller than that for BlockEntityType.SIGN 37 | } 38 | } 39 | -------------------------------------------------------------------------------- /core/src/main/java/org/geysermc/geyser/translator/level/block/entity/RequiresBlockState.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 2019-2022 GeyserMC. http://geysermc.org 3 | * 4 | * Permission is hereby granted, free of charge, to any person obtaining a copy 5 | * of this software and associated documentation files (the "Software"), to deal 6 | * in the Software without restriction, including without limitation the rights 7 | * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 8 | * copies of the Software, and to permit persons to whom the Software is 9 | * furnished to do so, subject to the following conditions: 10 | * 11 | * The above copyright notice and this permission notice shall be included in 12 | * all copies or substantial portions of the Software. 13 | * 14 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 15 | * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 16 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 17 | * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 18 | * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 19 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 20 | * THE SOFTWARE. 21 | * 22 | * @author GeyserMC 23 | * @link https://github.com/GeyserMC/Geyser 24 | */ 25 | 26 | package org.geysermc.geyser.translator.level.block.entity; 27 | 28 | /** 29 | * Implemented in block entities if their Java block state is required for additional values in Bedrock 30 | */ 31 | public interface RequiresBlockState { 32 | } 33 | -------------------------------------------------------------------------------- /core/src/main/java/org/geysermc/geyser/translator/protocol/Translator.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 2019-2022 GeyserMC. http://geysermc.org 3 | * 4 | * Permission is hereby granted, free of charge, to any person obtaining a copy 5 | * of this software and associated documentation files (the "Software"), to deal 6 | * in the Software without restriction, including without limitation the rights 7 | * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 8 | * copies of the Software, and to permit persons to whom the Software is 9 | * furnished to do so, subject to the following conditions: 10 | * 11 | * The above copyright notice and this permission notice shall be included in 12 | * all copies or substantial portions of the Software. 13 | * 14 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 15 | * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 16 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 17 | * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 18 | * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 19 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 20 | * THE SOFTWARE. 21 | * 22 | * @author GeyserMC 23 | * @link https://github.com/GeyserMC/Geyser 24 | */ 25 | package org.geysermc.geyser.translator.protocol; 26 | 27 | import java.lang.annotation.Retention; 28 | import java.lang.annotation.RetentionPolicy; 29 | 30 | @Retention(value = RetentionPolicy.RUNTIME) 31 | public @interface Translator { 32 | Class packet(); 33 | } 34 | -------------------------------------------------------------------------------- /core/src/main/java/org/geysermc/geyser/util/EnvironmentUtils.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 2024 GeyserMC. http://geysermc.org 3 | * 4 | * Permission is hereby granted, free of charge, to any person obtaining a copy 5 | * of this software and associated documentation files (the "Software"), to deal 6 | * in the Software without restriction, including without limitation the rights 7 | * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 8 | * copies of the Software, and to permit persons to whom the Software is 9 | * furnished to do so, subject to the following conditions: 10 | * 11 | * The above copyright notice and this permission notice shall be included in 12 | * all copies or substantial portions of the Software. 13 | * 14 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 15 | * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 16 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 17 | * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 18 | * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 19 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 20 | * THE SOFTWARE. 21 | * 22 | * @author GeyserMC 23 | * @link https://github.com/GeyserMC/Geyser 24 | */ 25 | 26 | package org.geysermc.geyser.util; 27 | 28 | public final class EnvironmentUtils { 29 | public static final boolean IS_UNIT_TESTING = isUnitTesting(); 30 | 31 | private EnvironmentUtils() {} 32 | 33 | private static boolean isUnitTesting() { 34 | for (StackTraceElement element : Thread.currentThread().getStackTrace()) { 35 | if (element.getClassName().startsWith("org.junit.")) { 36 | return true; 37 | } 38 | } 39 | return false; 40 | } 41 | } 42 | -------------------------------------------------------------------------------- /core/src/main/java/org/geysermc/geyser/util/MinecraftKey.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 2024 GeyserMC. http://geysermc.org 3 | * 4 | * Permission is hereby granted, free of charge, to any person obtaining a copy 5 | * of this software and associated documentation files (the "Software"), to deal 6 | * in the Software without restriction, including without limitation the rights 7 | * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 8 | * copies of the Software, and to permit persons to whom the Software is 9 | * furnished to do so, subject to the following conditions: 10 | * 11 | * The above copyright notice and this permission notice shall be included in 12 | * all copies or substantial portions of the Software. 13 | * 14 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 15 | * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 16 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 17 | * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 18 | * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 19 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 20 | * THE SOFTWARE. 21 | * 22 | * @author GeyserMC 23 | * @link https://github.com/GeyserMC/Geyser 24 | */ 25 | 26 | package org.geysermc.geyser.util; 27 | 28 | import net.kyori.adventure.key.Key; 29 | import org.intellij.lang.annotations.Subst; 30 | 31 | public final class MinecraftKey { 32 | 33 | /** 34 | * To prevent constant warnings from invalid regex. 35 | */ 36 | public static Key key(@Subst("empty") String s) { 37 | return Key.key(s); 38 | } 39 | } 40 | -------------------------------------------------------------------------------- /core/src/main/java/org/geysermc/geyser/util/ThrowingBiConsumer.java: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 2024 GeyserMC. http://geysermc.org 3 | * 4 | * Permission is hereby granted, free of charge, to any person obtaining a copy 5 | * of this software and associated documentation files (the "Software"), to deal 6 | * in the Software without restriction, including without limitation the rights 7 | * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 8 | * copies of the Software, and to permit persons to whom the Software is 9 | * furnished to do so, subject to the following conditions: 10 | * 11 | * The above copyright notice and this permission notice shall be included in 12 | * all copies or substantial portions of the Software. 13 | * 14 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 15 | * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 16 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 17 | * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 18 | * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 19 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 20 | * THE SOFTWARE. 21 | * 22 | * @author GeyserMC 23 | * @link https://github.com/GeyserMC/Geyser 24 | */ 25 | 26 | package org.geysermc.geyser.util; 27 | 28 | import java.util.function.BiConsumer; 29 | 30 | @FunctionalInterface 31 | public interface ThrowingBiConsumer extends BiConsumer { 32 | @Override 33 | default void accept(T t, U u) { 34 | try { 35 | acceptThrows(t, u); 36 | } catch (Throwable e) { 37 | throw new RuntimeException(e); 38 | } 39 | } 40 | 41 | void acceptThrows(T t, U u) throws Throwable; 42 | } 43 | -------------------------------------------------------------------------------- /core/src/main/resources/assets/geyser/icon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Shanwer/Geyser/edb1898da9be91114a6f7d862229c257ad2643f9/core/src/main/resources/assets/geyser/icon.png -------------------------------------------------------------------------------- /core/src/main/resources/bedrock/biome_definitions.dat: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Shanwer/Geyser/edb1898da9be91114a6f7d862229c257ad2643f9/core/src/main/resources/bedrock/biome_definitions.dat -------------------------------------------------------------------------------- /core/src/main/resources/bedrock/block_palette.1_21_50.nbt: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Shanwer/Geyser/edb1898da9be91114a6f7d862229c257ad2643f9/core/src/main/resources/bedrock/block_palette.1_21_50.nbt -------------------------------------------------------------------------------- /core/src/main/resources/bedrock/block_palette.1_21_60.nbt: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Shanwer/Geyser/edb1898da9be91114a6f7d862229c257ad2643f9/core/src/main/resources/bedrock/block_palette.1_21_60.nbt -------------------------------------------------------------------------------- /core/src/main/resources/bedrock/block_palette.1_21_70.nbt: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Shanwer/Geyser/edb1898da9be91114a6f7d862229c257ad2643f9/core/src/main/resources/bedrock/block_palette.1_21_70.nbt -------------------------------------------------------------------------------- /core/src/main/resources/bedrock/block_palette.1_21_80.nbt: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Shanwer/Geyser/edb1898da9be91114a6f7d862229c257ad2643f9/core/src/main/resources/bedrock/block_palette.1_21_80.nbt -------------------------------------------------------------------------------- /core/src/main/resources/bedrock/entity_identifiers.dat: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Shanwer/Geyser/edb1898da9be91114a6f7d862229c257ad2643f9/core/src/main/resources/bedrock/entity_identifiers.dat -------------------------------------------------------------------------------- /core/src/main/resources/bedrock/item_components.nbt: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Shanwer/Geyser/edb1898da9be91114a6f7d862229c257ad2643f9/core/src/main/resources/bedrock/item_components.nbt -------------------------------------------------------------------------------- /core/src/main/resources/bedrock/skin/geometry.humanoid.customskull.json: -------------------------------------------------------------------------------- 1 | { 2 | "format_version": "1.10.0", 3 | "geometry.humanoid.customskull": { 4 | "texturewidth": 64, 5 | "textureheight": 64, 6 | "visible_bounds_width": 2, 7 | "visible_bounds_height": 1, 8 | "visible_bounds_offset": [0, 0, 0], 9 | "bones": [ 10 | { 11 | "name": "head", 12 | "pivot": [0, 24, 0], 13 | "cubes": [ 14 | {"origin": [-4, 0, -4], "size": [8, 8, 8], "uv": [0, 0]} 15 | ] 16 | }, 17 | { 18 | "name": "hat", 19 | "parent": "head", 20 | "pivot": [0, 24, 0], 21 | "cubes": [ 22 | {"origin": [-4, 0, -4], "size": [8, 8, 8], "uv": [32, 0], "inflate": 0.5} 23 | ] 24 | } 25 | ] 26 | } 27 | } -------------------------------------------------------------------------------- /core/src/main/resources/bedrock/skull_resource_pack/animations/disable.animation.json: -------------------------------------------------------------------------------- 1 | { 2 | "format_version": "1.8.0", 3 | "animations": { 4 | "animation.geyser.disable": { 5 | "loop": true, 6 | "override_previous_animation": true, 7 | "bones": { 8 | "root": { 9 | "scale": 0 10 | } 11 | } 12 | } 13 | } 14 | } 15 | -------------------------------------------------------------------------------- /core/src/main/resources/bedrock/skull_resource_pack/manifest.json: -------------------------------------------------------------------------------- 1 | { 2 | "format_version": 2, 3 | "header": { 4 | "name": "Geyser Player Skull Resource Pack", 5 | "description": "Auto-generated resource pack to support player skulls as custom blocks", 6 | "uuid": "${uuid1}", 7 | "version": [1, 0, 0], 8 | "min_engine_version": [1, 16, 0] 9 | }, 10 | "modules": [ 11 | { 12 | "type": "resources", 13 | "uuid": "${uuid2}", 14 | "version": [1, 0, 0] 15 | } 16 | ] 17 | } -------------------------------------------------------------------------------- /core/src/main/resources/bedrock/skull_resource_pack/textures/terrain_texture.json: -------------------------------------------------------------------------------- 1 | { 2 | "num_mip_levels": 4, 3 | "padding": 8, 4 | "resource_pack_name": "Geyser Player Skull Resource Pack", 5 | "texture_data": { 6 | ${texture_data} 7 | } 8 | } -------------------------------------------------------------------------------- /core/src/main/resources/bedrock/skull_resource_pack_files.txt: -------------------------------------------------------------------------------- 1 | skull_resource_pack/animations/disable.animation.json 2 | skull_resource_pack/animations/player_skull.animation.json 3 | skull_resource_pack/models/blocks/player_skull.geo.json 4 | skull_resource_pack/models/blocks/player_skull_hand.geo.json 5 | skull_resource_pack/models/blocks/player_skull_wall.geo.json 6 | skull_resource_pack/textures/terrain_texture.json 7 | skull_resource_pack/manifest.json 8 | -------------------------------------------------------------------------------- /core/src/main/resources/custom-skulls.yml: -------------------------------------------------------------------------------- 1 | # -------------------------------- 2 | # Geyser Custom Skull Configuration Files 3 | # 4 | # This file is ignored with `add-custom-skull-blocks` disabled. 5 | # See `config.yml` for the main set of configuration values 6 | # 7 | # Custom skulls with the player username, UUID, or texture specified in this file 8 | # will be translated as custom blocks and be displayed in the inventory and on entities. 9 | # -------------------------------- 10 | 11 | # Java player usernames 12 | # Skins will be updated when Geyser starts and players will have to re-download 13 | # the resource pack if any players had changed their skin. 14 | player-usernames: 15 | # - GeyserMC 16 | 17 | # Java player UUIDs 18 | # Skins will be updated when Geyser starts and players will have to re-download 19 | # the resource pack if any players had changed their skin. 20 | player-uuids: 21 | # - 8b8d8e8f-2759-47c6-acb5-5827de8a72b8 22 | 23 | # The long string of characters found in the NBT of custom player heads 24 | player-profiles: 25 | # - ewogICJ0aW1lc3RhbXAiIDogMTY1NzMyMjIzOTgzMywKICAicHJvZmlsZUlkIiA6ICJjZGRiZTUyMGQwNDM0YThiYTFjYzlmYzkyZmRlMmJjZiIsCiAgInByb2ZpbGVOYW1lIiA6ICJBbWJlcmljaHUiLAogICJ0ZXh0dXJlcyIgOiB7CiAgICAiU0tJTiIgOiB7CiAgICAgICJ1cmwiIDogImh0dHA6Ly90ZXh0dXJlcy5taW5lY3JhZnQubmV0L3RleHR1cmUvYTkwNzkwYzU3ZTE4MWVkMTNhZGVkMTRjNDdlZTJmN2M4ZGUzNTMzZTAxN2JhOTU3YWY3YmRmOWRmMWJkZTk0ZiIsCiAgICAgICJtZXRhZGF0YSIgOiB7CiAgICAgICAgIm1vZGVsIiA6ICJzbGltIgogICAgICB9CiAgICB9CiAgfQp9 26 | 27 | # The hash of the skin on Minecraft's skin server (http://textures.minecraft.net/texture/HASH) 28 | skin-hashes: 29 | # - a90790c57e181ed13aded14c47ee2f7c8de3533e017ba957af7bdf9df1bde94f -------------------------------------------------------------------------------- /core/src/main/resources/git.properties: -------------------------------------------------------------------------------- 1 | git.branch=${branch} 2 | git.build.number=${buildNumber} 3 | git.build.version=${projectVersion} 4 | git.commit.id=${commit} 5 | git.commit.id.abbrev=${commitAbbrev} 6 | git.commit.message.full=${commitMessage} 7 | git.remote.origin.url=${repository} 8 | -------------------------------------------------------------------------------- /core/src/main/resources/permissions.yml: -------------------------------------------------------------------------------- 1 | 2 | # Add any permissions here that all players should have. 3 | # Permissions for builtin Geyser commands do not have to be listed here. 4 | 5 | # If an extension/plugin registers their permissions with default values, entries here are typically unnecessary. 6 | # If extensions don't register their permissions, permissions that everyone should have must be added here manually. 7 | 8 | default-permissions: 9 | - geyser.command.help # this is unnecessary 10 | -------------------------------------------------------------------------------- /core/src/test/resources/empty_pack.mcpack: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Shanwer/Geyser/edb1898da9be91114a6f7d862229c257ad2643f9/core/src/test/resources/empty_pack.mcpack -------------------------------------------------------------------------------- /core/src/test/resources/encrypted_pack.zip: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Shanwer/Geyser/edb1898da9be91114a6f7d862229c257ad2643f9/core/src/test/resources/encrypted_pack.zip -------------------------------------------------------------------------------- /core/src/test/resources/encrypted_pack.zip.key: -------------------------------------------------------------------------------- 1 | JAGcSXcXwcODc1YS70GzeWAUKEO172UA -------------------------------------------------------------------------------- /gradle.properties: -------------------------------------------------------------------------------- 1 | # Gradle settings 2 | org.gradle.jvmargs=-Xmx4G 3 | org.gradle.daemon=false 4 | org.gradle.configureondemand=true 5 | org.gradle.parallel=true 6 | org.gradle.caching=true 7 | org.gradle.vfs.watch=false 8 | 9 | group=org.geysermc 10 | id=geyser 11 | version=2.7.1-SNAPSHOT 12 | description=Allows for players from Minecraft: Bedrock Edition to join Minecraft: Java Edition servers. 13 | -------------------------------------------------------------------------------- /gradle/wrapper/gradle-wrapper.jar: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Shanwer/Geyser/edb1898da9be91114a6f7d862229c257ad2643f9/gradle/wrapper/gradle-wrapper.jar -------------------------------------------------------------------------------- /gradle/wrapper/gradle-wrapper.properties: -------------------------------------------------------------------------------- 1 | distributionBase=GRADLE_USER_HOME 2 | distributionPath=wrapper/dists 3 | distributionUrl=https\://services.gradle.org/distributions/gradle-8.11-bin.zip 4 | networkTimeout=10000 5 | validateDistributionUrl=true 6 | zipStoreBase=GRADLE_USER_HOME 7 | zipStorePath=wrapper/dists 8 | -------------------------------------------------------------------------------- /settings.gradle.kts: -------------------------------------------------------------------------------- 1 | @file:Suppress("UnstableApiUsage") 2 | 3 | enableFeaturePreview("TYPESAFE_PROJECT_ACCESSORS") 4 | 5 | pluginManagement { 6 | repositories { 7 | gradlePluginPortal() 8 | 9 | maven("https://repo.opencollab.dev/maven-snapshots/") 10 | maven("https://maven.fabricmc.net/") 11 | maven("https://maven.architectury.dev/") 12 | maven("https://maven.neoforged.net/releases") 13 | } 14 | includeBuild("build-logic") 15 | } 16 | 17 | rootProject.name = "geyser-parent" 18 | 19 | include(":ap") 20 | include(":api") 21 | include(":bungeecord") 22 | include(":fabric") 23 | include(":neoforge") 24 | include(":mod") 25 | include(":spigot") 26 | include(":standalone") 27 | include(":velocity") 28 | include(":viaproxy") 29 | include(":common") 30 | include(":core") 31 | 32 | // Specify project dirs 33 | project(":bungeecord").projectDir = file("bootstrap/bungeecord") 34 | project(":fabric").projectDir = file("bootstrap/mod/fabric") 35 | project(":neoforge").projectDir = file("bootstrap/mod/neoforge") 36 | project(":mod").projectDir = file("bootstrap/mod") 37 | project(":spigot").projectDir = file("bootstrap/spigot") 38 | project(":standalone").projectDir = file("bootstrap/standalone") 39 | project(":velocity").projectDir = file("bootstrap/velocity") 40 | project(":viaproxy").projectDir = file("bootstrap/viaproxy") 41 | --------------------------------------------------------------------------------