npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

koishi-plugin-simple-farm

v1.0.0

Published

一个功能丰富的农场经营游戏插件

Readme

koishi-plugin-farm-game

一个功能丰富的农场经营游戏插件,适用于 Koishi 框架。

🌾 功能特色

核心玩法

  • 土地系统: 开拓土地,最多可拥有10块土地
  • 作物种植: 7种不同稀有度的作物,从普通到传说级别
  • 等级系统: 通过种植和收获获得经验值,解锁新的作物
  • 经济系统: 金币交易,出售作物和佳肴获得收益

作物系统

  • 普通作物: 小麦、胡萝卜、番茄
  • 稀有作物: 蓝莓、火龙果
  • 传说作物: 金苹果、凤凰草

佳肴制作

  • 新鲜面包: 生长时间减少20%
  • 胡萝卜蛋糕: 售价提升30%
  • 豪华水果沙拉: 全属性提升25%
  • 黄金盛宴: 全属性提升50%

随机事件

  • 干旱事件: 作物可能遭遇干旱,需要浇水才能恢复生长
  • 宝箱系统: 开拓土地时可能发现宝箱,获得金币、经验、稀有作物或增益效果

增益系统

  • 生长加速: 缩短作物生长时间
  • 售价提升: 增加作物出售价格
  • 全属性提升: 同时提升生长和售价

📦 安装

npm install koishi-plugin-farm-game

🚀 使用方法

在 Koishi 配置文件中添加插件:

module.exports = {
  plugins: {
    'farm-game': {
      // 配置选项
      landBaseCost: 100,           // 开拓土地基础花费
      landExpandMultiplier: 1.5,    // 土地扩展价格倍率
      droughtProbability: 0.1,      // 干旱事件概率
      treasureProbability: 0.15,    // 挖到宝箱概率
      cropGrowthTime: 60,          // 作物基础生长时间(分钟)
      maxLand: 10,                  // 最大土地数量
    }
  }
}

🎮 游戏命令

基础命令

  • 进入游戏 - 开始游戏,查看基本信息
  • 查看状态 - 查看农场状态、等级、金币等
  • 查看商店 - 查看可购买的作物和佳肴食谱
  • 查看帮助 - 显示游戏帮助信息
  • 查看排行榜 - 查看玩家排行榜

土地管理

  • 开拓土地 - 开拓新的土地(需要金币)
  • 种植作物 <土地编号> <作物名> - 在指定土地上种植作物
  • 浇水 <土地编号> - 给干旱的土地浇水
  • 收获作物 [土地编号] - 收获作物(不指定则收获所有可收获的)

背包系统

  • 查看背包 - 查看背包中的作物、佳肴和增益效果
  • 制作佳肴 <佳肴名> - 使用作物制作佳肴
  • 食用佳肴 <佳肴名> - 食用佳肴获得增益效果
  • 出售物品 <物品名> [数量] - 出售背包中的物品

🏆 游戏机制

等级系统

  • 每升一级需要 等级 × 100 经验值
  • 升级奖励:等级 × 50 金币
  • 等级越高,可解锁更稀有的作物

作物生长

  • 基础生长时间:60分钟(可配置)
  • 不同作物有不同的生长时间倍数
  • 增益效果可以缩短生长时间

收益计算

  • 普通作物:基础价格
  • 稀有作物:1.5倍价格和经验
  • 传说作物:3倍价格和经验
  • 增益效果可进一步提升收益

每日奖励

  • 每日首次登录获得50金币奖励

⚙️ 配置选项

| 选项 | 类型 | 默认值 | 说明 | |------|------|--------|------| | landBaseCost | number | 100 | 开拓土地基础花费 | | landExpandMultiplier | number | 1.5 | 土地扩展价格倍率 | | droughtProbability | number | 0.1 | 干旱事件概率 (0-1) | | treasureProbability | number | 0.15 | 挖到宝箱概率 (0-1) | | cropGrowthTime | number | 60 | 作物基础生长时间(分钟) | | maxLand | number | 10 | 最大土地数量 |

🗃️ 数据存储

插件使用 Koishi 数据库存储用户数据,包括:

  • 用户基本信息(等级、经验、金币)
  • 土地状态
  • 背包物品
  • 增益效果
  • 游戏统计(收获次数、发现宝箱数)

🔧 依赖

  • koishi: ^4.0.0
  • koishi-plugin-puppeteer (可选,用于图片渲染功能)

📄 许可证

MIT License

🤝 贡献

欢迎提交 Issue 和 Pull Request!

📞 支持

如有问题或建议,请通过以下方式联系:


享受你的农场经营之旅! 🌱🌻🌾