• My Pages
  • Comments
  • Add Link
  • Subscribe
  • Subscribe User
  • Edit (GUI)
  • Edit (Text)
  • Rename Page
  • Copy Page
  • Load Page
  • Save Page
  • Delete Page
  • Attachments
  • Check Spelling
  • Diffs
  • Info
  • Revert to this revision
  • XML
  • Render as Docbook
  • Print View
  • Raw Text
  • Delete Cache
  • Like Pages
  • Local Site Map
  • Remove Spam
  • Package Pages
  • Sync Pages
    • Diff for "getAvailableTroop"
    Differences between revisions 1 and 6 (spanning 5 versions)
    Revision 1 as of 2015-03-22 03:02:16
    Size: 1083
    Editor: tech
    Comment:
    Revision 6 as of 2015-04-23 04:43:46
    Size: 1343
    Editor: Inanna
    Comment:
    Deletions are marked like this. Additions are marked like this.
    Line 2: Line 2:
    ||<tablebgcolor="#F9F9F9" tablestyle="margin:1em 1em 1em 0px;border-style:solid;border-color:rgb(170, 170, 170);border-left-width:2px;color:rgb(0, 0, 0);font-family:sans-serif;font-size:13px;line-height:19.5px; " tableclass="wikitable"#F2F2F2 style="padding:0.2em;border-left-width:2px;border-style:solid;border-color:rgb(170, 170, 170); ">Usage: ||<style="padding:0.2em;border-left-width:2px;border-style:solid;border-color:rgb(170, 170, 170);">city.getAvailableTroop() ||
    ||<#F2F2F2 style="padding:0.2em;border-left-width:2px;border-style:solid;border-color:rgb(170, 170, 170); ">Example: ||<style="padding:0.2em;border-left-width:2px;border-style:solid;border-color:rgb(170, 170, 170);">city.getAvailableTroop() ||
    ||<tablebgcolor="#F9F9F9" tablestyle="margin:1em 1em 1em 0px;border-style:solid;border-color:rgb(170, 170, 170);border-left-width:2px;color:rgb(0, 0, 0);font-family:sans-serif;font-size:13px;line-height:19.5px;   " tableclass="wikitable"#F2F2F2 style="padding:0.2em;border-left-width:2px;border-style:solid;border-color:rgb(170, 170, 170);   ">Usage: ||<style="padding:0.2em;border-left-width:2px;border-style:solid;border-color:rgb(170, 170, 170);">city.getAvailableTroop() ||
    ||<#F2F2F2 style="padding:0.2em;border-left-width:2px;border-style:solid;border-color:rgb(170, 170, 170);   ">Example: ||<style="padding:0.2em;border-left-width:2px;border-style:solid;border-color:rgb(170, 170, 170);">city.getAvailableTroop() ||
    Line 6: Line 6:
    This function returns a troop bean containing the total count of all troops attached to a city (not just the troops in the city, includes troops marching to or returning from somewhere This function returns an object with information about the troops attached to a city. It can give the total of all troops, a specific troop, or the troop upkeep in a city. It counts marching troops as well as those idle.
    Line 11: Line 12:
    The available properties for the object are:
    Line 12: Line 14:
    {{{
    foodConsumeRate
    peasants
    militia
    scouter
    pikemen
    swordsmen
    archer
    lightCavalry
    heavyCavalry
    carriage
    ballista
    batteringRam
    catapult
    }}}
    Line 13: Line 30:

    getAvailableTroop()

    Usage:

    city.getAvailableTroop()

    Example:

    city.getAvailableTroop()

    This function returns an object with information about the troops attached to a city. It can give the total of all troops, a specific troop, or the troop upkeep in a city. It counts marching troops as well as those idle.

    • echo "I have a total of  {city.getAvailableTroop().carriage} transports assigned to this city"

    The available properties for the object are:

    foodConsumeRate
    peasants 
    militia  
    scouter 
    pikemen  
    swordsmen  
    archer  
    lightCavalry 
    heavyCavalry 
    carriage 
    ballista  
    batteringRam 
    catapult 


    CategoryFunctions

    getAvailableTroop (last edited 2016-01-09 10:48:40 by LKD70)