Skip to content
This repository was archived by the owner on Nov 27, 2023. It is now read-only.

publicItemAdd()

蕉饼 edited this page Dec 11, 2022 · 1 revision

介绍

publicItemAdd()向屏幕添加元素,目前共有贴图与按钮两种类型的元素

如何使用

publicItemAdd(name, position, meshID, type)

参数 定义 格式
name 元素名 字符串
position 位置 列表[x,y]
meshID 贴图文件路径 字符串('mesh/xx.vb')
type 类型 字符串('img'或'btn')

案例

在地图放入一个名称为Box3GUI.vb的模型

在代码区写入world.gui.publicItemAdd('test',[10,10],'mesh/Box3GUI.vb','img')

效果如下

效果

注意事项

  • 玩家与世界都有执行权限

  • 模型大小必须为1*y*z

Clone this wiki locally