Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
44 commits
Select commit Hold shift + click to select a range
0a3528a
Version 1.3.1
tastybento Dec 19, 2024
a1e9784
Update config.yml to latest game modes.
tastybento Apr 12, 2025
f35d0aa
Initial plan
Copilot Mar 17, 2026
cf926d2
Fix NPE in teamChat when getIsland returns null
Copilot Mar 17, 2026
d7ecda3
Merge pull request #47 from BentoBoxWorld/copilot/fix-console-error-t…
tastybento Mar 17, 2026
40a0c14
Initial plan
Copilot Mar 17, 2026
1d45ff3
Add JUnit 5 test classes and update pom.xml for Paper 1.21.11
Copilot Mar 17, 2026
fd25121
Fix --add-opens flag format consistency in pom.xml
Copilot Mar 17, 2026
fdd016c
Merge pull request #49 from BentoBoxWorld/copilot/add-junit5-test-cla…
tastybento Mar 17, 2026
adbdbaf
Initial plan
Copilot Mar 17, 2026
d33662c
Add GitHub Actions workflow to build and test on push/PR to develop
Copilot Mar 17, 2026
94f899b
Merge pull request #50 from BentoBoxWorld/copilot/add-github-actions-…
tastybento Mar 17, 2026
86ac41c
Fix build: update Maven repos, downgrade BentoBox version, and fix fa…
tastybento Mar 17, 2026
aab11c6
Initial plan
Copilot Mar 17, 2026
60b812b
Initial plan
Copilot Mar 17, 2026
1cf1bf0
Add team mute command (/is muteteamchat) to allow players to mute tea…
Copilot Mar 17, 2026
d5635b2
Add extra-chat-worlds config to enable team chat in non-game worlds
Copilot Mar 17, 2026
844a5ce
Add clarifying comment about multi-game-mode extra world behavior
Copilot Mar 17, 2026
da1c598
Merge pull request #51 from BentoBoxWorld/copilot/add-team-mute-commands
tastybento Mar 17, 2026
0b34a76
Merge pull request #52 from BentoBoxWorld/copilot/fix-chat-functional…
tastybento Mar 17, 2026
b3fad68
Initial plan
Copilot Mar 17, 2026
0ff561b
Add missing language translations for all supported locales
Copilot Mar 17, 2026
a92d5b1
Merge pull request #54 from BentoBoxWorld/copilot/update-language-tra…
tastybento Mar 17, 2026
493cb58
Update to BentoBox 3.14.0-SNAPSHOT, compiler 3.15.0, JaCoCo 0.8.12
tastybento Apr 13, 2026
a7b3052
Update CLAUDE.md to reflect current project state
tastybento Apr 13, 2026
0bd8740
Run tests under Java 21 to restore JaCoCo coverage
tastybento Apr 13, 2026
e79b734
Revert JaCoCo workarounds; document Java 25 limitation
tastybento Apr 13, 2026
b4627f9
Upgrade JaCoCo to 0.8.14 for Java 25 support
tastybento Apr 13, 2026
460141d
Update Maven plugin versions to latest
tastybento Apr 13, 2026
2858c53
Convert all locale files from Bukkit color codes to MiniMessage format
tastybento Apr 13, 2026
96b460f
Merge branch 'master' into develop
tastybento Apr 13, 2026
23ba344
Bump version to 1.4.0
tastybento Apr 13, 2026
bdb7c7f
Enable snapshots on bentoboxworld repo to resolve BentoBox 3.x SNAPSHOTs
tastybento Apr 13, 2026
1e478fb
Potential fix for pull request finding
tastybento Apr 13, 2026
5017c71
Potential fix for pull request finding
tastybento Apr 13, 2026
0a65e79
Potential fix for pull request finding
tastybento Apr 13, 2026
cf8d83a
Initial plan
Copilot Apr 13, 2026
45b9d4e
Fix island chat to use isLogIslandChats() and [Island Chat Log] prefix
Copilot Apr 13, 2026
fd15f97
Fix syntax formatting for team chat spy in cs.yml
tastybento Apr 13, 2026
c13a21e
Remove mockito-inline dependency — merged into mockito-core in Mockit…
tastybento Apr 13, 2026
adc41b2
Merge pull request #57 from BentoBoxWorld/copilot/sub-pr-55
tastybento Apr 13, 2026
d43ec29
Improve mute UX: sender echo, mute reminder, and clear mute on chat t…
tastybento Apr 13, 2026
857ea7c
Fix ExecutionException handling and extend CI to master branch
tastybento Apr 13, 2026
d410cb0
Fix case-insensitive world name matching in getWorldsFromExtra
tastybento Apr 13, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
34 changes: 34 additions & 0 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
name: Build and Test

on:
push:
branches:
- develop
- master
pull_request:
branches:
- develop
- master

jobs:
build-and-test:
runs-on: ubuntu-latest
permissions:
contents: read

steps:
- name: Checkout repository
uses: actions/checkout@v4

- name: Set up Java 21
uses: actions/setup-java@v4
with:
java-version: '21'
distribution: 'temurin'
cache: 'maven'

- name: Build with Maven
run: mvn -B clean compile

- name: Run tests
run: mvn -B test
128 changes: 128 additions & 0 deletions CLAUDE.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,128 @@
# CLAUDE.md

This file provides guidance to Claude Code (claude.ai/code) when working with code in this repository.

## Project Overview

Chat is a BentoBox addon for Minecraft (Paper) that provides Team Chat and Island Chat for island-type game modes (BSkyBlock, AcidIsland, CaveBlock, SkyGrid). It requires Java 21 and targets Paper 1.21.11.

## Build Commands

