View Single Post
  #9  
Old October 19th, 2004, 06:21 PM

Tuna Tuna is offline
Corporal
 
Join Date: Aug 2004
Posts: 98
Thanks: 0
Thanked 0 Times in 0 Posts
Tuna is on a distinguished road
Default Re: dom 3 wish: mod AI

Well, just my 2 cents:

If the game is in really early developement, and you are considering rewriting the strategic map engine, please please consider doing it with open file formats.

That would mean that a .trn file has (encrypted by the turn password) all the data of the game situation that the player nation is capable of knowing in just (zipped) plain text. The format already exists as your modding commands, just reverse the # and no # to save some space.
Code:

province 112 (owned rich province)
owner 2
unrest 1
tax 50
plains
population 10000
income 100
resources 10
site = "ten thousand things"
dominion 1
scales = 1, 1, -1, 3, 1, 1
End

province 113 (seen indie province with neg dom)
owner 0
plains
dominion -1
scales -1, 0, 0, 0 ,0, 1
End

unit 23 (pretender)
owner = 2
location = 112
type = 10
affliction = lost an eye
magic 2,2,2,2,2,2,2,2
pretender
item 26, 37 (eye of aiming, robe of invulnerability)
Battleorders cast 13, cast 15, cast 15, flee
battlelocation -20, -20
end

unit 1001 (some standard HI with nothing special quarding commander)
location = 113
leader = 23
squad = 4
Battleorders = guard commander
battlelocation -20, -20
type = 50
end




In the same way, the .2h would have all the orders in encrypted zipped plain text.

Code:

orders:
unit 23
cast 222
battleorder cast 113, cast 114, cast.
end

unit 1001
squad 1
battleorder attack closest
battlelocation 20, 0
end

province 113
hire 50,50,50,50,50,50
hirecom 75
tax 100
end



When the host executes a command, it first uses it's own fthrland file, that has all the real info on the game, to check if the move is possible, then executes if it is or disregards until the next end if not.

This would make it impossible to cheat, other than trying to break the encryption on other player's turns, and nothing stops the game from saving different things in a turnfile all mixed up making it very hard to break the code.

This way, everyone who thinks they can do a better AI, can try... The big question there is, how much extra work would that be? I have absolutely no idea...
Reply With Quote