| @@ 53-67 (lines=15) @@ | ||
| 50 | def processBATTLEPhase(self, tran, obj, data): |
|
| 51 | return None |
|
| 52 | ||
| 53 | def getDiplomacyWith(self, tran, obj, playerID): |
|
| 54 | # this AI battles with overyone |
|
| 55 | # make default |
|
| 56 | dipl = IDataHolder() |
|
| 57 | dipl.type = Const.T_DIPLREL |
|
| 58 | dipl.pacts = {} |
|
| 59 | if obj.oid == playerID: |
|
| 60 | dipl.relation = Const.REL_UNITY |
|
| 61 | else: |
|
| 62 | dipl.relation = Const.REL_ENEMY |
|
| 63 | dipl.relChng = 0 |
|
| 64 | dipl.lastContact = tran.db[Const.OID_UNIVERSE].turn |
|
| 65 | dipl.contactType = Const.CONTACT_NONE |
|
| 66 | dipl.stats = None |
|
| 67 | return dipl |
|
| 68 | ||
| 69 | def isPactActive(self, tran, obj, partnerID, pactID): |
|
| 70 | return 0 |
|
| @@ 132-145 (lines=14) @@ | ||
| 129 | obj.techs[Rules.Tech.PIRATEFTLENG] = Rules.techMaxImprovement |
|
| 130 | obj.techs[Rules.Tech.PIRCOLONYMOD] = Rules.techMaxImprovement |
|
| 131 | ||
| 132 | def getDiplomacyWith(self, tran, obj, playerID): |
|
| 133 | if obj.oid == playerID: |
|
| 134 | return Const.REL_UNITY |
|
| 135 | # this AI battles with overyone |
|
| 136 | # make default |
|
| 137 | dipl = IDataHolder() |
|
| 138 | dipl.type = Const.T_DIPLREL |
|
| 139 | dipl.pacts = {} |
|
| 140 | dipl.relation = Const.REL_ENEMY |
|
| 141 | dipl.relChng = 0 |
|
| 142 | dipl.lastContact = tran.db[Const.OID_UNIVERSE].turn |
|
| 143 | dipl.contactType = Const.CONTACT_NONE |
|
| 144 | dipl.stats = None |
|
| 145 | return dipl |
|
| 146 | ||
| 147 | def isPactActive(self, tran, obj, partnerID, pactID): |
|
| 148 | if partnerID == Const.OID_NONE: |
|
| @@ 125-138 (lines=14) @@ | ||
| 122 | # fix goverment power |
|
| 123 | obj.govPwrCtrlRange = 10000 |
|
| 124 | ||
| 125 | def getDiplomacyWith(self, tran, obj, playerID): |
|
| 126 | if obj.oid == playerID: |
|
| 127 | return Const.REL_UNITY |
|
| 128 | # this AI battles with overyone |
|
| 129 | # make default |
|
| 130 | dipl = IDataHolder() |
|
| 131 | dipl.type = Const.T_DIPLREL |
|
| 132 | dipl.pacts = {} |
|
| 133 | dipl.relation = Const.REL_ENEMY |
|
| 134 | dipl.relChng = 0 |
|
| 135 | dipl.lastContact = tran.db[Const.OID_UNIVERSE].turn |
|
| 136 | dipl.contactType = Const.CONTACT_NONE |
|
| 137 | dipl.stats = None |
|
| 138 | return dipl |
|
| 139 | ||
| 140 | # allow normal pacts |
|
| 141 | #def isPactActive(self, tran, obj, partnerID, pactID): |
|
| @@ 107-120 (lines=14) @@ | ||
| 104 | obj.shipDesigns[3] = ShipUtils.makeShipMinSpec(obj, 'Frigate', Rules.Tech.MEDIUMHULL2, |
|
| 105 | {Rules.Tech.SBRIDGE1:1, Rules.Tech.CANNON1:2, Rules.Tech.SSROCKET:2}, []) |
|
| 106 | ||
| 107 | def getDiplomacyWith(self, tran, obj, playerID): |
|
| 108 | if obj.oid == playerID: |
|
| 109 | return Const.REL_UNITY |
|
| 110 | # renegade battles with overyone |
|
| 111 | # make default |
|
| 112 | dipl = IDataHolder() |
|
| 113 | dipl.type = Const.T_DIPLREL |
|
| 114 | dipl.pacts = {} |
|
| 115 | dipl.relation = Const.REL_ENEMY |
|
| 116 | dipl.relChng = 0 |
|
| 117 | dipl.lastContact = tran.db[Const.OID_UNIVERSE].turn |
|
| 118 | dipl.contactType = Const.CONTACT_NONE |
|
| 119 | dipl.stats = None |
|
| 120 | return dipl |
|
| 121 | ||
| 122 | @public(Const.AL_ADMIN) |
|
| 123 | def processFINALPhase(self, tran, obj, data): |
|