```bash
mvn clean package # Build (default goal)
mvn test # Run all tests
mvn -Dtest=ChatListenerTest test # Run a single test class
mvn -Dtest=ChatListenerTest#onChat test # Run a single test method
```

The build produces `target/Chat-{version}-SNAPSHOT-LOCAL.jar`.

## Architecture

This is a **BentoBox Pladdon** (plugin-addon):

- `ChatPladdon` — Entry point loaded by BentoBox's Pladdon system, creates the `Chat` addon instance
- `Chat` — Main addon class. On enable: loads `Settings` from config.yml, registers commands per game mode, creates `ChatListener`, and registers the `IsTeamChatHandler` request handler
- `ChatListener` — Core logic. Implements both `Listener` and `EventExecutor`. Intercepts `AsyncPlayerChatEvent` (registered manually with configurable priority from Settings). Maintains in-memory sets for team chat users, island chatters, team spies, and island spies. All toggle state is held in memory (not persisted)
- `Settings` — BentoBox `ConfigObject` stored at `addons/Chat/config.yml`. Controls which game modes have team/island chat, logging, event priority, and default chat game mode
- `IsTeamChatHandler` — BentoBox request handler that lets other addons query if a player has team chat enabled

Commands follow BentoBox's `CompositeCommand` pattern and are registered dynamically onto each game mode's player/admin command trees:
- Player: `IslandChatCommand` (chat), `IslandTeamChatCommand` (teamchat), `IslandTeamMuteCommand` (muteteamchat)
- Admin: `AdminIslandChatSpyCommand` (chatspy), `AdminTeamChatSpyCommand` (teamchatspy)

## Testing

Tests use JUnit 5 + Mockito + MockBukkit. The `CommonTestSetup` base class provides standard mocks for BentoBox, Bukkit, Player, World, Island, etc. New test classes should extend `CommonTestSetup` and call `super.setUp()`/`super.tearDown()`. The `WhiteBox` utility sets private/static fields via reflection for test setup.

Localization strings are defined in `src/main/resources/locales/` (en-US.yml is the primary locale).


## Dependency Source Lookup

When you need to inspect source code for a dependency (e.g., BentoBox, addons):

1. **Check local Maven repo first**: `~/.m2/repository/` — sources jars are named `*-sources.jar`
2. **Check the workspace**: Look for sibling directories or Git submodules that may contain the dependency as a local project (e.g., `../bentoBox`, `../addon-*`)
3. **Check Maven local cache for already-extracted sources** before downloading anything
4. Only download a jar or fetch from the internet if the above steps yield nothing useful

Prefer reading `.java` source files directly from a local Git clone over decompiling or extracting a jar.

In general, the latest version of BentoBox should be targeted.

## Project Layout

Related projects are checked out as siblings under `~/git/`:

**Core:**
- `bentobox/` — core BentoBox framework

**Game modes:**
- `addon-acidisland/` — AcidIsland game mode
- `addon-bskyblock/` — BSkyBlock game mode
- `Boxed/` — Boxed game mode (expandable box area)
- `CaveBlock/` — CaveBlock game mode
- `OneBlock/` — AOneBlock game mode
- `SkyGrid/` — SkyGrid game mode
- `RaftMode/` — Raft survival game mode
- `StrangerRealms/` — StrangerRealms game mode
- `Brix/` — plot game mode
- `parkour/` — Parkour game mode
- `poseidon/` — Poseidon game mode
- `gg/` — gg game mode

**Addons:**
- `addon-level/` — island level calculation
- `addon-challenges/` — challenges system
- `addon-welcomewarpsigns/` — warp signs
- `addon-limits/` — block/entity limits
- `addon-invSwitcher/` / `invSwitcher/` — inventory switcher
- `addon-biomes/` / `Biomes/` — biomes management
- `Bank/` — island bank
- `Border/` — world border for islands
- `Chat/` — island chat
- `CheckMeOut/` — island submission/voting
- `ControlPanel/` — game mode control panel
- `Converter/` — ASkyBlock to BSkyBlock converter
- `DimensionalTrees/` — dimension-specific trees
- `discordwebhook/` — Discord integration
- `Downloads/` — BentoBox downloads site
- `DragonFights/` — per-island ender dragon fights
- `ExtraMobs/` — additional mob spawning rules
- `FarmersDance/` — twerking crop growth
- `GravityFlux/` — gravity addon
- `Greenhouses-addon/` — greenhouse biomes
- `IslandFly/` — island flight permission
- `IslandRankup/` — island rankup system
- `Likes/` — island likes/dislikes
- `Limits/` — block/entity limits
- `lost-sheep/` — lost sheep adventure
- `MagicCobblestoneGenerator/` — custom cobblestone generator
- `PortalStart/` — portal-based island start
- `pp/` — pp addon
- `Regionerator/` — region management
- `Residence/` — residence addon
- `TopBlock/` — top ten for OneBlock
- `TwerkingForTrees/` — twerking tree growth
- `Upgrades/` — island upgrades (Vault)
- `Visit/` — island visiting
- `weblink/` — web link addon
- `CrowdBound/` — CrowdBound addon

**Data packs:**
- `BoxedDataPack/` — advancement datapack for Boxed

**Documentation & tools:**
- `docs/` — main documentation site
- `docs-chinese/` — Chinese documentation
- `docs-french/` — French documentation
- `BentoBoxWorld.github.io/` — GitHub Pages site
- `website/` — website
- `translation-tool/` — translation tool

Check these for source before any network fetch.

## Key Dependencies (source locations)

- `world.bentobox:bentobox` `3.14.0-SNAPSHOT` → `~/git/bentobox/src/`
Loading
Loading