impl#

对具体的 GM 命令业务逻辑高度封装后的接口. 这些接口可以分为两类:

  1. 我们只关心运行成功与否, 不关心返回值.

  2. 我们需要这个命令返回的数据.

所有的接口都有这三个参数:

  • bsm: boto_session_manager.BotoSesManager 对象, 定义了 AWS 权限.

  • server_id: 服务器的逻辑 ID, 命名规则为 ${env_name}-${server_name}. 例如 sbx-blue.

  • raises: 当命令执行失败时是否抛出异常, 默认为 True.

Reference:

acore_soap_app.sdk.canned.impl.get_online_players(bsm: BotoSesManager, server_id: str, raises: bool = True) Dict[str, int][source]#
Returns:

a dict with two keys: connected_players and characters_in_world.

acore_soap_app.sdk.canned.impl.is_server_online(bsm: BotoSesManager, server_id: str, raises: bool = True) bool[source]#
Returns:

a boolean value to indicate whether the server is online

acore_soap_app.sdk.canned.impl.create_account(bsm: BotoSesManager, server_id: str, username: str, password: str, raises: bool = True) bool[source]#
Returns:

a boolean value to indicate whether the account is created successfully

acore_soap_app.sdk.canned.impl.set_gm_level(bsm: BotoSesManager, server_id: str, username: str, level: int, realm_id: int, raises: bool = True) bool[source]#
Parameters:
  • username

  • level

  • realm_id

Returns:

a boolean value to indicate whether the account is created successfully

acore_soap_app.sdk.canned.impl.set_password(bsm: BotoSesManager, server_id: str, username: str, password: str, raises: bool = True) bool[source]#
Parameters:
  • username

  • level

  • realm_id

Returns:

a boolean value to indicate whether the account is created successfully

acore_soap_app.sdk.canned.impl.delete_account(bsm: BotoSesManager, server_id: str, username: str, raises: bool = True) bool[source]#
Parameters:

username

Returns:

a boolean value to indicate whether the account is deleted successfully

acore_soap_app.sdk.canned.impl.gm_list(bsm: BotoSesManager, server_id: str, raises: bool = True) List[Tuple[str, int]][source]#
Returns:

a boolean value to indicate whether the account is deleted successfully