nickilovesyou
📎 1 file 4,424 chars
📄
pasted-code-1774892310569.txt
txt 176 lines
▶
🕵️ Project: Unknown (Updated Design)
Disclaimer: This is an unofficial remake of the Project: Unknown plugin concept. I am not affiliated with the original Project: Unknown server or team. This plugin is a fan-made recreation and I do not claim any credit for the original gameplay concept.


🎮 Core Concept
A social deduction plugin where all players are anonymous. Everyone shares the same name and skin. Players must gather information, track targets, and correctly identify others to eliminate them.


🔹 Features
🎭 Complete Anonymity
All players appear as the same name (e.g. “Player”)
All players use identical skins
No visible identity indicators

🧭 Detective’s Compass
Tracks a random player for 5 minutes
Displays:Distance
Direction
Timer (action bar)
Target player receives a warning message when being tracked

🔔 Bell of Truth (Experimental)
Place and ring the bell
Reveals all players within 8 blocks for 20 seconds
Effects:Real names shown in red
Glowing red outline

❤️ Lives System
Each player starts with 3 lives (configurable)
When correctly caught:Player loses 1 life
At 0 lives → eliminated (banned)

❤️ Action Bar Display
Players always see their remaining lives in the action bar
Display Format:
❤️❤️❤️ = 3 lives
❤️❤️🖤 = 2 lives
❤️🖤🖤 = 1 life
Updates every second or on change
Does not reveal identity

🔄 Revive System (NEW)
🔹 How Revival Works
Eliminated players (0 lives) are not permanently gone immediately
They enter a “downed/eliminated” state upon dying they will be in another world as a phantom state isolated from all other players until revived

🧪 Revive Item: Totem of Revival
Craftable or admin-given item
Can be used on an eliminated player
✅ On Use:
Restores player to 1 life
Removes ban/spectator (phantom state)
Player returns to the game

⚖️ Revive Rules
Revived players:Return with 1 life only
Optional limits:Max revives per player (configurable)
Revive cooldown

💡 Suggested Craft (example)
 
Totem of Undying + Diamond Block + Nether Star
 
(Fully configurable in config.yml)

Revival creates particles/sound (alerts nearby players)

🐉 Dragon Egg
Holding egg:+1 max heart per kill
Right-click:Reveal nearby players (8 blocks)
Unlocks:Permanent locator bar for just that player that holds the dragon egg

⚔️ Catching System
Rename a weapon to a player’s real username
Kill that player with the weapon
Outcomes:
✅ Correct: Target loses 1 life
❌ Incorrect: Weapon is wasted (will just go back to their normal sword and will have to rename the sword again)

🎮 Gameplay Flow
Players join
Everyone is disguised
Players gather information through:Behavior
Movement
Voice chat
Use tools:Compass → track
Bell → reveal
Attempt catches carefully
Players lose lives and get eliminated
Revives allow comeback plays

⚙️ Configuration (config.yml)
 
lives:
enabled: true
starting-lives: 3
ban-on-zero-lives: true
ban-duration: -1 # -1 = permanent

actionbar:
enabled: true
update-interval: 20 # ticks (1 second)
format: "&c%hearts% &7(%lives% Lives)"

revive:
enabled: true
item-name: "&aTotem of Revival"
restore-lives: 1
max-revives-per-player: 1
cooldown: 300 # seconds
revive-time: 3 # seconds to channel
interrupt-on-damage: true

messages:
life-lost: "&cYou lost a life! Lives remaining: %lives%"
eliminated: "&4You have been eliminated!"
revived: "&aYou have been revived!"
wrong-catch: "&cWrong target! Your weapon was wasted."
 

🧠 Implementation Notes (for Developer)
Lives Storage
 
lives::playerUUID → integer
 

Action Bar Logic
Loop all players every second
Convert lives → heart string
Send action bar

Elimination Flow
 
if lives <= 0:
set player state → eliminated
ban OR switch to spectator
 

