make me a plugin like altar smp but only the altars and u can put the resources needed andd the item that u can craft in a gui
I’ll build the configurable altar recipes, a recipe-selection menu, and an altar GUI where players place ingredients and click to craft. I’ll also add the plugin command and sample recipes.
Created the AltarSMP plugin. Players use /altar to choose a recipe, place its ingredients in the altar GUI, and click the result to craft. Any ingredients left in the altar are returned when the GUI closes.
Recipes and result items—including material, amount, display name, and lore—are configurable in config.yml. Each recipe supports up to nine ingredient types.
make it so i can pick what result item and make it so when i do /altar spawn it spawns a stucture block woth a hologram of the result and on top of it the resources
Add
/altar spawnrecipe selection and/altar spawn <recipe>for direct spawning.Build a small clickable altar and display its result and required resources as floating item holograms.
Save altar locations so their holograms and recipe interactions return after a restart.
/altar spawn now opens a menu to choose a configured result, then builds that altar three blocks in front of you. You can also spawn one directly with /altar spawn <recipe-id>.
Each altar shows floating item holograms for its result and required resources. Right-click the center block to open that recipe’s crafting GUI. Spawned altars are saved and restored after restart; spawning requires altarsmp.admin.
make so i can change the result in the admin gui so like i cant fo /altar and when i click on the altar blessing or voidcore i can change it to like nether star or sum else
Make
/altaropen an admin result editor when an admin selects a recipe; keep the normal crafting menu for other players.Let admins place a replacement item, save it into the recipe config, and refresh existing altar holograms.
Return an unsaved replacement item safely if the editor is closed without saving.
Admins can now use /altar, click an altar recipe, place a replacement item in the empty slot, and click Save result. The new item—including its name, lore, and other item metadata—is saved to the recipe and updates existing altar holograms. Closing without saving returns the replacement item.
now make it so i can change the resources needed and do the command /altar resources and make ALL of the command only assecaple by admin or /op players
Restrict
/altarand every subcommand toaltarsmp.admin(OP by default).Add
/altar resourcesrecipe selection and a nine-slot ingredient editor with Save.Persist updated requirements and refresh holograms; return unsaved editor items when closed.
Added /altar resources: select an altar recipe, place the new required items in the nine slots, and click Save resources. Saving updates the recipe config and refreshes its spawned altar holograms; closing without saving returns your items.
All /altar commands now require altarsmp.admin, which is granted to OPs by default.
now make it so i can create new altars and when i craft a altar it deletes itself
Add an admin flow to create new altar recipes.
Remove a placed altar after a successful craft.
Recipe creation:
/altar create <id>opens an admin GUI for the result and required resources; recipes save into config.Craft cleanup: remove the spawned altar after a successful craft.
/altar create <id>now opens an admin GUI to set the result item and required resources, then saves the new recipe.A spawned altar now removes its structure and holograms after a successful craft. Missing ingredients won’t consume it; any extra items in the GUI are returned when it closes.
yes and make the command /altar create
/altar create will open a creation GUI directly—no recipe ID required. Admins can place the result and required resources, then save; the plugin assigns a unique recipe ID automatically.
/altar create now opens the admin creation GUI. Place the result item in the center slot and required resources in the resource slots, then click Create altar. The recipe is saved with a unique ID based on the result item; unsaved items are returned when you close the menu.
now add /altar delete
I’ll add /altar delete as an admin recipe-selection menu; selecting a recipe will remove it from config and clear any spawned altars for it.
Added /altar delete. It opens a recipe menu; selecting one deletes its recipe from config and removes any spawned altars using that recipe. Only admins/OPs can use it.
package com.kodari.altarsmp;
import org.bukkit.Bukkit;
import org.bukkit.command.PluginCommand;
import org.bukkit.plugin.java.JavaPlugin;
public final class AltarSMPPlugin extends JavaPlugin {
private AltarManager altarManager;
@Override
public void onEnable() {
saveDefaultConfig();
altarManager = new AltarManager(this);
Bukkit.getPluginManager().registerEvents(new AltarListener(altarManager), this);
PluginCommand altarCommand = getCommand("altar");
if (altarCommand != null) {
altarCommand.setExecutor(new AltarCommand(this, altarManager));
}
}
public void reloadAltarConfig() {
reloadConfig();
altarManager.loadRecipes();
}
}