Lua接口/客户端/Sound/PlaySound
来自天龙知识库
跳到导航跳到搜索
Sound:PlaySound
读取客户端本地数据 · 实现于 Game/Sound/GMSoundSystem.cpp
调用方式
Sound:PlaySound(number, boolean)
对象名 Sound 是全局对象,可直接使用。
界面脚本中共 5 处调用,实参个数出现过:2 个(5 处)。
参数
| 序号 | 类型 | 说明 |
|---|---|---|
| 1 | number
|
调用点实参:Get_XParam_INT(0)(2 处)、113(1 处)、SoundInfo[6](1 处)
|
| 2 | boolean
|
调用点实参:false(4 处)、true(1 处)
|
返回值
返回 1 个值。
实现体注释
以下注释取自实现体原文,仅收录可确认属原作者的部分:
- 生成Source
- 设置资源
脚本中的调用
以下是界面脚本里的真实调用点(同一形态只列一次):
-- Quest/Quest.lua Sound:PlaySound(Get_XParam_INT(0), false) -- SelectServer/SelectServer.lua Sound:PlaySound(113, true) -- XingYun/XingYun.lua Sound:PlaySound(SoundInfo[pt], false) -- XingYun/XingYun.lua Sound:PlaySound(SoundInfo[6], false)
关联
- 读取或修改客户端本地数据