From NEAT Portal Wiki
Jump to: navigation, search
(Farmingpolicy)
Line 1: Line 1:
 
==Farmingpolicy==
 
==Farmingpolicy==
  
{| style="width: 45%; text-align:center" border="1"
+
{| class="wikitable"
! scope="row" | Usage:
+
! style="text-align:left;" | Usage:
 
| config npc:[switch]
 
| config npc:[switch]
 
|-
 
|-
! scope="row" | Example:
+
! style="text-align:left;" | Example:
 
| farmingpolicy /level:5 /mindistance:1 /maxdistance:7 /farmingcycle:8<br>
 
| farmingpolicy /level:5 /mindistance:1 /maxdistance:7 /farmingcycle:8<br>
 
farmingpolicy /level:10 /mindistance:1 /maxdistance:5 /farmingcycle:1<br>
 
farmingpolicy /level:10 /mindistance:1 /maxdistance:5 /farmingcycle:1<br>
Line 53: Line 53:
 
==Npclimit==
 
==Npclimit==
  
{| style="width: 25%; text-align:center" border="1"
+
{| class="wikitable"
! scope="row" | Usage:
+
! style="text-align:left;" | Usage:
 
| config npclimit:[days]
 
| config npclimit:[days]
 
|-
 
|-
! scope="row" | Example:
+
! style="text-align:left;" | Example:
 
| config npclimit:10
 
| config npclimit:10
 
|}
 
|}
Line 66: Line 66:
 
==Buildnpc==
 
==Buildnpc==
  
{| style="width: 25%; text-align:center" border="1"
+
{| class="wikitable"
! scope="row" | Usage:
+
! style="text-align:left;" | Usage:
 
| config buildnpc:[switch]
 
| config buildnpc:[switch]
 
|-
 
|-
! scope="row" | Example:
+
! style="text-align:left;" | Example:
 
| config buildnpc:15
 
| config buildnpc:15
 
|-
 
|-
! scope="row" | Switch:
+
! style="text-align:left;" | Switch:
 
| 0 - Disable buildnpc<br>
 
| 0 - Disable buildnpc<br>
 
1 - Build npcs level 1<br>
 
1 - Build npcs level 1<br>
Line 103: Line 103:
 
==Npclist==
 
==Npclist==
  
{| style="width: 35%; text-align:center" border="1"
+
{| class="wikitable"
! scope="row" | Usage:
+
! style="text-align:left;" | Usage:
 
| npclist [level] npc1 npc2 npc3 [...] npcX
 
| npclist [level] npc1 npc2 npc3 [...] npcX
 
|-
 
|-
! scope="row" | Example:
+
! style="text-align:left;" | Example:
 
| npclist 5 111,222 111,333 111,444 111,555<br>
 
| npclist 5 111,222 111,333 111,444 111,555<br>
 
npclist 8 111,202 111,303 111,404 111,505
 
npclist 8 111,202 111,303 111,404 111,505
Line 118: Line 118:
 
==Npctroops==
 
==Npctroops==
  
{| style="width: 35%; text-align:center" border="1"
+
{| class="wikitable"
! scope="row" | Usage:
+
! style="text-align:left;" | Usage:
 
| npctroops [level] troops_to_send
 
| npctroops [level] troops_to_send
 
|-
 
|-
! scope="row" | Example:
+
! style="text-align:left;" | Example:
 
| npctroops 10 a:90000,wo:2000,w:2000,s:4000,t:2000<br>
 
| npctroops 10 a:90000,wo:2000,w:2000,s:4000,t:2000<br>
 
npctroops 9  a:90000,wo:2000,w:2000,s:4000,t:2000<br>
 
npctroops 9  a:90000,wo:2000,w:2000,s:4000,t:2000<br>
Line 133: Line 133:
 
==Npcteams ==
 
==Npcteams ==
  
{| style="width: 25%; text-align:center" border="1"
+
{| class="wikitable"
! scope="row" | Usage:
+
! style="text-align:left;" | Usage:
 
| npcteams number_to_send  
 
| npcteams number_to_send  
 
|-
 
|-
! scope="row" | Example:
+
! style="text-align:left;" | Example:
 
| npcteams 7
 
| npcteams 7
 
|}
 
|}
Line 145: Line 145:
 
==Ballsused==
 
==Ballsused==
  
{| style="width: 25%; text-align:center" border="1"
+
{| class="wikitable"
! scope="row" | Usage:
+
! style="text-align:left;" | Usage:
 
| ballsused npc1s,npc2s,npc3s,npc4s,npc5s
 
| ballsused npc1s,npc2s,npc3s,npc4s,npc5s
 
|-
 
|-
! scope="row" | Example:
+
! style="text-align:left;" | Example:
 
| ballsused 25,50,170,250,500
 
| ballsused 25,50,170,250,500
 
|}
 
|}
Line 157: Line 157:
 
==Npc10list ==
 
==Npc10list ==
  
{| style="width: 25%; text-align:center" border="1"
+
{| class="wikitable"
! scope="row" | Usage:
+
! style="text-align:left;" | Usage:
 
| npc10list npc1 npc2 npc3 npc4
 
| npc10list npc1 npc2 npc3 npc4
 
|-
 
|-
! scope="row" | Example:
+
! style="text-align:left;" | Example:
 
| npc10list 111,222 111,333 111,444
 
| npc10list 111,222 111,333 111,444
 
|}
 
|}
Line 169: Line 169:
 
==Npc10troops==
 
==Npc10troops==
  
{| style="width: 35%; text-align:center" border="1"
+
{| class="wikitable"
! scope="row" | Usage:
+
! style="text-align:left;" | Usage:
 
| npc10troops troops_to_send  
 
| npc10troops troops_to_send  
 
|-
 
|-
! scope="row" | Example:
+
! style="text-align:left;" | Example:
 
| npc10troops a:90000,wo:2000,w:2000,s:4000,t:2000
 
| npc10troops a:90000,wo:2000,w:2000,s:4000,t:2000
 
|}
 
|}
Line 181: Line 181:
 
==Npc10limit==
 
==Npc10limit==
  
{| style="width: 25%; text-align:center" border="1"
+
{| class="wikitable"
! scope="row" | Usage:
+
! style="text-align:left;" | Usage:
 
| npc10limit troops_to_have  
 
| npc10limit troops_to_have  
 
|-
 
|-
! scope="row" | Example:
+
! style="text-align:left;" | Example:
 
| npc10limit a:390000,s:50000  
 
| npc10limit a:390000,s:50000  
 
|}
 
|}
Line 193: Line 193:
 
==NpcLimits==
 
==NpcLimits==
  
{| style="width: 25%; text-align:center" border="1"
+
{| class="wikitable"
! scope="row" | Usage:
+
! style="text-align:left;" | Usage:
 
| npclimits [level] troops_to_have
 
| npclimits [level] troops_to_have
 
|-
 
|-
! scope="row" | Example:
+
! style="text-align:left;" | Example:
 
| npclimits 10 a:390000,s:50000<br>
 
| npclimits 10 a:390000,s:50000<br>
 
npclimits 8 a:50000,w:100000
 
npclimits 8 a:50000,w:100000
Line 206: Line 206:
 
==Npcbounds==
 
==Npcbounds==
  
{| style="width: 25%; text-align:center" border="1"
+
{| class="wikitable"
! scope="row" | Usage:
+
! style="text-align:left;" | Usage:
 
| npcbounds Xmin Xmax Ymin Ymax
 
| npcbounds Xmin Xmax Ymin Ymax
 
|-
 
|-
! scope="row" | Example:
+
! style="text-align:left;" | Example:
 
| npcbounds 5 200 215 400 415<br>
 
| npcbounds 5 200 215 400 415<br>
 
npcbounds 8 200 205 400 405
 
npcbounds 8 200 205 400 405
Line 223: Line 223:
 
==Npcexcludelist==
 
==Npcexcludelist==
  
{| style="width: 25%; text-align:center" border="1"
+
{| class="wikitable"
! scope="row" | Usage:
+
! style="text-align:left;" | Usage:
 
| npcexcludelist npc1 npc2 npc3 npc4
 
| npcexcludelist npc1 npc2 npc3 npc4
 
|-
 
|-
! scope="row" | Example:
+
! style="text-align:left;" | Example:
 
| npcexcludelist 111,222 111,333 111,444
 
| npcexcludelist 111,222 111,333 111,444
 
|}
 
|}
Line 235: Line 235:
 
==Npc10excludelist==
 
==Npc10excludelist==
  
{| style="width: 35%; text-align:center" border="1"
+
{| class="wikitable"
! scope="row" | Usage:
+
! style="text-align:left;" | Usage:
 
| npc10excludelist npc1 npc2 npc3 npc4
 
| npc10excludelist npc1 npc2 npc3 npc4
 
|-
 
|-
! scope="row" | Example:
+
! style="text-align:left;" | Example:
 
| npc10excludelist 111,222 111,333 111,444
 
| npc10excludelist 111,222 111,333 111,444
 
|}
 
|}
Line 247: Line 247:
 
==Farmingcycle==
 
==Farmingcycle==
  
{| style="width: 25%; text-align:center" border="1"
+
{| class="wikitable"
! scope="row" | Usage:
+
! style="text-align:left;" | Usage:
 
| config farmingcycle:[hours]
 
| config farmingcycle:[hours]
 
|-
 
|-
! scope="row" | Example:
+
! style="text-align:left;" | Example:
 
| config farmingcycle:6
 
| config farmingcycle:6
 
|}
 
|}

Revision as of 08:56, 1 June 2011

Farmingpolicy

Usage: config npc:[switch]
Example: farmingpolicy /level:5 /mindistance:1 /maxdistance:7 /farmingcycle:8

farmingpolicy /level:10 /mindistance:1 /maxdistance:5 /farmingcycle:1
farmingpolicy /level:8 /mindistance:1 /maxdistance:5 /farmingcycle:1

Npc farming has receieved a major overhaul in Y.A.E.B. starting in versions past 1268. It is now much more flexible and powerful, allowing you to farm specific levels of npcs for specific numbers of miles in specific intervals. The switches /mindistance and /maxdistance allow you to instruct the bot how far it will go for that particular level of npc. Details on how the bot prioritizes which npcs to farm with the various available settings can be found here. The /farmingcycle switch allows you to tell the bot how often to reset it's farming history for that particular level of npc, and start over from the closest.

The above 3 examples could be combined with npcheroes, npctroops, and npclimits to have your bot farm level 5, 8, and 10 npcs as follows:

farmingpolicy /level:5 /mindistance:1 /maxdistance:7 /farmingcycle:8
npcheroes 5 !mainguy,!queen,any
npctroops 5 b:500,t:400

farmingpolicy /level:10 /mindistance:1 /maxdistance:5 /farmingcycle:1
npcheroes 10 mainguy
npctroops 10 a:90k,w:2k,wo:2k,s:4k,t:2k
npclimits 10 a:400k

farmingpolicy /level:8 /mindistance:1 /maxdistance:5 /farmingcycle:1
npcheroes 8 queen,smartguy
npctroops 8 a:19k,w:80k,t:1k
npclimits 8 w:200k,a:100k

By default the bot will send out as many npc runs at a time as it's able to with troops, heroes, and limits. You may wish to control how many are sent at a time. This can be done via the goal npcteams or via rallypolicy.

The bot is automatically programmed to send the proper safe amount of transports and ballista (for lvl 1-5 npcs), or transports, archers, and layers (for 6+ npcs) based on the level of the npc and your logistics research. You can change the default troops used with the config settings ballsused or npctroops. If a hero is sent on a npc farming run, and it's attack attribute is below 50, the bot will send the default number of ballista regardless of what you set. For level 5 npcs, this default is 550 ballista.

The bot starts with the closest npc and works it's way out, restarting again based on the following order of priority:

Y.A.E.B. will automatically detect maintenance and reset your farming cycle after it relogs. You can manually reset it by typing \resetfarminghistory in the Commands window.

Farming Restrictions

There are many goals the bot can use to determine which npcs it is allowed to farm. They are processed by the bot in the following order of priority:

  • If an npclist is set for that level of npcs, it will farm npcs only on the list.
  • If npcbounds is set, farm all npcs within these boundaries
  • If farmingpolicy uses /mindistance and /maxdistance switches, then farm all npcs within that many miles from the city
  • If distancepolicy is set, then farm all npcs within that many miles from the city
  • If nothing is set to determine distance, then farm for a 10 mile radius from the city.

Npclimit

Usage: config npclimit:[days]
Example: config npclimit:10

This goal sets a limit in days for the amount of food obtained when farming npc's, Y.A.E.B. will limit farming to the specified number of days based on your troops' food consumption. If this is not set, or the goal is not reached, the bot will farm your npcs once every 8 hours. If this is set and the goal is reached, the bot will no longer farm until it falls below the specified number of days, or unless config training:1 or config training:2 is enabled.


Buildnpc

Usage: config buildnpc:[switch]
Example: config buildnpc:15
Switch: 0 - Disable buildnpc

1 - Build npcs level 1
2 - Build npcs level 2
3 - Build npcs level 3
4 - Build npcs level 4
5 - Build npcs level 5
10 - Build npcs level 10
15 - Build npcs level 5 & 10
20 - Convert all flats to npcs

Combined with buildnpcmin and buildnpcmax, this tells the bot what levels of npcs you wish to have it build for you. The bot will attack open flats of the requested levels using the troops specified in valleytroops, or the default if one is not set.

You should specify which npcs you want to be built at which distances by using buildnpcmin and buildnpcmax. For example, if config buildnpc:20 is enabled the bot will know to fill every flat with npcs, but you may not want it building junk level npcs close to you. You can set the minimum and maximum miles for each level of npcs from you that it will build using the following syntax:

Buildnpcmin npc1s npc2s npc3s npc4s npc5s npc6s npc7s npc8s npc9s npc10s
Buildnpcmax npc1s npc2s npc3s npc4s npc5s npc6s npc7s npc8s npc9s npc10s

As an example, if I wanted the bot to build level 10 npcs within 4 miles of my city, level 5 npcs between 5-8 miles of my city, and any level npcs beyond 8 miles from my city up to a 20 mile radius away from my city, I would type it as:

buildnpcmin 9 9 9 9 5 9 9 9 9 0
buildnpcmax 20 20 20 20 8 20 20 20 20 4

Npclist

Usage: npclist [level] npc1 npc2 npc3 [...] npcX
Example: npclist 5 111,222 111,333 111,444 111,555

npclist 8 111,202 111,303 111,404 111,505

By default, Y.A.E.B. will find and farm npcs on it's own of the level you specify via the config npc goal. However, you may sometimes wish to restrict your bot to only farm specific npcs. You can do so with this directive. By listing the coordinates of every npc you wish the bot to farm, you can restrict it's farming. In the examples above, the bot will farm level level 5 npcs at the specified coordinates, and level 8 npcs at the other specified coordinates. Details on how the bot prioritizes which npcs to farm with the various available settings can be found here.

NOTE: it is not recommended to use this unless you need to due to sharing npcs with a friendly neighbor, etc. It's much better to let the bot decide what to hit.

Npctroops

Usage: npctroops [level] troops_to_send
Example: npctroops 10 a:90000,wo:2000,w:2000,s:4000,t:2000

npctroops 9 a:90000,wo:2000,w:2000,s:4000,t:2000
npctroops 8 w:100000
npctroops 5 b:400,t:400

By deafult, Y.A.E.B. will send out what it thinks is the optimal troop setup for each level of npc it farms. You can configure your own troop settings with this directive. In the example above, the bot will send out 400 ballista and 400 transports to level 5 npcs, 100k warriors to level 8 npcs, and 90k archers/2k workers/2k warriors/2k transports to level 9 and 10 npcs.

Npcteams

Usage: npcteams number_to_send
Example: npcteams 7

This directive tells the bot how many npc farm teams it may send out at a time.

Ballsused

Usage: ballsused npc1s,npc2s,npc3s,npc4s,npc5s
Example: ballsused 25,50,170,250,500

This directive is being phased out in lieu of the more powerful npctroops goal.

Npc10list

Usage: npc10list npc1 npc2 npc3 npc4
Example: npc10list 111,222 111,333 111,444

This directive is being phased out in lieu of the more powerful npclimits goal that has been expanded to accept a level parameter in versions after rev1268.

Npc10troops

Usage: npc10troops troops_to_send
Example: npc10troops a:90000,wo:2000,w:2000,s:4000,t:2000

This directive is being phased out in lieu of the more powerful npctroops goal.

Npc10limit

Usage: npc10limit troops_to_have
Example: npc10limit a:390000,s:50000

This directive is being phased out in lieu of the more powerful npclimits goal, below.

NpcLimits

Usage: npclimits [level] troops_to_have
Example: npclimits 10 a:390000,s:50000

npclimits 8 a:50000,w:100000

This is a necessary goal for npc level 6-10 farming. If this goal is not set, the bot will not farm npcs of these levels. This directive tells the bot the minimum number of troops it must have in the city before it will farm another level 6-10 npc. In the example above, the bot must have 390k archers and 50k scouts before it will resume farming 10s, and 50k archers and 100k warriors before it will resume farming 8s.

Npcbounds

Usage: npcbounds Xmin Xmax Ymin Ymax
Example: npcbounds 5 200 215 400 415

npcbounds 8 200 205 400 405

By default, Y.A.E.B. will find and farm npcs on it's own as specified with farmingpolicy. However, you may sometimes wish to restrict your bot to only farm npcs in a specific area. You can do so with this directive. This tells the bot the bounderies in which it may farm. In the example above, the bot would be allowed to farm in a square with the top left corner at 200,400 and the bottom right corner at 215,415 for level 5 npcs. In the 2nd example above, the bot will only farm level 8 npcs between 200,400 and 205,405.

The bot will process which npcs to farm based on the priorities specified here.

NOTE: it is not recommended to use this unless you need to due to sharing npcs with a friendly neighbor, etc. It's much better to let the bot decide what to hit.

Npcexcludelist

Usage: npcexcludelist npc1 npc2 npc3 npc4
Example: npcexcludelist 111,222 111,333 111,444

By default, Y.A.E.B. will find and farm npcs on it's own of the level you specify in farmingpolicy goals. However, you may sometimes wish to restrict your bot to not farm specific npcs. You can do so with this directive. This tells the bot to find what npcs to farm, but to skip the specified npcs in it's farming cycle. In the example above, all npcs within the allowed radius will be farmed, except 111,222 111,333 and 111,444. This exclude list works for any level of npc being farmed.

Npc10excludelist

Usage: npc10excludelist npc1 npc2 npc3 npc4
Example: npc10excludelist 111,222 111,333 111,444

This goal is no longer necessary. Npcexcludelist will exclude all npcs at the given coordinates, regardless of level.

Farmingcycle

Usage: config farmingcycle:[hours]
Example: config farmingcycle:6

By default, the bot will farm the npcs in range once every 8 hours. You can change the duration between restarting the farming cycle with this. Each city can have a different number of hours to restart farming from the beginning.

The bot will process priority of how often to farm in the following order:

  • If config training:1 or config training10:1, then farm every hour
  • If farmingpolicy for that level of npc specifies a /farmingcycle switch, then use that number of hours
  • If config farmingcycle (this goal) is set, then use that number of hours
  • If nothing is set, then use 8 hour cycles.