Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Help with CBOT environment control:
#1
Hiya!

I'm currently working on a really cool mode (at least I think it's cool) for Code Battles. King of The Hill to be exact. And I'm a bit stalled, as it'll rely heavily on Overlord Bot, wich will take care about respawning destroyed bots. The issues I have are:
  • Is it possible to produce(); damaged and powered vehicle?
  • Is it possible to produce(); vehicle with loaded and running user's program without necessity to paste it earlier in predefined directory? (i.e. Save program as public and run it at respawn.
  • Is it possible for neutral bot to spawn teamed bot?
I answers to those are "No." I'll be rather unhappy, but I already have workarounds prepared. But they're not foolproof and rather complicated to implement (namely multiple "service" bots, at very least 8 of them).

Also, I'd appreciate if someone passed me knowledge on how to dynamically keep track on bots, specially their ammount.
I'll need to write a CBOT script to keep 2 Tracked OrgaShooters and one Practice Bot per team with 5s respawn cooldowns (it's completely untested ammount obviously and I will adjust it as needed.

Also, question for you guys - would you prefer to play it 'till first bot gets on platform or first-to-get-3? CBOT Overlord program adds shitton of possibilities to Code Battles.

PS Yes, I am hyped.
Si vis pace, para bellum.

#2
(03-08-2017, 08:29 PM)Quartofel Wrote: Overlord Bot
The concept of using a CBOT script to contol a level is not new. We call this a LevelController script, but some people still use the old temporary name GhostBot. The level files even have an LevelController command which creates an invisible object (but after some refactoring it will likely have no assockated object at all). The only problem is, as you noticed, CBOT is missing many functions for doing anything advanced with it.

(03-08-2017, 08:29 PM)Quartofel Wrote:
  • Is it possible to produce(); damaged and powered vehicle?
Unfortunately, no. But allowing produce() to specify other object parameters is something that has been on my TODO list for quite a while.

(03-08-2017, 08:29 PM)Quartofel Wrote:
  • Is it possible to produce(); vehicle with loaded and running user's program without necessity to paste it earlier in predefined directory? (i.e. Save program as public and run it at respawn.
You can try ../program/ProgName.txt for public saved programs, but I can't promise that works because I never tried it.

(03-08-2017, 08:29 PM)Quartofel Wrote:
  • Is it possible for neutral bot to spawn teamed bot?
No, see the point about expanding produce() parametrs.

(03-08-2017, 08:29 PM)Quartofel Wrote: Also, I'd appreciate if someone passed me knowledge on how to dynamically keep track on bots, specially their ammount.
Try sizeof(radarall(PracticeBot)); (also works with other radar parameters for team selection)
Keep in mind this is untested, and radarall is quite a new addition to CBOT.
#3
Ok, thank you. Workarounds then, I still think that this concept is doable.
Si vis pace, para bellum.



Forum Jump:


Users browsing this thread: 2 Guest(s)