Installation
Overview
ML Planting lets players plant seeds, water and fertilize them, and harvest the results. Plant types, categories, growth zones and ground rules are built in an in-game admin panel and saved in the database.
Quick Start
- Download from CFX Portal
- Extract to your
resourcesfolder asml_planting - Add to
server.cfg:
server.cfg
1ensure oxmysql
2ensure ox_lib
3ensure ml_bridge
4ensure ml_plantingLoad Order
ml_planting must start AFTER ml_bridge. Optional resources such as ML Inventory, ml_skills and ml_battlepass start before it.
Database
Tables are created on first start:
ml_planting_plants: planted plants with position, water, fertilizer, health and growthml_planting_types: plant types with stages, harvest, water and fertilizer settingsml_planting_categories: categories and their shared defaultsml_planting_zones: growth zones with multipliers, seed lists and blipsml_planting_bp_runs,ml_planting_bp_outbox,ml_planting_bp_cache,ml_planting_bp_sources,ml_planting_bp_guard: battlepass progress queue, created by the ML Bridge module and only filled whenml_battlepassruns
Item Registration
The example plants use the items in _INSTALL/items.lua. Copy them into your inventory so the starter plants work:
watering_can,fertilizer: care toolsweed_seed,coca_seed: seeds. Using a seed starts the placementweed_branch,coca_leaf: harvest results
Rename, reprice or replace them from the admin panel. With Config.SeedDefaultPlants = false the panel starts with no plant types and you register only your own items.
Verify
The console prints the version banner and:
cfg
1[ml_planting] Ready! Loaded 0 plants in 0 chunks, 1 zonesOpen the admin panel with /plantadmin.
/plantadmindoes nothing: the player needs admin permission from the framework or ACE. Admin groups are set inml_bridge.- Seed does nothing: the seed item must be registered and set on a plant type.
- Cannot place a plant: check
Config.OnlyAllowedGrounds, the surface list of the plant type,PlantDistanceand the player limit. - Plant not visible: check the prop model of each growth stage and
Config.StreamRadius. - Growth stuck: at 0 water a plant stops growing. Water it and growth goes on from the elapsed time.