This will reset the objects to the way they were at the beginning of the last combat. It doesn't work yet.
svSettingUp
This
used only
the setup phase
robots around
BUTTONDOWN loc
BEGINMOVEUNIT
BUTTONSTILLDOWN
CONTINUEMOVEUNIT
BUTTONUP
ENDMOVEUNIT
UTTONDOWN
BUTTONSTILLDOWN
BUTTONDOWN
BUTTONUP
BUTTONDOWN
HRBEGINMOVEUNIT
BUTTONSTILLDOWN
CONTINUEMOVEUNIT
BUTTONUP
ENDMOVEUNIT
pBehavior
pObjectEnergy
This
used only
the setup phase
robots around
BUTTONDOWN loc
BEGINMOVEUNIT
BUTTONSTILLDOWN
CONTINUEMOVEUNIT
BUTTONUP
ENDMOVEUNIT
UTTONDOWN
BUTTONSTILLDOWN
BUTTONDOWN
BUTTONUP
BUTTONDOWN
HRBEGINMOVEUNIT
BUTTONSTILLDOWN
CONTINUEMOVEUNIT
BUTTONUP
ENDMOVEUNIT
pBehavior
pObjectEnergy
This
used only
the setup phase
robots around
BUTTONDOWN loc
BEGINMOVEUNIT
BUTTONSTILLDOWN
CONTINUEMOVEUNIT
BUTTONUP
ENDMOVEUNIT
UTTONDOWN
BUTTONSTILLDOWN
BUTTONDOWN
BUTTONUP
BUTTONDOWN
HRBEGINMOVEUNIT
BUTTONSTILLDOWN
CONTINUEMOVEUNIT
BUTTONUP
ENDMOVEUNIT
pBehavior
pObjectEnergy
This
used only
the setup phase
robots around
BUTTONDOWN loc
BEGINMOVEUNIT
BUTTONSTILLDOWN
CONTINUEMOVEUNIT
BUTTONUP
ENDMOVEUNIT
UTTONDOWN
BUTTONSTILLDOWN
BUTTONDOWN
BUTTONUP
BUTTONDOWN
HRBEGINMOVEUNIT
BUTTONSTILLDOWN
CONTINUEMOVEUNIT
BUTTONUP
ENDMOVEUNIT
pBehavior
pObjectEnergy
This
used only
the setup phase
robots around
BUTTONDOWN loc
BEGINMOVEUNIT
BUTTONSTILLDOWN
CONTINUEMOVEUNIT
BUTTONUP
ENDMOVEUNIT
UTTONDOWN
BUTTONSTILLDOWN
BUTTONDOWN
BUTTONUP
BUTTONDOWN
HRBEGINMOVEUNIT
BUTTONSTILLDOWN
CONTINUEMOVEUNIT
BUTTONUP
ENDMOVEUNIT
pBehavior
pObjectEnergy
This
used only
the setup phase
robots around
BUTTONDOWN loc
BEGINMOVEUNIT
BUTTONSTILLDOWN
CONTINUEMOVEUNIT
BUTTONUP
ENDMOVEUNIT
UTTONDOWN
BUTTONSTILLDOWN
BUTTONDOWN
BUTTONUP
BUTTONDOWN
HRBEGINMOVEUNIT
BUTTONSTILLDOWN
CONTINUEMOVEUNIT
BUTTONUP
ENDMOVEUNIT
R"F"pBehavior
h"pObjectEnergy
`#pObjectEnergy
This
used only
the setup phase
robots around
BUTTONDOWN loc
BEGINMOVEUNIT
BUTTONSTILLDOWN
CONTINUEMOVEUNIT
BUTTONUP
ENDMOVEUNIT
UTTONDOWN
BUTTONSTILLDOWN
BUTTONDOWN
BUTTONUP
BUTTONDOWN
HRBEGINMOVEUNIT
BUTTONSTILLDOWN
CONTINUEMOVEUNIT
BUTTONUP
ENDMOVEUNIT
&pBehavior
&pObjectEnergy
This
used only
the setup phase
robots around
BUTTONDOWN loc
BEGINMOVEUNIT
BUTTONSTILLDOWN
CONTINUEMOVEUNIT
BUTTONUP
ENDMOVEUNIT
UTTONDOWN
BUTTONSTILLDOWN
BUTTONDOWN
BUTTONUP
BUTTONDOWN
HRBEGINMOVEUNIT
BUTTONSTILLDOWN
CONTINUEMOVEUNIT
BUTTONUP
ENDMOVEUNIT
*pBehavior
+pObjectEnergy
J-L/X
This
used only
the setup phase
robots around
BUTTONDOWN loc
BEGINMOVEUNIT
BUTTONSTILLDOWN
CONTINUEMOVEUNIT
BUTTONUP
ENDMOVEUNIT
UTTONDOWN
BUTTONSTILLDOWN
BUTTONDOWN
BUTTONUP
BUTTONDOWN
HRBEGINMOVEUNIT
BUTTONSTILLDOWN
CONTINUEMOVEUNIT
BUTTONUP
ENDMOVEUNIT
j/^/pBehavior
/pObjectEnergy
This
used only
the setup phase
robots around
BUTTONDOWN loc
BEGINMOVEUNIT
BUTTONSTILLDOWN
CONTINUEMOVEUNIT
BUTTONUP
ENDMOVEUNIT
UTTONDOWN
BUTTONSTILLDOWN
BUTTONDOWN
BUTTONUP
BUTTONDOWN
HRBEGINMOVEUNIT
BUTTONSTILLDOWN
CONTINUEMOVEUNIT
BUTTONUP
ENDMOVEUNIT
3pBehavior
3pObjectEnergy
tank help
BUTTONUP
"tank help"
BUTTONUP
BUTTONUP
tank help
The Game of TankWarr
This is a game of cellular automata. The cells or units in this game are tanks on a battlefield, firing at each other. There are two sides. Red and Blue. There are two phases to the game, Setup and Combat. During the Setup phase each player positions his units and defines their behavior. When the battle starts the tanks advance, firing on the enemy. The battle continues until one side has no tanks left. The purpose of this game is to let you try out various survival strategies and combat formations for your tank force.
The Units.
Each unit is a tank. At the beginning each tank has 125 units of energy. This energy is diminished each time the tank is hit. A unit also has a behavior characteristic (property, for those who have already OD'ed on ToolBook) that governs how it moves. A move consists of the following: the tank moves forward, fires at the closest enemy tank, and then moves back. The net motion on each turn is always forward, but the ratio between the two types of motion is governed by the behavior, and can be Aggressive (moves forward a lot more than back), Moderate (forward some, then back some) or Conservative (moves forward some, then back almost as much. If a unit gets to the end of the field it reverses its motion.
Shots.
Each shot starts out with 75 units of energy, but the further a shot travels the less energy it has. When its energy reaches zero it explodes harmlessly. A hit diminishes the target's energy by the amount of energy it has left.
left.
Large explosion
Small explosion
bullet
:A"@lAr
@6,-4
@"@44
YA(A8@80
@6,-4
?-8,2
A-7,3
tX<"t$<\8
jA0A-7,3
@,B-8,2
OriginalUnit
fTargetCoords
bullet
pObjectEnergy
lObjectCenter
Large explosion
INSERTKILL
lObjectCenter
Small explosion
pObjectEnergy
svBulletEnergy
svCurrentListPosition
fHitEnergy
fTarget
BEGINMOVEUNIT
svSettingUp
svOldLoc
fTarget
CONTINUEMOVEUNIT
svSettingUp
svOldLoc
fTarget
ENDMOVEUNIT
CONTINUEMOVEUNIT
SETUNITPROPERTY
svSettingUp
fTarget
SETUNITPROPERTY
Make this unit Aggressive, Moderate, Conservative
Agress
Agress
pRedUnits
pBehavior
vMoveDirection
vStartPoint
vMoves
svMoveDirection
svUnitMoves
svSettingUp
fTarget
lObjectCenter
large explosion
bullet
fExplosionObject
fPoint
INSERTKILL
svUnitList
svUnitsPerSide
svLiveRed
svLiveBlue
fObject
lObjectCenter
vObjectBounds
nearestTarget
numDistanceToTarget
vDistanceToTarget
vThisTarget
vOurTargetList
vOurTarget
svUnitsPerSide
fTargetList
fMyBounds
numDistanceToTarget
lObjectCenter
lObjectCenter
vCenter1
vCenter2
xDiff
yDiff
fBounds2
fBounds1
Battlefield Survival Strategies
ControlPanel
BUTTONUP
4svSettingUp
boolAllObjectsSetup()
PLAYGAME
}have
xbeen
%assigned behavior
4svUnitList
"dead"
pBehavior
BUTTONUP
boolAllObjectsSetup
BUTTONUP
boolAllObjectsSetup
`PLAYGAME
All objects have not been set up
svSettingUp
boolAllObjectsSetup
pBehavior
svUnitList
Combat
BUTTONUP
"tank Help"
BUTTONUP
BUTTONUP
tank Help
;**Z6
BUTTONUP
4svSettingUp
INITGAME
default
BUTTONUP
BUTTONUP
j^INITGAME
default
svSettingUp
Reset
BUTTONUP
4svSettingUp
"This will reset the
way they were
beginning
Jcombat.
It doesn't work yet."
BUTTONUP
BUTTONUP
This will reset the objects to the way they were at the beginning of the last combat. It doesn't work yet.
svSettingUp
This
used only
the setup phase
robots around
BUTTONDOWN loc
BEGINMOVEUNIT
BUTTONSTILLDOWN
CONTINUEMOVEUNIT
BUTTONUP
ENDMOVEUNIT
UTTONDOWN
BUTTONSTILLDOWN
BUTTONDOWN
BUTTONUP
BUTTONDOWN
HRBEGINMOVEUNIT
BUTTONSTILLDOWN
CONTINUEMOVEUNIT
BUTTONUP
ENDMOVEUNIT
pObjectEnergy
This
used only
the setup phase
robots around
BUTTONDOWN loc
BEGINMOVEUNIT
BUTTONSTILLDOWN
CONTINUEMOVEUNIT
BUTTONUP
ENDMOVEUNIT
UTTONDOWN
BUTTONSTILLDOWN
BUTTONDOWN
BUTTONUP
BUTTONDOWN
HRBEGINMOVEUNIT
BUTTONSTILLDOWN
CONTINUEMOVEUNIT
BUTTONUP
ENDMOVEUNIT
pObjectEnergy
This
used only
the setup phase
robots around
BUTTONDOWN loc
BEGINMOVEUNIT
BUTTONSTILLDOWN
CONTINUEMOVEUNIT
BUTTONUP
ENDMOVEUNIT
UTTONDOWN
BUTTONSTILLDOWN
BUTTONDOWN
BUTTONUP
BUTTONDOWN
HRBEGINMOVEUNIT
BUTTONSTILLDOWN
CONTINUEMOVEUNIT
BUTTONUP
ENDMOVEUNIT
pObjectEnergy
This
used only
the setup phase
robots around
BUTTONDOWN loc
BEGINMOVEUNIT
BUTTONSTILLDOWN
CONTINUEMOVEUNIT
BUTTONUP
ENDMOVEUNIT
UTTONDOWN
BUTTONSTILLDOWN
BUTTONDOWN
BUTTONUP
BUTTONDOWN
HRBEGINMOVEUNIT
BUTTONSTILLDOWN
CONTINUEMOVEUNIT
BUTTONUP
ENDMOVEUNIT
pObjectEnergy
This
used only
the setup phase
robots around
BUTTONDOWN loc
BEGINMOVEUNIT
BUTTONSTILLDOWN
CONTINUEMOVEUNIT
BUTTONUP
ENDMOVEUNIT
UTTONDOWN
BUTTONSTILLDOWN
BUTTONDOWN
BUTTONUP
BUTTONDOWN
HRBEGINMOVEUNIT
BUTTONSTILLDOWN
CONTINUEMOVEUNIT
BUTTONUP
ENDMOVEUNIT
pObjectEnergy
This
used only
the setup phase
robots around
BUTTONDOWN loc
BEGINMOVEUNIT
BUTTONSTILLDOWN
CONTINUEMOVEUNIT
BUTTONUP
ENDMOVEUNIT
UTTONDOWN
BUTTONSTILLDOWN
BUTTONDOWN
BUTTONUP
BUTTONDOWN
HRBEGINMOVEUNIT
BUTTONSTILLDOWN
CONTINUEMOVEUNIT
BUTTONUP
ENDMOVEUNIT
!pObjectEnergy
"pObjectEnergy
This
used only
the setup phase
robots around
BUTTONDOWN loc
BEGINMOVEUNIT
BUTTONSTILLDOWN
CONTINUEMOVEUNIT
BUTTONUP
ENDMOVEUNIT
UTTONDOWN
BUTTONSTILLDOWN
BUTTONDOWN
BUTTONUP
BUTTONDOWN
HRBEGINMOVEUNIT
BUTTONSTILLDOWN
CONTINUEMOVEUNIT
BUTTONUP
ENDMOVEUNIT
%pObjectEnergy
This
used only
the setup phase
robots around
BUTTONDOWN loc
BEGINMOVEUNIT
BUTTONSTILLDOWN
CONTINUEMOVEUNIT
BUTTONUP
ENDMOVEUNIT
UTTONDOWN
BUTTONSTILLDOWN
BUTTONDOWN
BUTTONUP
BUTTONDOWN
HRBEGINMOVEUNIT
BUTTONSTILLDOWN
CONTINUEMOVEUNIT
BUTTONUP
ENDMOVEUNIT
*pObjectEnergy
B,D.X
This
used only
the setup phase
robots around
BUTTONDOWN loc
BEGINMOVEUNIT
BUTTONSTILLDOWN
CONTINUEMOVEUNIT
BUTTONUP
ENDMOVEUNIT
UTTONDOWN
BUTTONSTILLDOWN
BUTTONDOWN
BUTTONUP
BUTTONDOWN
HRBEGINMOVEUNIT
BUTTONSTILLDOWN
CONTINUEMOVEUNIT
BUTTONUP
ENDMOVEUNIT
Z.pObjectEnergy
This
used only
the setup phase
robots around
BUTTONDOWN loc
BEGINMOVEUNIT
BUTTONSTILLDOWN
CONTINUEMOVEUNIT
BUTTONUP
ENDMOVEUNIT
UTTONDOWN
BUTTONSTILLDOWN
BUTTONDOWN
BUTTONUP
BUTTONDOWN
HRBEGINMOVEUNIT
BUTTONSTILLDOWN
CONTINUEMOVEUNIT
BUTTONUP
ENDMOVEUNIT
2pObjectEnergy
tank help
BUTTONUP
"tank help"
BUTTONUP
BUTTONUP
tank help
The Game of TankWarr
This is a game of cellular automata. The cells or units in this game are tanks on a battlefield, firing at each other. There are two sides. Red and Blue. There are two phases to the game, Setup and Combat. During the Setup phase each player positions his units and defines their behavior. When the battle starts the tanks advance, firing on the enemy. The battle continues until one side has no tanks left. The purpose of this game is to let you try out various survival strategies and combat formations for your tank force.
The Units.
Each unit is a tank. At the beginning each tank has 125 units of energy. This energy is diminished each time the tank is hit. A unit also has a behavior characteristic (property, for those who have already OD'ed on ToolBook) that governs how it moves. A move consists of the following: the tank moves forward, fires at the closest enemy tank, and then moves back. The net motion on each turn is always forward, but the ratio between the two types of motion is governed by the behavior, and can be Aggressive (moves forward a lot more than back), Moderate (forward some, then back some) or Conservative (moves forward some, then back almost as much. If a unit gets to the end of the field it reverses its motion.
Shots.
Each shot starts out with 75 units of energy, but the further a shot travels the less energy it has. When its energy reaches zero it explodes harmlessly. A hit diminishes the target's energy by the amount of energy it has left.
left.
Large explosion
Small explosion
bullet
pObjectEnergy
4710.5,5187.5
pObjectEnergy
4870,5382.5
pObjectEnergy
4160,5375
pObjectEnergy
4295,5367.5
Explosion
Improvements/modifications, etc.
1. Visual redesign - give the tanks eyes & a beak. Think about each tank having a little bar that shows how much energy it has left. Also it would have some way of letting you tell what its behavior is (a color patch somewhere would do nicely
2. Think about having the tanks move towards their targets, fire, & fall back. They would no linger be restricted to straight horizontal movement.
3. How can we make this look a little more interesting? Possibly we could have terrain, the tanks cannot shoot or see anything with a "Wall" in between.
This is a game of cellular automata. The cells or units in this game are tanks on a battlefield, firing at each other. There are two sides. Red and Blue. There are two phases to the game, Setup and Combat. During the Setup phase each player positions his units and defines their behavior. When the battle starts the tanks advance, firing on the enemy. The battle continues until one side has no tanks left. The purpose of this game is to let you try out various survival strategies and combat formations for your tank force.
The Units.
Each unit is a tank. At the beginning each tank has 125 units of energy. This energy is diminished each time the tank is hit. A unit also has a behavior characteristic (property, for those who have already OD'ed on ToolBook) that governs how it moves. A move consists of the following: the tank moves forward, fires at the closest enemy tank, and then moves back. The net motion on each turn is always forward, but the ratio between the two types of motion is governed by the behavior, and can be Aggressive (moves forward a lot more than back), Moderate (forward some, then back some) or Conservative (moves forward some, then back almost as much. If a unit gets to the end of the field it reverses its motion.
Shots.
Each shot starts out with 75 units of energy, but the further a shot travels the less energy it has. When its energy reaches zero it explodes harmlessly. A hit diminishes the target's energy by the amount of energy it has left.
left.
Large explosion
Small explosion
Browser
SHOWOBJECT
4svBrowseAction
"Show
"Click on
{'s ID
"Browser message"
PRINTFIELD
"Print Field"
's ID
GETOBJECTSCRIPT
"Get Script"
{'s ID
work
ADJUSTPARAMS
"Adjust Parameters"
{'s ID
CLEARBROWSERFIELDS
"Object ID"
)Bounds"
"browser
title"
INTFIELD
SHOWOBJECT
GETOBJECTSCRIPT
ADJUSTPARAMS
PRINTFIELD
CLEARBROWSERFIELDS
SHOWOBJECT
Show object
Click on an object's ID to show it
Browser message
svBrowseAction
PRINTFIELD
Print Field
Click on a field's ID to print its text
Browser message
svBrowseAction
GETOBJECTSCRIPT
Get Script
Click on an object's ID to work with its script
Browser message
svBrowseAction
ADJUSTPARAMS
Adjust Parameters
Click on an object's ID to work with its bounds
Browser message
svBrowseAction
CLEARBROWSERFIELDS
Object ID
Object name
Object properties
Object Bounds
browser message
Browser title
DJxDpBrowseHelp
This is the object browser. The four fields show the following information about the current page:
Object ID The unique id of an object is shown.
Object name If the object has a name it will appear here
Object Properties The status of the following four properties is shown here; script, visible, userProperties, and layer. The first three are Yes/No flags, the layer is by number
Object bounds The bounds of the object are shown. If an item in the list is negative, it will be surrounded by angle brackets.
The following functions are available through the buttons on the browser. They all work the same way: first click on the function button to set the mode, then click on the object's line in the Object ID field.
Get script An object's script can be printed, edited with a DOS text editor (you must set this up through the tools configuration menu first), or put into a field on the screen.
Print field The text of a field can be printed.
Show object An invisible object can be shown.
Adjust Bounds/Vertices You can adjust the size and shape of an object without ungrouping.
Other features. The black diamond in the upper right of the control panel is a move handle - click on it and you can drag the browser around. The small box in the upper left of the control panel is the go-away button, and a click there will remove the browser. The two black triangles over the bounds field are scroll buttons for all four fields.