コード例 #1
0
        public int SpawnNewBot(MyAgentDefinition agentDefinition)
        {
            Vector3D spawnPosition = default(Vector3D);

            if (!BotFactory.GetBotSpawnPosition(agentDefinition.BehaviorType, out spawnPosition))
            {
                return(0);
            }

            return(SpawnNewBotInternal(agentDefinition, spawnPosition, false));
        }
コード例 #2
0
        public int SpawnNewBot(MyAgentDefinition agentDefinition)
        {
            //if (!MyAIComponent.Static.CanSpawnMoreBots(agentDefinition.BehaviorType))
            //    return 0;

            Vector3D spawnPosition = default(Vector3D);

            if (!BotFactory.GetBotSpawnPosition(agentDefinition.BehaviorType, out spawnPosition))
            {
                return(0);
            }

            return(SpawnNewBotInternal(agentDefinition, spawnPosition, false));
        }