* @version : HUOSDK 8.0 */ namespace huolib\utils; use huolib\constant\GameConst; use huolib\status\DeviceStatus; use huolib\status\GameStatus; class GameUtils { /** * 校验SDK订单 * * @param array $game_data * * @return int */ public static function checkGame($game_data = []) { if (empty($game_data)) { return DeviceStatus::INVALID_PARAMS; } return DeviceStatus::NO_ERROR; } /** * 校验支付方式 * * @param int $server_type * * @return int */ public static function checkServerType($server_type = 0) { if (empty($server_type)) { return GameStatus::NO_ERROR; } $_rs = GameConst::getServerMsg($server_type); if (false == $_rs) { return GameStatus::SERVER_TYPE_ERROR; } return GameStatus::NO_ERROR; } }