查看“︁Lua接口/服务端/SetHumanMenpaiPoint”︁的源代码
来自天龙知识库
←
Lua接口/服务端/SetHumanMenpaiPoint
跳到导航
跳到搜索
因为以下原因,您没有权限编辑该页面:
您请求的操作仅限属于该用户组的用户执行:
用户
您可以查看和复制此页面的源代码。
__NOTOC__ <div class="lua-reference" style="max-width:1200px;margin:0 auto;line-height:1.8;color:#29343a;font-family:Arial,'Microsoft YaHei',sans-serif;letter-spacing:0;overflow-wrap:anywhere;"> [[首页|首页]] · [[Lua接口/服务端函数索引|服务端接口]] · [[Lua接口/服务端函数索引/角色属性与物品|角色属性与物品]] · [[Lua接口/服务端调用约定|调用约定]] <div style="padding:14px 0;border-top:3px solid #287568;border-bottom:1px solid #dbe3e6;">设置玩家门派贡献点并标记存档字段为脏。</div> == Lua 调用 == <pre style="white-space:pre-wrap;overflow-wrap:anywhere;font-size:13px;line-height:1.7;padding:12px;background:#f5f7f8;border:1px solid #dbe3e6;">SetHumanMenpaiPoint(sceneId, selfId, menpaiPoint)</pre> 服务端脚本中共出现 45 处调用,实参个数出现过:3 个(45 处)。 实现位于 <code style="white-space:normal;overflow-wrap:anywhere;">LuaFnTbl_Attr.h</code> 第 5511 行,注册表第 1041 行。 == 参数 == {| class="wikitable" style="width:100%;table-layout:fixed;border-collapse:collapse;font-size:13px;" ! scope="col" style="text-align:left;background:#edf3f2;padding:8px;width:11%;" | 序号 ! scope="col" style="text-align:left;background:#edf3f2;padding:8px;width:36%;" | 参数 / 类型 ! scope="col" style="text-align:left;background:#edf3f2;padding:8px;" | 说明 |- | style="padding:8px;vertical-align:top;overflow-wrap:anywhere;" | 1 | style="padding:8px;vertical-align:top;overflow-wrap:anywhere;" | <code style="white-space:normal;overflow-wrap:anywhere;">sceneId</code><br /><span style="color:#657078;"><code style="white-space:normal;overflow-wrap:anywhere;">number</code></span> | style="padding:8px;vertical-align:top;overflow-wrap:anywhere;" | 当前调用所在的场景 ID。<br /><span style="color:#657078;">脚本中的实参:<code style="white-space:normal;overflow-wrap:anywhere;">sceneId</code>(45 处)</span> |- | style="padding:8px;vertical-align:top;overflow-wrap:anywhere;" | 2 | style="padding:8px;vertical-align:top;overflow-wrap:anywhere;" | <code style="white-space:normal;overflow-wrap:anywhere;">selfId</code><br /><span style="color:#657078;"><code style="white-space:normal;overflow-wrap:anywhere;">number</code></span> | style="padding:8px;vertical-align:top;overflow-wrap:anywhere;" | 当前场景内的对象 ID。玩家接口需传入有效玩家对象;不是角色 GUID。<br /><span style="color:#657078;">脚本中的实参:<code style="white-space:normal;overflow-wrap:anywhere;">humanObjId</code>(36 处)、<code style="white-space:normal;overflow-wrap:anywhere;">selfId</code>(7 处)、<code style="white-space:normal;overflow-wrap:anywhere;">killerId</code></span> |- | style="padding:8px;vertical-align:top;overflow-wrap:anywhere;" | 3 | style="padding:8px;vertical-align:top;overflow-wrap:anywhere;" | <code style="white-space:normal;overflow-wrap:anywhere;">menpaiPoint</code><br /><span style="color:#657078;"><code style="white-space:normal;overflow-wrap:anywhere;">number</code></span> | style="padding:8px;vertical-align:top;overflow-wrap:anywhere;" | 门派点数。<br /><span style="color:#657078;">脚本中的实参:<code style="white-space:normal;overflow-wrap:anywhere;">mppoint</code>(36 处)、<code style="white-space:normal;overflow-wrap:anywhere;">menpaipoint-needpoint</code>(2 处)、<code style="white-space:normal;overflow-wrap:anywhere;">GetHumanMenpaiPoint(sceneId, selfId) + menpaiPoi</code></span> |} == 返回值 == 根据执行分支,返回数量可能为 0、1 个(0 个表示无返回值)。返回类型包括 <code style="white-space:normal;overflow-wrap:anywhere;">number</code>。明确的固定返回组合包括 <code style="white-space:normal;overflow-wrap:anywhere;">-1</code>。 == 脚本中的调用 == 以下是服务端脚本里的真实调用点,按实参形态去重后列出 8 条。这些调用取自随包发布的脚本,可用于确认参数顺序与实际传入的值;它们不代表该写法在当前版本仍然有效。 <pre style="white-space:pre-wrap;overflow-wrap:anywhere;font-size:13px;line-height:1.7;padding:12px;background:#f5f7f8;border:1px solid #dbe3e6;">-- event/dali/edali_0287.lua SetHumanMenpaiPoint(sceneId, nPlayerId, nMenpaiPoint+20) -- event/huashan/ehuashan_1.lua SetHumanMenpaiPoint(sceneId, killerId, nMenpaiPoint+1) -- event/huodong/eTouximenpai_NPC_emei.lua SetHumanMenpaiPoint(sceneId, humanObjId, mppoint) -- event/shimen/event_exchangeitembymenpaipoint.lua SetHumanMenpaiPoint(sceneId, selfId, menpaipoint-400) -- event/shimen/event_exchangeitembymenpaipoint.lua SetHumanMenpaiPoint(sceneId, selfId, menpaipoint-needpoint) -- event/shimen/event_shimen_helpfinish.lua SetHumanMenpaiPoint(sceneId, selfId, menpaiPoint-needPoint) -- event/xunhuan/Mission_Necessary.lua SetHumanMenpaiPoint(sceneId, selfId, GetHumanMenpaiPoint(sceneId, selfId) + menpaiPoi) -- event/xunhuan/Mission_Necessary.lua SetHumanMenpaiPoint(sceneId, selfId, menpaiPoint-1)</pre> == 注意事项 == * 调用对象必须是当前场景中的有效玩家。 </div>
返回
Lua接口/服务端/SetHumanMenpaiPoint
。
导航菜单
页面操作
页面
讨论
阅读
查看源代码
历史
页面操作
页面
讨论
更多
工具
个人工具
创建账号
登录
导航
首页
最近更改
随机页面
MediaWiki帮助
特殊页面
搜索
工具
链入页面
相关更改
页面信息