Revive Flow
 
if player is eliminated:
if revive item used:
restore 1 life
unban / restore player
 

Catch Check
 
if weapon name == target real username:
success
else:
fail
 

🧾 Commands & Permissions
Command
Permission: op
Description
/detectivecompass
-
Get a Detective's Compass
/belloftruth
-
Get a Bell of Truth
/projectunknown reload
projectunknown.reload
Reload config

🧠 Final Result
This version creates:

High tension gameplay (limited lives)
Comeback potential (revives)
Constant awareness (action bar)
Strategic risk (catching system)
(make this whole plugin highly configurable)
Kodari AI
KodariMar 30 at 5:41 pm 21,061 (v2)

I’ll create a comprehensive Project: Unknown social deduction plugin with anonymity, lives system, tracking tools, and revival mechanics.

ProjectUnknown
A social deduction plugin where all players are anonymous with identical names and skins. Players use detective compasses to track targets, bells to reveal identities, and renamed weapons to catch opponents. Features a lives system with elimination, revivals via totems, and special dragon egg abilities. Includes action bar life display, phantom world for eliminated players, and highly configurable gameplay mechanics.

All files created! This comprehensive Project: Unknown plugin features complete anonymity, lives system with action bar display, detective compass tracking, bell revealing, catch mechanics, revive system, dragon egg abilities, and phantom world for eliminated players. Everything is highly configurable through config.yml.

nickilovesyou

the skin and nametag above the players head does not change it only changed on tablist can you fix that and also players can use a bell instead of "the bell of truth" can you make it so players cannot use a bell in replacement of the bell of truth and fix the skin and nametag problem aswell

Kodari AI
KodariMar 30 at 5:56 pm 12,964 (v2)

I’ll read the relevant files to fix both issues.

I’ll fix both issues:

  1. Disguise nametag - Using scoreboard teams properly to change the nametag above the player’s head

  2. Bell validation - Track placed “Bell of Truth” bells and prevent regular bells from working

Both issues are now fixed:

Nametag Display: The disguise now properly uses scoreboard teams with prefixes, so the nametag above the player’s head will show the disguised name (not just in tab list). When revealed by the bell, the team changes to show the colored name.

Bell of Truth Validation: Players can no longer use regular bells. The plugin now tracks which bell blocks are “Bell of Truth” bells (placed from the special item) and only allows those to activate the reveal effect. Regular bells will be cancelled with a message.

Note: Player skins cannot be changed without ProtocolLib or similar packet manipulation libraries. The visual player model will remain the same, but the nametag above their head and tab list will show the disguised name.

nickilovesyou

okay so 3 things it still says the players name all it did was add "player" before their name hope you can just make it say "player" instead of there actual user and I downloaded protocolLIB so then players skins will be hidden so can you hide the players skins aswell? and last thing im using a plugin called "multiworld" so when you die all three times can you make it so players go to that new world "phantom world"

1 image attached
Kodari AI
KodariMar 30 at 6:12 pm 14,992 (v2)

I’ll fix all three issues:

  1. Make it show only “Player” (no username)

  2. Hide skins using ProtocolLib

  3. The phantom world teleport is already implemented! Just make sure your multiworld plugin has a world named “phantom_world” or change the config setting.


Fixed all three issues:

  1. Name now shows only “Player” - Removed team prefix system, using custom names and hiding nametags via team options

  2. Skins hidden with ProtocolLib - All players show as Steve skin using packet modification

  3. Phantom world teleport already works - When players die 3 times, they go to spectator mode and teleport to “phantom_world”

Make sure your multiworld plugin has a world named “phantom_world” or change it in config.yml under lives.phantom-world-name. The plugin will warn you in console if the world doesn’t exist.

nickilovesyou

[13:25:56 WARN]: [ProjectUnknown] Error modifying player info packet: Unable to set value of field private final java.util.EnumSet net.minecraft.network.protocol.game.ClientboundPlayerInfoUpdatePacket.actions

