nunomeas

Tạo cho tôi 1 plugin tên CelestialSMP có các chức năng về

  • Chúng ta sẽ có các cung hoàng đạo tương ứng với các chòm sao, trong ngoặc là chòm sao:

    Bạch Dương (Aries), Kim Ngưu (Taurus), Song Tử (Gemini), Cự Giải (Cancer), Sư Tử (Leo), Xử Nữ (Virgo), Thiên Bình (Libra), Bọ Cạp (Scorpio), Nhân Mã (Sagittarius), Ma Kết (Capricorn), Bảo Bình (Aquarius), Song Ngư (Pisces)

  • Các cung hoàng đạo sẽ chia ra thành 3 cấp bậc yếu:3 cung hoàng đạo, trung bình:7 cung hoàng đạo và mạnh: 2 cung hoàng đạo
  • Khi người chơi lần đầu vào server sẽ tự động mở 1 INVENTORY GUI sau khi /login hay /register xong hoặc sử dụng lệnh /zodiacsign(nếu bạn có cung hoàng đạo rồi thì sẽ không sử dụng được nữa) nó sẽ mở ra cho bạn để bạn chọn 1 cung hoàng đạo nhưng trong đó chỉ có 3 cung hoàng đạo yếu nhất
  • Thiết kế riêng cho các cung hoàng đạo là custom skill khi dùng skill bạn sẽ ấn nút shift
  • Chúng ta sẽ có các chu kì của chòm sao, 3 ngày sẽ là chu kì của 1 chòm sao, khi đến chòm sao nào tương ứng với cung hoàng đạo thì skill của cung hoàng đạo đó sẽ được buff 50% sức mạnh và nếu không ở trong chu kì thì chỉ buff 10% sức mạnh thôi
  • Khi đến chu kì của chòm sao nào server sẽ tự thông báo cho toàn bộ người chơi "3 ngày này là chu kì của chòm sao nào và tương ứng với cung hoàng đạo nào"
  • Sẽ có lệnh /list để xem toàn bộ thông tin của cung hoàng đạo, sức mạnh và sức mạnh khi đến chu kì
  • lệnh /stock để xem các cung hoàng đạo đang bán sẽ có 12 cung hoàng đạo ở đó nhưng chỉ có 2 cung hoàng đạo được bán và cung hoàng đạo càng mạnh thì tỉ lệ stock càng thấp và 30p restock 1 lần (có thể chỉnh trong config.yml) và giá của cung hoàng đạo càng mạnh thì số tiền càng đắt thấp nhất là 5m cao nhất là 30m
  • lệnh cho admin /setzodiacsign <player> <cung hoàng đạo> để set cung hoàng đạo nếu cung hoàng đạo là None thì sẽ là xoá cung hoàng đạo họ đang sở hữu
  • hãy dùng bảng này để set tên lore lời nói cho toàn bộ plugin: "ᴀʙᴄᴅᴇꜰɢʜɪᴊᴋʟᴍɴᴏᴘQʀꜱᴛᴜᴠᴡxʏᴢ", Hãy thiết kế các INVENTORY GUI sao cho gọn gàng và thật đẹp sao cho server chuyên nghiệp

Full Tiếng anh

Kodari AI
KodariJun 16 at 7:39 am 51

I’ll create a comprehensive zodiac system plugin for a professional SMP server with cosmic cycles, custom skills, and an economy-based progression system.

CelestialSMP
A zodiac-based progression system featuring 12 celestial signs with unique skills. Players select their zodiac sign and gain custom abilities activated by sneaking. The plugin includes a 3-day cosmic cycle system that buffs the active zodiac's power by 50%. Features an economic shop with dynamic restocking, professional GUI interfaces, admin management commands, and persistent data storage. Supports Vault economy integration.

Perfect! I’ve created a complete zodiac system plugin with professional design and all requested features. Here’s what was implemented:

✦ ᴄᴏʀᴇ ꜰᴇᴀᴛᴜʀᴇꜱ ✦

12 Zodiac Signs organized in 3 tiers:

  • Weak: Gemini, Cancer, Virgo (3 signs)

  • Medium: Aries, Taurus, Leo, Libra, Scorpio, Sagittarius, Pisces (7 signs)

  • Strong: Capricorn, Aquarius (2 signs)

Unique Skills for each zodiac activated by sneaking:

  • Aries: Ram’s Fury (fire dash)

  • Taurus: Earthen Fortress (defense)

  • Gemini: Twin Velocity (speed/jump)

  • Cancer: Tidal Shell (water shield)

  • Leo: Lion’s Roar (strength + AOE debuff)

  • Virgo: Purifying Light (regen + cleanse)

  • Libra: Perfect Balance (all stat buffs)

  • Scorpio: Venomous Strike (poison AOE)

  • Sagittarius: Arrow Storm (projectile buffs)

  • Capricorn: Mountain Endurance (massive power)

  • Aquarius: Aquatic Dominion (water control)

  • Pisces: Oceanic Blessing (water breathing)

3-Day Cycle System:

  • Each zodiac gets a 3-day cycle period

  • Active cycle: +50% skill power

  • Inactive: +10% skill power

  • Server broadcasts cycle changes

Shop System:

  • Dynamic restocking every 30 minutes (configurable)

  • Only 2 zodiacs available at a time

  • Prices: 5M (weak), 15M (medium), 30M (strong)

  • Stock weighted by tier

Commands:

  • /zodiacsign - Select your zodiac (first-time only)

  • /zodiaclist - View all zodiacs with info

  • /zodiacstock - Open shop

  • /setzodiacsign <player> <zodiac|None> - Admin command

