SetUpPunting
Playbook:
PROC []
RETURNS [] ~ {
IF puntingPlaysInit = TRUE THEN RETURN;
puntingPlays[offense][setup] ← NEW[PlayRec];
puntingPlays[defense][setup] ← NEW[PlayRec];
puntingPlays[offense][play] ← NEW[PlayRec];
puntingPlays[defense][play] ← NEW[PlayRec];
puntingPlays[offense][setup]^ ← [name: "Punt-formation", commands: [
[run, [relative[-3, 0]]], [run, [relative[-1, -8]]], [run, [relative[-1, 8]]],
[run, [relative[-1, -4]]], [run, [relative[-1, 4]]], [run, [relative[-1, 0]]]]];
puntingPlays[defense][setup]^ ← [name: "Punt-reception", commands: [
[run, [relative[-45, 0]]], [run, [relative[-1, -8]]], [run, [relative[-1, 8]]],
[run, [relative[-1, -4]]], [run, [relative[-1, 4]]], [run, [relative[-1, 0]]]]];
puntingPlays[offense][play]^ ← [name: "Punt", ball: [kick, [goal[]]], commands: [
[run, [relative[-10, 3]]], [block, [player[all]]], [block, [player[all]]],
[block, [player[all]]], [block, [player[all]]], [block, [player[all]]]]];
puntingPlays[defense][play]^ ← [name: "Punt-return", commands: [
[stop, [null[]]], [block, [player[ball]]], [block, [player[ball]]],
[run, [player[ball]]], [run, [player[ball]]], [run, [player[ball]]]]];
puntingPlaysInit ← TRUE;
};
ManualSetUpPlaybook:
PROC [myTeam: Team]
RETURNS [] ~ {
this should really read a playbook file
SetUpPuntingPlaybook[];
teamPlaybookFile[myTeam] ← "manual";
teamPlays[myTeam][offense][setup].plays[0] ← NEW[PlayRec];
teamPlays[myTeam][defense][setup].plays[0] ← NEW[PlayRec];
teamPlays[myTeam][offense][play].plays[0] ← NEW[PlayRec];
teamPlays[myTeam][offense][play].plays[1] ← NEW[PlayRec];
teamPlays[myTeam][defense][play].plays[0] ← NEW[PlayRec];
teamPlays[myTeam][defense][play].plays[1] ← NEW[PlayRec];
teamPlays[myTeam][defense][play].plays[2] ← NEW[PlayRec];
teamPlays[myTeam][defense][play].plays[3] ← NEW[PlayRec];
offensive setups
teamPlays[myTeam][offense][setup].plays[0]^ ← [name: "5-1", commands: [
[run, [relative[-3, 0]]], [run, [relative[-1, -8]]], [run, [relative[-1, 8]]],
[run, [relative[-1, -4]]], [run, [relative[-1, 4]]], [run, [relative[-1, 0]]]]];
teamPlays[myTeam][offense][setup].num ← 1;
defensive setups
teamPlays[myTeam][defense][setup].plays[0]^ ← [name: "4-2", commands: [
[run, [relative[-1, -2]]], [run, [relative[-6, -2]]], [run, [relative[-6, 2]]],
[run, [relative[-1, -6]]], [run, [relative[-1, 6]]], [run, [relative[-1, 2]]]]];
teamPlays[myTeam][defense][setup].num ← 1;
offensive plays
teamPlays[myTeam][offense][play].plays[0]^ ← [name: "UpTheMiddle", commands: [
[run, [relative[5, -4]]], [block, [player[all]]], [block, [player[all]]],
[block, [player[all]]], [block, [player[all]]], [block, [player[all]]]]];
teamPlays[myTeam][offense][play].plays[1]^ ← [name: "ShortPassTop", ball: [pass, [relative[10, 10]]], commands: [
[run, [relative[-10, 3]]], [block, [player[all]]], [run, [relative[10, 10]]],
[block, [player[all]]], [block, [player[all]]], [block, [player[all]]]]];
teamPlays[myTeam][offense][play].num ← 2;
defensive plays
teamPlays[myTeam][defense][play].plays[0]^ ← [name: "Rush", commands: [
[run, [player[ball]]], [run, [player[ball]]], [run, [player[ball]]],
[run, [player[ball]]], [run, [player[ball]]], [run, [player[ball]]]]];
teamPlays[myTeam][defense][play].plays[1]^ ← [name: "GuardEnds", commands:
IF myTeam = home
THEN [
[run, [player[ball]]], [run, [player[VLE]]], [run, [player[VRE]]],
[run, [player[ball]]], [run, [player[ball]]], [run, [player[ball]]]]
ELSE [
[run, [player[ball]]], [run, [player[HLE]]], [run, [player[HRE]]],
[run, [player[ball]]], [run, [player[ball]]], [run, [player[ball]]]]];
teamPlays[myTeam][defense][play].plays[2]^ ← [name: "ManToMan", commands:
IF myTeam = home
THEN [
[run, [player[VQB]]], [run, [player[VLE]]], [run, [player[VRE]]],
[run, [player[VLG]]], [run, [player[VRG]]], [run, [player[VC]]]]
ELSE [
[run, [player[HQB]]], [run, [player[HLE]]], [run, [player[HRE]]],
[run, [player[HLG]]], [run, [player[HRG]]], [run, [player[HC]]]]];
teamPlays[myTeam][defense][play].plays[3]^ ← [name: "Zone", commands: [
[run, [player[ball]]], [block, [relative[-10, -15]]], [block, [relative[-10, 15]]],
[run, [player[ball]]], [run, [player[ball]]], [run, [player[ball]]]]];
teamPlays[myTeam][defense][play].num ← 4;
};