Oolite Bulletins

For information and discussion about Oolite.
It is currently Sun Mar 24, 2019 3:20 am

All times are UTC

Post new topic  Reply to topic  [ 1 post ] 
Author Message
 Post subject: Basic station AI
PostPosted: Sun Aug 07, 2016 9:46 am 
---- E L I T E ----
---- E L I T E ----
User avatar

Joined: Wed Aug 15, 2012 4:19 am
Posts: 2549
Location: Finland
I'm messing with YAH stations' AI and would really, really much appreciate a basic station js AI that, on top of doing the basic defense and traffic control, would have it's own defense ship patrolling the station. Basically I would like to write something like this:
this.aiStarted = function() {
		/* Patrol */
			preconfiguration: ai.configurationCheckScanner,
			notcondition: ai.conditionScannerContainsPatrol,
			behaviour: ai.behaviourStationLaunchPatrol,
			reconsider: 60
So logically after setting ai.setParameter("oolite_stationPatrolRole","tescoosecurity");, ai.conditionScannerContainsPatrol would check for "tescoosecurity" and ai.behaviourStationLaunchPatrol would launch "tescoosecurity" that would keep patrolling the station perimeter.

I'm not sure what ai.setParameter("oolite_stationPatrolRole","tescoosecurity"); and ai.conditionScannerContainsPatrol exactly achieve, but ai.behaviourStationLaunchPatrol always launches police ships.

Hope that makes some sense :D .

Display posts from previous:  Sort by  
Post new topic  Reply to topic  [ 1 post ] 

All times are UTC

Who is online

Users browsing this forum: No registered users and 10 guests

You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
Powered by phpBB® Forum Software © phpBB Limited