Kodari can make mistakes. Review important code before using.
Files
src
build.gradle
Code
28 1,701
src/main/java/com/projectunknown/ProjectUnknown.java
package com.projectunknown;

import com.projectunknown.commands.BellOfTruthCommand;
import com.projectunknown.commands.DetectiveCompassCommand;
import com.projectunknown.commands.ProjectUnknownCommand;
import com.projectunknown.listeners.*;
import com.projectunknown.managers.*;
import lombok.Getter;
import org.bukkit.Bukkit;
import org.bukkit.World;
import org.bukkit.WorldCreator;
import org.bukkit.plugin.java.JavaPlugin;

@Getter
public class ProjectUnknown extends JavaPlugin {
    private ConfigManager configManager;
    private DataManager dataManager;
    private LivesManager livesManager;
    private DisguiseManager disguiseManager;
    private SkinManager skinManager;
    private CompassManager compassManager;
    private BellManager bellManager;
    private ReviveManager reviveManager;
    private DragonEggManager dragonEggManager;
    private ActionBarManager actionBarManager;
    
    @Override
    public void onEnable() {
        saveDefaultConfig();
        
        this.configManager = new ConfigManager(this);
        this.dataManager = new DataManager(this);
        this.livesManager = new LivesManager(this);
        this.disguiseManager = new DisguiseManager(this);
        this.skinManager = new SkinManager(this);
        this.compassManager = new CompassManager(this);
        this.bellManager = new BellManager(this);
        this.reviveManager = new ReviveManager(this);
        this.dragonEggManager = new DragonEggManager(this);
        this.actionBarManager = new ActionBarManager(this);
        
        ensurePhantomWorld();
        
        registerListeners();
        registerCommands();
        
        this.actionBarManager.startTask();
        this.compassManager.startTask();
        
        getLogger().info("ProjectUnknown has been enabled!");
    }
    
    @Override
    public void onDisable() {
        if (this.actionBarManager != null) {
            this.actionBarManager.stopTask();
        }
        if (this.compassManager != null) {
            this.compassManager.stopTask();
        }
        if (this.dataManager != null) {
            this.dataManager.saveAll();
        }
        
        getLogger().info("ProjectUnknown has been disabled!");
    }
    
    private void ensurePhantomWorld() {
        String worldName = getConfig().getString("lives.phantom-world-name", "phantom_world");
        World world = Bukkit.getWorld(worldName);
        
        if (world == null) {
            getLogger().warning("Phantom world '" + worldName + "' not found!");
            getLogger().warning("Players with 0 lives will be set to spectator mode in their current world.");
            getLogger().warning("Make sure your multiworld plugin has created a world named: " + worldName);
        } else {
            getLogger().info("Phantom world found: " + worldName);
        }
    }
    
    private void registerListeners() {
        Bukkit.getPluginManager().registerEvents(new PlayerJoinListener(this), this);
        Bukkit.getPluginManager().registerEvents(new PlayerQuitListener(this), this);
        Bukkit.getPluginManager().registerEvents(new PlayerDeathListener(this), this);
        Bukkit.getPluginManager().registerEvents(new CompassListener(this), this);
        Bukkit.getPluginManager().registerEvents(new BellListener(this), this);
        Bukkit.getPluginManager().registerEvents(new WeaponCatchListener(this), this);
        Bukkit.getPluginManager().registerEvents(new DragonEggListener(this), this);
        Bukkit.getPluginManager().registerEvents(new ReviveListener(this), this);
    }
    
    private void registerCommands() {
        getCommand("detectivecompass").setExecutor(new DetectiveCompassCommand(this));
        getCommand("belloftruth").setExecutor(new BellOfTruthCommand(this));
        getCommand("projectunknown").setExecutor(new ProjectUnknownCommand(this));
    }
    
    public void reload() {
        reloadConfig();
        this.configManager.reload();
        this.dataManager.reload();
    }
}