WOW API

部分API

魔兽世界全局函数

魔兽世界 API 列表,随着游戏版本的变化而随时更新.不会100%完整,我们会第一时间补充新的API.

这是一张完整的全局函数列表.假如有任何的遗漏,是因为仍没有人添加这个条目,欢迎您参与添加或修改其中的条目。在您添加函数以前,请先阅读如何编辑 API 页面

帐号游戏时间范围函数 (Account PlayTime Limit Functions)

此类API函数是专门为防沉迷系统而设计的,能计算出当前玩家游戏时间等内容,当前只在亚洲地区有效。

  • GetBillingTimeRested() - 返回当前帐户已登陆时间。

    PartialPlayTime() - 如果用户状态为“疲劳(tired)”则返回1:降低经验及掉落。

    NoPlayTime() - 如果用户状态为“不健康的(unhealthy)”则返回1:无经验及掉落。

编辑


动作函数 (Action Functions)

这些函数对动作按钮进行操作(通常玩家的动作有可能通过下面列表中的函数执行)。

  • 保护 界面 ActionButtonDown(id) - 按下指定动作按钮。
    保护 界面 ActionButtonUp(id) - 释放指定动作按钮。
    ActionHasRange(slot) - 检测指定动作按钮是否受距离限制 (是则返回 1,否则返回 nil) 。
    界面 BonusActionButtonDown - 触发指定额外动作按钮 (宠物或仆从)。
    界面 BonusActionButtonUp - 释放指定额外动作按钮 (宠物或仆从)。
    保护 CameraOrSelectOrMoveStart() - 在 3D 界面开始 "左键单击" 动作。 (1.10 - 保护)
    保护 CameraOrSelectOrMoveStop([stickyFlag]) - 在 3D 界面结束 "左键单击" 动作。 (1.10 - 保护)
    ChangeActionBarPage() - 更改系统动作按钮页面为系统变量 CURRENT_ACTIONBAR_PAGE 指定页。
    GetActionBarToggles() - 获取系统动作条显示状况。
    GetActionCooldown(slot) - 获取指定动作按钮冷却状况。
    GetActionCount(slot) - 获取动作按钮所需物品剩余量 (绷带/毒药/等),无物品或不可用时返回 0。
    GetActionText(slot) - 获取动作按钮文本标签 (宏, 等),不存在则返回 nil。
    GetActionTexture(slot) - 获取指定动作按钮材质路径。
    GetBonusBarOffset() - 检测何种额外动作条已显示。
    HasAction(slot) - 假如指定动作条按钮有技能执行,则返回 1,其他情况返回 nil。
    IsActionInRange(slot) - 测试技能是否在施展距离内 (1=是, 0=否, nil=不可用)。
    IsAttackAction(slot) - 技能为“攻击”动作则返回 1 (战斗中闪光), 其他情况返回 nil。
    IsAutoRepeatAction(slot) - 技能可自动重复时返回 1,其他情况返回 nil。
    IsCurrentAction(slot) - 技能动作正在执行时返回 1,其他情况返回 nil。
    IsUsableAction(slot) - 技能可立即执行时返回 1,其他情况返回 nil。
    IsConsumableAction(slot) - 技能有施展次数时返回 1 (例如:施法物品),其他情况返回 nil。
    IsEquippedAction(slot) - 必须装备才能施展的技能返回 1 (例如:链接到必须装备的物品),其他情况返回 nil。
    PetHasActionBar() - 检测玩家宠物是否有动作条。
    PickupAction(slot) - 将指定动作按钮的技能提取并放置于光标上。
    PickupPetAction(slot) - 将指定的宠物动作按钮的技能提取并放置于光标上。
    PlaceAction(slot) - 将鼠标上的技能放置于指定动作按钮。
    SetActionBarToggles(show1,show2,show3,show4[, alwaysShow]) - 设置指定系统动作条显示。 - 1.12 版本添加 'alwaysShow'。
    保护 TurnOrActionStart() - 在 3D 界面开始 "右键单击" 动作。(1.10 - 保护)
    保护 TurnOrActionStop() - 在 3D 界面结束 "右键单击" 动作。 (1.10 - 保护)
    保护 UseAction(slot[, checkCursor[, onSelf]]) - 执行绑定到指定 ID 的动作按钮技能,可定向玩家 (与目标无关)。

编辑


行为函数 (Activity Functions)

这个部分的函数会引发玩家角色的动作(未在别处加以保护, 非简单确认步骤)

编辑


插件函数 (AddOn Functions)

编辑


竞技场函数(Arena Functions)

  • ArenaTeamInviteByName(teamIndex, playerName) - Invites the specified player to the specified arena team.
    ArenaTeamLeave(teamIndex) - Leaves the specified arena team.
    ArenaTeamRoster(teamIndex) - Sends a request to the server to request the most recent information on a specific Arena Team that you are in.
    ArenaTeamUninviteByName(teamIndex, playerName) - Removes the specified played from the specified arena team.
    ArenaTeamDisband(teamIndex) - Disbands the arena team without any warning! Requires you to be the leader of the team. (Known to be implemented as of 2.1.3, but may have existed before).
    GetArenaCurrency() - Gets the amount of arena points a player currently has to spend.
    GetArenaTeam(teamIndex) - Returns information regarding the players arena team, nil if the player is not in the passed team
    GetArenaTeamRosterInfo(teamIndex, playerIndex) - Returns information regarding a player from the specified team, this requires a call to ArenaTeamRoster you only need to do this when the player logins in, UI reloads will not effect the return.
    GetNumArenaTeamMembers(teamIndex[, showOffline]) - Gets the number of arena team members, this requires a call to ArenaTeamRoster you only need to do this when the player logins in, UI reloads will not effect the return.
    GetBattlefieldTeamInfo(index) - Gets info about a registered Arena Team at the end of an arena match.
    GetCurrentArenaSeason() - Gets the current Arena season.
    IsActiveBattlefieldArena() - Returns true if in an Arena Match, also Returns true for the second argument if it's a registered match.
    IsArenaTeamCaptain(teamIndex) - Returns a value based on whether the player is the arena team captain.
    IsBattlefieldArena() - Returns true if the battlemaster you're talking to can queue you for arenas

编辑


拍卖函数 (Auction Functions)

编辑

具体内容:http://wiki.cwowaddon.com/WoWAPI


  • 2
    点赞
  • 11
    收藏
    觉得还不错? 一键收藏
  • 1
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论 1
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值