Colobot Forum - International Colobot Community

Full Version: Implementing the LRV
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Here is my idea how to make the LRV a bot:
changes to the LRV:
terrain:not anymore able to drive underwater
storages:2 the empty place in front of the seats,the seats
energy:on the moon a special battery, which can not be taken out and looks like part of it´s back block
battery storage:the battery storage in back block, if the LRV is build a part in the back block is missing(the place where the special battery was) in this part a battery can be put
health:now has health

changes to Cbot:
A new command called force is :added, which forces the nearest, charged grabbing unit or the astronaut to bring an item onto one of it´s storages:

Extern Void Object: ?
:   force(PowerCell.PlaceOne);               //Forces nearest grabbing unit to bring a PowerCell to storage place 1.
:   force(PowerCell.PlaceOne.away);       //Forces nearest grabbing unit to bring the PowerCell from place 1 away.

And the command ignore, which will let a grabber ignore the LRV´s orders:

Exter Void Object:Ignore
:  ignore();//Let´s the bot ignore the LRV.
:  ignore(PowerLevel.2)//Let´s the bot ignore the LRV´s orders if it has a lower energy level than 2.

new exercising levels:
Remote Control #9
How to use the LRV commands.

new challanges:
Moon Explorer
Use tracked grabber and the LRV to find 3 Titanium and 1 Uranium ore.

Charging drill #1
Use the ignore command to let the subber charge,before it executes the orders.
If you have ideas for exercises and challenges, I strongly encourage you to create your userlevels based on existing onesSmile it's a great way to learn how it all works in game, and what options are nice, what missions would be interesting, and such - test it yourself, and if you like it, share it with othersSmile
About the fuctions in cbot - there are better ways to communicate between bots - you might try to test them, check the "global variables"- you'll be able to command a bot to deliver resource to astronaut - go through exercises and you'll be able to write your own functions like force() and ignore() easilySmile
The idea with storage on LRV is ok, like an idea of a storage bot with several storage slots in general - but it appears it is not currently doable - it would require everyone to work on changing the fundaments of the game, as carrying many objects or even having an object loading slot that would work for something else than a power cell is currently not implemented. Same as adding other features you suggested - they aren't here not because noone thought about it, but because it would require years of hard work to put them in and working correctly. And it's very hard to do so. Just check how everyone tries to understand what is even happening in the code, here on github I'm an engineer of robotics and have done some programming projects, but I don't get how this works and could not implement anything without studying game code for years. If you're determined I encourage you to learn C++ and programming, and get into this code to try and work on it in the futureSmile