local ServerFormationManager = {} function ServerFormationManager:updateFormation(params, callback) local result = { status = 1 } if params == nil then if callback then callback(result) end return end local formationType = params.formationType local matchType = tostring(params.matchType) local heroId = params.heroId if formationType and matchType and heroId then local ServerGameData = require "app/server/server_game_data" if ServerGameData.FormationData:upHeroToFormation(formationType, matchType, heroId) then result.status = 0 end end if callback then callback(result) end end return ServerFormationManager