Professional GUIs with small caps font styling throughout!

nunomeas

thêm placeholder api để hiện trên scoreboard: %zodiac_sign%

Kodari AI
KodariJun 16 at 7:53 am 29

I’ll add PlaceholderAPI support to display zodiac signs on scoreboards.

Perfect! PlaceholderAPI is already added. Now let me update the pom.xml to add the PlaceholderAPI dependency:

Perfect! ✦ PlaceholderAPI integration complete!

Added Features:

  • PlaceholderAPI dependency in pom.xml

  • Created CelestialPlaceholder expansion class

  • Registered placeholder hook in main plugin class

  • Added softdepend: [Vault, PlaceholderAPI] in plugin.yml

Placeholder Usage:

  • %celestialsmp_zodiac_sign% - Displays player’s zodiac sign name (e.g., “ᴀʀɪᴇꜱ”, “ɴᴏɴᴇ”)

Use this placeholder in any scoreboard plugin (like FeatherBoard, AnimatedScoreboard, etc.) to display zodiac signs!

nunomeas

fix chu kì 3 ngày không hoạt động và chỉ cần ghi /day 3 lần là kích hoạt chu kì mới

nunomeas

fix chu kì 3 ngày không hoạt động và chỉ cần ghi /day 3 lần là kích hoạt chu kì mới

nunomeas

fix placeholder api không hoạt động chỉ cần có này trên plugin TAB là hiện được luôn %zodiac_sign%

nunomeas

fix placeholder api không hoạt động chỉ cần có này trên plugin TAB là hiện được luôn %zodiac_sign% fix chu kì 3 ngày không hoạt động và chỉ cần ghi /day hoặc /night 3 lần là kích hoạt chu kì mới

Kodari can make mistakes. Review important code before using.
Files
src
pom.xml
Code
23 1,981
src/main/java/com/celestialsmp/CelestialSMP.java
package com.celestialsmp;

import com.celestialsmp.commands.*;
import com.celestialsmp.hooks.CelestialPlaceholder;
import com.celestialsmp.listeners.*;
import com.celestialsmp.managers.*;
import net.milkbowl.vault.economy.Economy;
import org.bukkit.Bukkit;
import org.bukkit.plugin.RegisteredServiceProvider;
import org.bukkit.plugin.java.JavaPlugin;

public class CelestialSMP extends JavaPlugin {

    private static CelestialSMP instance;
    private Economy economy;
    
    private ConfigManager configManager;
    private DataManager dataManager;
    private ZodiacCycleManager cycleManager;
    private SkillManager skillManager;
    private GUIManager guiManager;
    private ShopManager shopManager;

    @Override
    public void onEnable() {
        instance = this;
        
        // Initialize configuration
        saveDefaultConfig();
        configManager = new ConfigManager(this);
        
        // Setup Vault economy
        if (getConfig().getBoolean("economy.enabled")) {
            if (!setupEconomy()) {
                getLogger().warning("Vault not found! Economy features disabled.");
            } else {
                getLogger().info("Vault economy hooked successfully!");
            }
        }
        
        // Setup PlaceholderAPI
        if (Bukkit.getPluginManager().getPlugin("PlaceholderAPI") != null) {
            new CelestialPlaceholder(this).register();
            getLogger().info("PlaceholderAPI hooked successfully!");
        }
        
        // Initialize managers
        dataManager = new DataManager(this);
        cycleManager = new ZodiacCycleManager(this);
        skillManager = new SkillManager(this);
        guiManager = new GUIManager(this);
        shopManager = new ShopManager(this);
        
        // Register commands
        registerCommands();
        
        // Register listeners
        registerListeners();
        
        // Start tasks
        cycleManager.startCycleTask();
        shopManager.startRestockTask();
        
        getLogger().info("CelestialSMP has been enabled!");
    }

    @Override
    public void onDisable() {
        // Save all data
        if (dataManager != null) {
            dataManager.saveAllData();
        }
        
        getLogger().info("CelestialSMP has been disabled!");
    }
    
    private void registerCommands() {
        getCommand("zodiacsign").setExecutor(new ZodiacSignCommand(this));
        getCommand("zodiaclist").setExecutor(new ListCommand(this));
        getCommand("zodiacstock").setExecutor(new StockCommand(this));
        getCommand("setzodiacsign").setExecutor(new SetZodiacSignCommand(this));
    }
    
    private void registerListeners() {
        Bukkit.getPluginManager().registerEvents(new PlayerJoinListener(this), this);
        Bukkit.getPluginManager().registerEvents(new InventoryClickListener(this), this);
        Bukkit.getPluginManager().registerEvents(new PlayerToggleSneakListener(this), this);
    }
    
    private boolean setupEconomy() {
        if (getServer().getPluginManager().getPlugin("Vault") == null) {
            return false;
        }
        RegisteredServiceProvider<Economy> rsp = getServer().getServicesManager().getRegistration(Economy.class);
        if (rsp == null) {
            return false;
        }
        economy = rsp.getProvider();
        return economy != null;
    }

    public static CelestialSMP getInstance() {
        return instance;
    }

    public Economy getEconomy() {
        return economy;
    }

    public ConfigManager getConfigManager() {
        return configManager;
    }

    public DataManager getDataManager() {
        return dataManager;
    }

    public ZodiacCycleManager getCycleManager() {
        return cycleManager;
    }

    public SkillManager getSkillManager() {
        return skillManager;
    }

    public GUIManager getGuiManager() {
        return guiManager;
    }

    public ShopManager getShopManager() {
        return shopManager;
    }
}