yogarine/crayta-stubs

此包已被弃用且不再维护。作者建议使用 yogarine/crayta-stub-generator 包。

Crayta 的 Lua stubs

v2.1.1 2021-08-30 16:15 UTC

This package is auto-updated.

Last update: 2021-11-14 16:09:19 UTC


README

Crayta API 文档的 Lua stub 生成器。

Crayta 是一款免费的游戏创作游戏。去看看吧:(https://www.crayta.com)

要求

安装

通过运行 composer require yogarine/crayta-stub-generator 将此包添加到您的项目中,或者使用 composer global require yogarine/crayta-stub-generator 进行全局安装。

使用

从您的项目目录中运行 vendor/bin/create-crayta-stubs,或者如果全局安装,则运行 create-crayta-stubs 来生成 stubs。它们将被放置在当前工作目录的 stubs 子目录中。

开发

使用 Legendary 更新 LuaDocs xml 文件

  1. 安装并配置 Legendary (见 https://github.com/derrod/legendary#how-to-runinstall)

    • 在 macOS 上的安装
      1. brew install python3.9
      2. pip3 install legendary-gl
    • 配置
      1. legendary auth
  2. 运行 legendary list-games 获取正确的 应用名称

    legendary list-games

    应用名称可能是一个 32 位的哈希,如 a0a49d82e3f64c1b81873397a6e92f09

  3. 使用给定的应用名称安装应用

    legendary install a0a49d82e3f64c1b81873397a6e92f09
  4. 复制 LuaDocs。

    cp -af ~/legendary/Crayta/Crayta/Content/LuaDocs/* LuaDocs/

免责声明

本项目与 Crayta、其开发者 Unit 2 Games 没有任何官方关联。Crayta 是注册商标,Crayta stubs 以及其包含的文档受 Unit 2 Games 版权保护。根据 Unit 2 Games 的服务条款,stubs 可以仅用于 Crayta 的推广。