From NEAT Portal Wiki
Revision as of 17:06, 20 June 2012 by Inanna (talk | contribs) (Created page with "There is a great deal of info the bot is able to make available for the advanced scripter, via the ifgoto and ifgosub scripts. The complete list of variables usable is a work in ...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to: navigation, search

There is a great deal of info the bot is able to make available for the advanced scripter, via the ifgoto and ifgosub scripts. The complete list of variables usable is a work in progress, and a debt of gratitude goes to several YAEB users for testing and finding them. Special thanks to Dismayed for compiling it all into a list.

Ifgoto

Usage: ifgoto ( reference {operator} value ) label
Example: ifgoto ( m_city.cityManager.resource.wood.amount > 150000 )

See ifgosub

Ifgosub

Usage: ifgosub ( reference {operator} value ) label
Example: ifgosub ( m_city.cityManager.resource.wood.amount > 150000 )

Conditional Statements enable checking of resources,troops,population,…etc.

Conditional Statements add a whole new dimension to Y.A.E.B. scripts allowing more human-like interaction & less "insuffient resource" statements.

Variables for use in ifgoto & ifgosub statements can be found in the Reference Section.

ifgosub ( m_city.cityManager.resource.stone.amount > 250000 ) CheckATT
ifgosub ( m_city.cityManager.resource.iron.amount > 150000 ) CheckTrain
sleep rnd:3000
loop 0
//
label CheckTrain
ifgosub ( m_city.cityManager.resource.wood.amount > 150000 ) TrainTroops
gosubreturn 
//
label CheckATT
ifgosub ( m_city.cityManager.resource.wood.amount > 250000 ) UpATT
gosubreturn
//
label TrainTroops
train arch:250 Bubba
repeat 4
gosubreturn
//
label UpATT
walldefense archertowers 250
gosubreturn