| Line |   | 
|---|
| 1 | -- Global Variables | 
|---|
| 2 | panic = false             -- True if thestranger panics. | 
|---|
| 3 | walkingRouteOne = false   -- True if thestranger is walking route one | 
|---|
| 4 |  | 
|---|
| 5 |  | 
|---|
| 6 | function togglePanic(timestep) | 
|---|
| 7 | panic = not panic | 
|---|
| 8 | return false | 
|---|
| 9 | end | 
|---|
| 10 |  | 
|---|
| 11 |  | 
|---|
| 12 | function walkRouteOne() | 
|---|
| 13 |  | 
|---|
| 14 |  | 
|---|
| 15 | end | 
|---|
| 16 |  | 
|---|
| 17 | function flee() | 
|---|
| 18 |  | 
|---|
| 19 |  | 
|---|
| 20 | end | 
|---|
| 21 |  | 
|---|
| 22 |  | 
|---|
| 23 | function tick(timestep) | 
|---|
| 24 |  | 
|---|
| 25 | if not walkingRouteOne then | 
|---|
| 26 | walkRouteOne() | 
|---|
| 27 | routeOneTriggered = true | 
|---|
| 28 | end | 
|---|
| 29 |  | 
|---|
| 30 | if panic then | 
|---|
| 31 | flee(timestep) | 
|---|
| 32 | end | 
|---|
| 33 |  | 
|---|
| 34 |  | 
|---|
| 35 | return false | 
|---|
| 36 | end | 
|---|
       
      
      Note: See 
TracBrowser
        for help on using the repository browser.