Player-Owned Companies
Players can now create and manage their own companies directly in-game.
Added player-owned company creation
Companies now store owner UUID and owner name
Company owners can withdraw money from company treasury
Company ownership can be transferred to another online player
Owners can rename their company
Owners can set company tax percentage
Owners can set company dividend percentage
Owners can attach their own shops to their company
Owners can add/remove materials from their company sector
New Company Commands
/fm company create <id> <name>
/fm company my
/fm company rename <id> <name>
/fm company settax <id> <percent>
/fm company setdividend <id> <percent>
/fm company withdraw <id> <amount>
/fm company transfer <id> <player>
/fm company attachshop <companyId> <shopId>
/fm company additem <id> <MATERIAL>
New Configuration Options
Enable/disable player-owned companies
Company creation cost
Max companies per player
Max shops per company
Max player company tax percent
Max player company dividend percent
Default player company share price
Default total/public shares
Permissions
Added framemarket.company.create
Stock trading now respects framemarket.stock.trade
Help Menu
/fm now shows the new company owner commands to players when player-owned companies are enabled
Tab-complete now includes the new company subcommands
Database
Added company owner fields to MySQL
Existing companies are migrated automatically
This update gives regular players real control over their own shops. Previously, any player with the framemarket.create permission could register a shop but had no way to remove it, no stock limit, and no restocking system. All of that changes now.
What's New
Player shops now require real inventory items When a player creates a shop, every matching item in their inventory is automatically deposited as the shop's stock. If you have 30 Coal, your shop will sell exactly 30 Coal — no more, no less. Once stock runs out, buyers see an "Out of stock" message and purchase buttons are greyed out in the GUI. Admins still create unlimited shops as before.
Players can now restock their own shop New command: /fm restock — look at your shop frame and run the command. All matching items in your inventory are instantly transferred into the shop's stock. No need to delete and recreate the shop.
Players can now remove their own shop /fm remove is no longer admin-exclusive. Shop owners can look at their own frame and remove it at any time. All unsold stock is automatically returned to their inventory. Admins can still remove any shop; if the original owner is online at the time, their leftover stock is returned to them too.
Stock counter visible in the shop GUI The shop item panel now shows remaining stock for player-owned shops. Buy buttons clearly indicate when a quantity exceeds available stock.
Ownership is enforced server-side Each player shop stores the owner's identity in the database. Players cannot remove or restock a shop they don't own — attempting to do so shows a no-permission message.
Automatic database migration Two new columns (owner_uuid and stock) are added to the database automatically on server start. No manual SQL needed. Existing shops created by admins remain infinite as expected.
Why this matters
Before this update, granting players the framemarket.create permission meant they could open shops without ever having the items, and those shops would stay in the database forever with no way to remove them. Now the system is self-contained: players deposit real items to open a shop, restock it when needed, and clean it up themselves when they're done — all without admin intervention.
What's New
Basic shop creation permission
Players with theframemarket.createpermission can now create basic shops using/fm create.
Admin-only advanced settings
Advanced parameters such asmin,max, andimpactare still restricted to admins only.
Clearer command usage
The/fm createusage message was updated to better explain the new permission structure.
Version updated
Plugin version increased from0.3.1to0.3.2.
Why this matters
This update makes shop creation easier for regular players while keeping advanced market controls protected for administrators.
This update focuses only on internal code cleanup and maintenance.
What changed:
- Cleaned and organized parts of the codebase
- Improved readability for future development
- Removed unnecessary or outdated internal code
- Prepared the project for easier future updates
No new features were added in this update, and no gameplay or user-facing behavior was intentionally changed.
This is a maintenance update to keep the plugin cleaner, easier to maintain, and ready for the next improvements.
