home *** CD-ROM | disk | FTP | other *** search
Unknown | 1999-11-02 | 7.1 KB |
view JSON data
|
view as text
|
open on a Mac
|
open on a PC
This file was not able to be converted.
This format is not currently supported by dexvert.
Confidence | Program | Detection | Match Type | Support
|
---|
100%
| file
| data
| default
|
|
hex view+--------+-------------------------+-------------------------+--------+--------+
|00000000| 00 00 00 00 00 00 00 00 | 53 71 2f 2f 3d 3d 3d 3d |........|Sq//====|
|00000010| 3d 3d 3d 3d 3d 3d 3d 3d | 3d 3d 3d 3d 3d 3d 3d 3d |========|========|
|00000020| 3d 3d 3d 3d 3d 3d 3d 3d | 3d 3d 3d 3d 3d 3d 3d 3d |========|========|
|00000030| 3d 3d 3d 3d 3d 3d 3d 3d | 3d 3d 3d 3d 3d 3d 3d 3d |========|========|
|00000040| 3d 3d 3d 3d 3d 3d 3d 3d | 3d 3d 3d 3d 3d 3d 3d 3d |========|========|
|00000050| 3d 3d 3d 3d 3d 3d 3d 3d | 3d 0d 0a 2f 2f 20 57 61 |========|=..// Wa|
|00000060| 79 70 6f 69 6e 74 53 65 | 6c 65 63 74 6f 72 41 70 |ypointSe|lectorAp|
|00000070| 70 72 6f 61 63 68 69 6e | 67 2e 0d 0a 2f 2f 20 24 |proachin|g...// $|
|00000080| 41 75 74 68 6f 72 3a 20 | 4d 66 6f 78 20 24 0d 0a |Author: |Mfox $..|
|00000090| 2f 2f 20 24 44 61 74 65 | 3a 20 31 30 2f 32 36 2f |// $Date|: 10/26/|
|000000a0| 39 39 20 35 3a 33 38 70 | 20 24 0d 0a 2f 2f 20 24 |99 5:38p| $..// $|
|000000b0| 52 65 76 69 73 69 6f 6e | 3a 20 31 20 24 0d 0a 2f |Revision|: 1 $../|
|000000c0| 2f 3d 3d 3d 3d 3d 3d 3d | 3d 3d 3d 3d 3d 3d 3d 3d |/=======|========|
|000000d0| 3d 3d 3d 3d 3d 3d 3d 3d | 3d 3d 3d 3d 3d 3d 3d 3d |========|========|
|000000e0| 3d 3d 3d 3d 3d 3d 3d 3d | 3d 3d 3d 3d 3d 3d 3d 3d |========|========|
|000000f0| 3d 3d 3d 3d 3d 3d 3d 3d | 3d 3d 3d 3d 3d 3d 3d 3d |========|========|
|00000100| 3d 3d 3d 3d 3d 3d 3d 3d | 3d 3d 3d 3d 3d 3d 0d 0a |========|======..|
|00000110| 0d 0a 63 6c 61 73 73 20 | 57 61 79 70 6f 69 6e 74 |..class |Waypoint|
|00000120| 53 65 6c 65 63 74 6f 72 | 41 70 70 72 6f 61 63 68 |Selector|Approach|
|00000130| 69 6e 67 20 65 78 70 61 | 6e 64 73 20 57 61 79 70 |ing expa|nds Wayp|
|00000140| 6f 69 6e 74 53 65 6c 65 | 63 74 6f 72 3b 0d 0a 0d |ointSele|ctor;...|
|00000150| 0a 76 61 72 20 28 29 20 | 66 6c 6f 61 74 20 41 6e |.var () |float An|
|00000160| 74 69 63 69 70 61 74 65 | 64 54 72 61 76 65 6c 44 |ticipate|dTravelD|
|00000170| 69 73 74 61 6e 63 65 3b | 0d 0a 76 61 72 20 28 29 |istance;|..var ()|
|00000180| 20 66 6c 6f 61 74 20 4d | 69 6e 4f 66 66 73 65 74 | float M|inOffset|
|00000190| 44 69 73 74 61 6e 63 65 | 3b 0d 0a 76 61 72 20 28 |Distance|;..var (|
|000001a0| 29 20 66 6c 6f 61 74 20 | 4d 61 78 4f 66 66 73 65 |) float |MaxOffse|
|000001b0| 74 44 69 73 74 61 6e 63 | 65 3b 0d 0a 0d 0a 0d 0a |tDistanc|e;......|
|000001c0| 73 74 61 74 69 63 20 66 | 75 6e 63 74 69 6f 6e 20 |static f|unction |
|000001d0| 62 6f 6f 6c 20 47 65 74 | 4d 6f 76 65 6d 65 6e 74 |bool Get|Movement|
|000001e0| 44 65 73 74 69 6e 61 74 | 69 6f 6e 28 20 47 6f 61 |Destinat|ion( Goa|
|000001f0| 6c 41 62 73 74 72 61 63 | 74 65 72 49 6e 74 65 72 |lAbstrac|terInter|
|00000200| 66 20 4d 6f 76 65 6d 65 | 6e 74 47 6f 61 6c 2c 0d |f Moveme|ntGoal,.|
|00000210| 0a 09 09 41 63 74 6f 72 | 20 4d 6f 76 69 6e 67 41 |...Actor| MovingA|
|00000220| 63 74 6f 72 2c 0d 0a 09 | 09 42 65 68 61 76 69 6f |ctor,...|.Behavio|
|00000230| 72 43 6f 6e 73 74 72 61 | 69 6e 65 72 20 43 6f 6e |rConstra|iner Con|
|00000240| 73 74 72 61 69 6e 65 72 | 2c 0d 0a 09 09 47 6f 61 |strainer|,....Goa|
|00000250| 6c 41 62 73 74 72 61 63 | 74 65 72 49 6e 74 65 72 |lAbstrac|terInter|
|00000260| 66 20 47 6f 61 6c 20 29 | 0d 0a 7b 0d 0a 09 6c 6f |f Goal )|..{...lo|
|00000270| 63 61 6c 20 62 6f 6f 6c | 20 62 47 6f 74 44 65 73 |cal bool| bGotDes|
|00000280| 74 69 6e 61 74 69 6f 6e | 3b 0d 0a 09 6c 6f 63 61 |tination|;...loca|
|00000290| 6c 20 56 65 63 74 6f 72 | 20 47 6f 61 6c 4c 6f 63 |l Vector| GoalLoc|
|000002a0| 61 74 69 6f 6e 3b 0d 0a | 09 63 6c 61 73 73 27 44 |ation;..|.class'D|
|000002b0| 65 62 75 67 27 2e 73 74 | 61 74 69 63 2e 44 65 62 |ebug'.st|atic.Deb|
|000002c0| 75 67 4c 6f 67 28 20 4d | 6f 76 69 6e 67 41 63 74 |ugLog( M|ovingAct|
|000002d0| 6f 72 2c 20 22 47 65 74 | 4d 6f 76 65 6d 65 6e 74 |or, "Get|Movement|
|000002e0| 44 65 73 74 69 6e 61 74 | 69 6f 6e 22 2c 20 27 57 |Destinat|ion", 'W|
|000002f0| 61 79 70 6f 69 6e 74 53 | 65 6c 65 63 74 6f 72 41 |aypointS|electorA|
|00000300| 70 70 72 6f 61 63 68 69 | 6e 67 27 20 29 3b 0d 0a |pproachi|ng' );..|
|00000310| 09 2f 2f 72 65 74 75 72 | 6e 20 47 65 74 4d 6f 76 |.//retur|n GetMov|
|00000320| 65 6d 65 6e 74 44 65 73 | 74 69 6e 61 74 69 6f 6e |ementDes|tination|
|00000330| 32 28 20 4d 6f 76 65 6d | 65 6e 74 47 6f 61 6c 2c |2( Movem|entGoal,|
|00000340| 20 4d 6f 76 69 6e 67 41 | 63 74 6f 72 2c 20 43 6f | MovingA|ctor, Co|
|00000350| 6e 73 74 72 61 69 6e 65 | 72 2c 20 47 6f 61 6c 20 |nstraine|r, Goal |
|00000360| 29 3b 0d 0a 09 69 66 28 | 20 47 6f 61 6c 2e 47 65 |);...if(| Goal.Ge|
|00000370| 74 47 6f 61 6c 4c 6f 63 | 61 74 69 6f 6e 28 20 4d |tGoalLoc|ation( M|
|00000380| 6f 76 69 6e 67 41 63 74 | 6f 72 2c 20 47 6f 61 6c |ovingAct|or, Goal|
|00000390| 4c 6f 63 61 74 69 6f 6e | 20 29 20 29 0d 0a 09 7b |Location| ) )...{|
|000003a0| 0d 0a 09 09 62 47 6f 74 | 44 65 73 74 69 6e 61 74 |....bGot|Destinat|
|000003b0| 69 6f 6e 20 3d 20 53 65 | 6c 65 63 74 54 72 61 63 |ion = Se|lectTrac|
|000003c0| 65 57 61 79 70 6f 69 6e | 74 28 20 4d 6f 76 65 6d |eWaypoin|t( Movem|
|000003d0| 65 6e 74 47 6f 61 6c 2c | 20 4d 6f 76 69 6e 67 41 |entGoal,| MovingA|
|000003e0| 63 74 6f 72 2c 20 47 6f | 61 6c 4c 6f 63 61 74 69 |ctor, Go|alLocati|
|000003f0| 6f 6e 20 29 3b 0d 0a 09 | 7d 0d 0a 09 63 6c 61 73 |on );...|}...clas|
|00000400| 73 27 44 65 62 75 67 27 | 2e 73 74 61 74 69 63 2e |s'Debug'|.static.|
|00000410| 44 65 62 75 67 4c 6f 67 | 28 20 4d 6f 76 69 6e 67 |DebugLog|( Moving|
|00000420| 41 63 74 6f 72 2c 20 22 | 47 65 74 4d 6f 76 65 6d |Actor, "|GetMovem|
|00000430| 65 6e 74 44 65 73 74 69 | 6e 61 74 69 6f 6e 20 72 |entDesti|nation r|
|00000440| 65 74 75 72 69 6e 67 20 | 22 20 24 20 62 47 6f 74 |eturing |" $ bGot|
|00000450| 44 65 73 74 69 6e 61 74 | 69 6f 6e 2c 20 27 57 61 |Destinat|ion, 'Wa|
|00000460| 79 70 6f 69 6e 74 53 65 | 6c 65 63 74 6f 72 41 70 |ypointSe|lectorAp|
|00000470| 70 72 6f 61 63 68 69 6e | 67 27 20 29 3b 0d 0a 09 |proachin|g' );...|
|00000480| 72 65 74 75 72 6e 20 62 | 47 6f 74 44 65 73 74 69 |return b|GotDesti|
|00000490| 6e 61 74 69 6f 6e 3b 0d | 0a 7d 0d 0a 0d 0a 0d 0a |nation;.|.}......|
|000004a0| 0d 0a 73 74 61 74 69 63 | 20 66 75 6e 63 74 69 6f |..static| functio|
|000004b0| 6e 20 62 6f 6f 6c 20 53 | 65 6c 65 63 74 54 72 61 |n bool S|electTra|
|000004c0| 63 65 57 61 79 70 6f 69 | 6e 74 28 20 47 6f 61 6c |ceWaypoi|nt( Goal|
|000004d0| 41 62 73 74 72 61 63 74 | 65 72 49 6e 74 65 72 66 |Abstract|erInterf|
|000004e0| 20 4d 6f 76 65 6d 65 6e | 74 47 6f 61 6c 2c 20 41 | Movemen|tGoal, A|
|000004f0| 63 74 6f 72 20 4d 6f 76 | 69 6e 67 41 63 74 6f 72 |ctor Mov|ingActor|
|00000500| 2c 20 56 65 63 74 6f 72 | 20 47 6f 61 6c 4c 6f 63 |, Vector| GoalLoc|
|00000510| 61 74 69 6f 6e 20 29 0d | 0a 7b 0d 0a 09 6c 6f 63 |ation ).|.{...loc|
|00000520| 61 6c 20 62 6f 6f 6c 20 | 62 53 65 6c 65 63 74 54 |al bool |bSelectT|
|00000530| 72 61 63 65 57 61 79 70 | 6f 69 6e 74 3b 0d 0a 09 |raceWayp|oint;...|
|00000540| 6c 6f 63 61 6c 20 56 65 | 63 74 6f 72 20 47 6f 61 |local Ve|ctor Goa|
|00000550| 6c 44 69 72 65 63 74 69 | 6f 6e 2c 20 47 6f 61 6c |lDirecti|on, Goal|
|00000560| 56 65 63 74 6f 72 2c 20 | 49 6e 74 65 6e 64 65 64 |Vector, |Intended|
|00000570| 44 65 73 74 69 6e 61 74 | 69 6f 6e 2c 20 4f 66 66 |Destinat|ion, Off|
|00000580| 73 65 74 41 6e 63 68 6f | 72 3b 0d 0a 09 6c 6f 63 |setAncho|r;...loc|
|00000590| 61 6c 20 66 6c 6f 61 74 | 20 54 72 61 63 65 44 69 |al float| TraceDi|
|000005a0| 73 74 61 6e 63 65 2c 20 | 54 72 61 63 65 45 6e 64 |stance, |TraceEnd|
|000005b0| 48 65 69 67 68 74 41 64 | 6a 75 73 74 2c 20 4f 66 |HeightAd|just, Of|
|000005c0| 66 73 65 74 44 69 73 74 | 61 6e 63 65 2c 20 44 65 |fsetDist|ance, De|
|000005d0| 6c 74 61 5a 2c 20 50 72 | 6f 6a 65 63 74 65 64 44 |ltaZ, Pr|ojectedD|
|000005e0| 69 73 74 61 6e 63 65 3b | 0d 0a 09 6c 6f 63 61 6c |istance;|...local|
|000005f0| 20 69 6e 74 20 49 74 65 | 72 3b 0d 0a 09 0d 0a 09 | int Ite|r;......|
|00000600| 47 6f 61 6c 56 65 63 74 | 6f 72 20 3d 20 47 6f 61 |GoalVect|or = Goa|
|00000610| 6c 4c 6f 63 61 74 69 6f | 6e 20 2d 20 4d 6f 76 69 |lLocatio|n - Movi|
|00000620| 6e 67 41 63 74 6f 72 2e | 4c 6f 63 61 74 69 6f 6e |ngActor.|Location|
|00000630| 3b 0d 0a 09 44 65 6c 74 | 61 5a 20 3d 20 47 6f 61 |;...Delt|aZ = Goa|
|00000640| 6c 56 65 63 74 6f 72 2e | 5a 3b 0d 0a 09 47 6f 61 |lVector.|Z;...Goa|
|00000650| 6c 56 65 63 74 6f 72 2e | 5a 20 3d 20 30 3b 0d 0a |lVector.|Z = 0;..|
|00000660| 09 50 72 6f 6a 65 63 74 | 65 64 44 69 73 74 61 6e |.Project|edDistan|
|00000670| 63 65 20 3d 20 56 53 69 | 7a 65 28 20 47 6f 61 6c |ce = VSi|ze( Goal|
|00000680| 56 65 63 74 6f 72 20 29 | 3b 0d 0a 09 0d 0a 09 69 |Vector )|;......i|
|00000690| 66 28 20 44 65 6c 74 61 | 5a 20 3e 3d 20 50 72 6f |f( Delta|Z >= Pro|
|000006a0| 6a 65 63 74 65 64 44 69 | 73 74 61 6e 63 65 20 29 |jectedDi|stance )|
|000006b0| 0d 0a 09 7b 0d 0a 09 09 | 2f 2f 67 72 65 61 74 65 |...{....|//greate|
|000006c0| 72 20 74 68 61 6e 20 61 | 20 34 35 20 64 65 67 72 |r than a| 45 degr|
|000006d0| 65 65 20 61 6e 67 6c 65 | 0d 0a 09 09 2f 2f 66 6f |ee angle|....//fo|
|000006e0| 72 63 65 20 74 6f 20 61 | 20 6d 61 78 20 6f 66 20 |rce to a| max of |
|000006f0| 34 35 20 64 65 67 72 65 | 65 73 0d 0a 09 09 47 6f |45 degre|es....Go|
|00000700| 61 6c 56 65 63 74 6f 72 | 2e 5a 20 3d 20 50 72 6f |alVector|.Z = Pro|
|00000710| 6a 65 63 74 65 64 44 69 | 73 74 61 6e 63 65 3b 0d |jectedDi|stance;.|
|00000720| 0a 09 09 54 72 61 63 65 | 44 69 73 74 61 6e 63 65 |...Trace|Distance|
|00000730| 20 3d 20 53 71 72 74 28 | 20 28 20 64 65 66 61 75 | = Sqrt(| ( defau|
|00000740| 6c 74 2e 41 6e 74 69 63 | 69 70 61 74 65 64 54 72 |lt.Antic|ipatedTr|
|00000750| 61 76 65 6c 44 69 73 74 | 61 6e 63 65 20 2a 20 64 |avelDist|ance * d|
|00000760| 65 66 61 75 6c 74 2e 41 | 6e 74 69 63 69 70 61 74 |efault.A|nticipat|
|00000770| 65 64 54 72 61 76 65 6c | 44 69 73 74 61 6e 63 65 |edTravel|Distance|
|00000780| 20 29 20 2b 0d 0a 09 09 | 09 09 28 20 64 65 66 61 | ) +....|..( defa|
|00000790| 75 6c 74 2e 41 6e 74 69 | 63 69 70 61 74 65 64 54 |ult.Anti|cipatedT|
|000007a0| 72 61 76 65 6c 44 69 73 | 74 61 6e 63 65 2a 20 64 |ravelDis|tance* d|
|000007b0| 65 66 61 75 6c 74 2e 41 | 6e 74 69 63 69 70 61 74 |efault.A|nticipat|
|000007c0| 65 64 54 72 61 76 65 6c | 44 69 73 74 61 6e 63 65 |edTravel|Distance|
|000007d0| 20 29 20 29 3b 0d 0a 09 | 7d 0d 0a 09 65 6c 73 65 | ) );...|}...else|
|000007e0| 0d 0a 09 7b 0d 0a 09 09 | 2f 2f 6c 65 73 73 20 74 |...{....|//less t|
|000007f0| 68 61 6e 20 61 20 34 35 | 20 64 65 67 72 65 65 20 |han a 45| degree |
|00000800| 61 6e 67 6c 65 20 28 74 | 68 61 74 73 20 67 72 6f |angle (t|hats gro|
|00000810| 6f 76 79 29 0d 0a 09 09 | 47 6f 61 6c 56 65 63 74 |ovy)....|GoalVect|
|00000820| 6f 72 2e 5a 20 3d 20 44 | 65 6c 74 61 5a 3b 0d 0a |or.Z = D|eltaZ;..|
|00000830| 09 09 54 72 61 63 65 44 | 69 73 74 61 6e 63 65 20 |..TraceD|istance |
|00000840| 3d 20 64 65 66 61 75 6c | 74 2e 41 6e 74 69 63 69 |= defaul|t.Antici|
|00000850| 70 61 74 65 64 54 72 61 | 76 65 6c 44 69 73 74 61 |patedTra|velDista|
|00000860| 6e 63 65 20 2f 20 43 6f | 73 28 20 41 74 61 6e 28 |nce / Co|s( Atan(|
|00000870| 20 44 65 6c 74 61 5a 20 | 2f 20 50 72 6f 6a 65 63 | DeltaZ |/ Projec|
|00000880| 74 65 64 44 69 73 74 61 | 6e 63 65 20 29 20 29 3b |tedDista|nce ) );|
|00000890| 0d 0a 09 7d 0d 0a 09 09 | 0d 0a 09 47 6f 61 6c 44 |...}....|...GoalD|
|000008a0| 69 72 65 63 74 69 6f 6e | 20 3d 20 4e 6f 72 6d 61 |irection| = Norma|
|000008b0| 6c 28 20 47 6f 61 6c 56 | 65 63 74 6f 72 20 29 3b |l( GoalV|ector );|
|000008c0| 0d 0a 09 4f 66 66 73 65 | 74 41 6e 63 68 6f 72 20 |...Offse|tAnchor |
|000008d0| 3d 20 28 20 47 6f 61 6c | 44 69 72 65 63 74 69 6f |= ( Goal|Directio|
|000008e0| 6e 20 43 72 6f 73 73 20 | 76 65 63 74 28 20 30 2c |n Cross |vect( 0,|
|000008f0| 20 30 2c 20 31 20 29 20 | 29 3b 0d 0a 09 61 73 73 | 0, 1 ) |);...ass|
|00000900| 65 72 74 28 20 4f 66 66 | 73 65 74 41 6e 63 68 6f |ert( Off|setAncho|
|00000910| 72 2e 5a 20 3d 3d 20 30 | 20 29 3b 0d 0a 09 0d 0a |r.Z == 0| );.....|
|00000920| 09 54 72 61 63 65 45 6e | 64 48 65 69 67 68 74 41 |.TraceEn|dHeightA|
|00000930| 64 6a 75 73 74 20 3d 20 | 28 20 41 62 73 28 20 47 |djust = |( Abs( G|
|00000940| 6f 61 6c 56 65 63 74 6f | 72 2e 5a 20 29 20 2b 20 |oalVecto|r.Z ) + |
|00000950| 32 20 2a 20 4d 6f 76 69 | 6e 67 41 63 74 6f 72 2e |2 * Movi|ngActor.|
|00000960| 43 6f 6c 6c 69 73 69 6f | 6e 48 65 69 67 68 74 20 |Collisio|nHeight |
|00000970| 29 3b 0d 0a 09 4f 66 66 | 73 65 74 44 69 73 74 61 |);...Off|setDista|
|00000980| 6e 63 65 20 3d 20 4d 6f | 76 69 6e 67 41 63 74 6f |nce = Mo|vingActo|
|00000990| 72 2e 52 61 6e 64 52 61 | 6e 67 65 28 20 64 65 66 |r.RandRa|nge( def|
|000009a0| 61 75 6c 74 2e 4d 69 6e | 4f 66 66 73 65 74 44 69 |ault.Min|OffsetDi|
|000009b0| 73 74 61 6e 63 65 2c 20 | 64 65 66 61 75 6c 74 2e |stance, |default.|
|000009c0| 4d 61 78 4f 66 66 73 65 | 74 44 69 73 74 61 6e 63 |MaxOffse|tDistanc|
|000009d0| 65 20 29 3b 0d 0a 09 0d | 0a 09 66 6f 72 28 20 49 |e );....|..for( I|
|000009e0| 74 65 72 20 3d 20 30 3b | 20 49 74 65 72 20 3c 20 |ter = 0;| Iter < |
|000009f0| 33 3b 20 49 74 65 72 2b | 2b 20 29 0d 0a 09 7b 0d |3; Iter+|+ )...{.|
|00000a00| 0a 09 09 73 77 69 74 63 | 68 28 20 49 74 65 72 20 |...switc|h( Iter |
|00000a10| 29 0d 0a 09 09 7b 0d 0a | 09 09 09 63 61 73 65 20 |)....{..|...case |
|00000a20| 30 3a 0d 0a 09 09 09 09 | 2f 2f 74 72 79 20 74 6f |0:......|//try to|
|00000a30| 20 67 6f 20 73 74 72 61 | 69 67 68 74 20 74 6f 77 | go stra|ight tow|
|00000a40| 61 72 64 73 20 74 68 65 | 20 67 6f 61 6c 0d 0a 09 |ards the| goal...|
|00000a50| 09 09 09 49 6e 74 65 6e | 64 65 64 44 65 73 74 69 |...Inten|dedDesti|
|00000a60| 6e 61 74 69 6f 6e 20 3d | 20 4d 6f 76 69 6e 67 41 |nation =| MovingA|
|00000a70| 63 74 6f 72 2e 4c 6f 63 | 61 74 69 6f 6e 20 2b 20 |ctor.Loc|ation + |
|00000a80| 47 6f 61 6c 44 69 72 65 | 63 74 69 6f 6e 20 2a 20 |GoalDire|ction * |
|00000a90| 54 72 61 63 65 44 69 73 | 74 61 6e 63 65 3b 0d 0a |TraceDis|tance;..|
|00000aa0| 09 09 09 09 62 72 65 61 | 6b 3b 0d 0a 09 09 09 63 |....brea|k;.....c|
|00000ab0| 61 73 65 20 31 3a 0d 0a | 09 09 09 63 61 73 65 20 |ase 1:..|...case |
|00000ac0| 32 3a 0d 0a 09 09 09 09 | 49 6e 74 65 6e 64 65 64 |2:......|Intended|
|00000ad0| 44 65 73 74 69 6e 61 74 | 69 6f 6e 20 3d 20 4d 6f |Destinat|ion = Mo|
|00000ae0| 76 69 6e 67 41 63 74 6f | 72 2e 4c 6f 63 61 74 69 |vingActo|r.Locati|
|00000af0| 6f 6e 20 2b 20 28 20 4f | 66 66 73 65 74 41 6e 63 |on + ( O|ffsetAnc|
|00000b00| 68 6f 72 20 2a 20 4f 66 | 66 73 65 74 44 69 73 74 |hor * Of|fsetDist|
|00000b10| 61 6e 63 65 20 29 20 2b | 20 28 20 47 6f 61 6c 44 |ance ) +| ( GoalD|
|00000b20| 69 72 65 63 74 69 6f 6e | 20 2a 20 54 72 61 63 65 |irection| * Trace|
|00000b30| 44 69 73 74 61 6e 63 65 | 20 29 3b 0d 0a 09 09 09 |Distance| );.....|
|00000b40| 09 4f 66 66 73 65 74 44 | 69 73 74 61 6e 63 65 20 |.OffsetD|istance |
|00000b50| 2a 3d 20 2d 31 3b 0d 0a | 09 09 09 09 62 72 65 61 |*= -1;..|....brea|
|00000b60| 6b 3b 0d 0a 09 09 09 64 | 65 66 61 75 6c 74 3a 0d |k;.....d|efault:.|
|00000b70| 0a 09 09 09 09 61 73 73 | 65 72 74 28 20 66 61 6c |.....ass|ert( fal|
|00000b80| 73 65 20 29 3b 0d 0a 09 | 09 09 09 62 72 65 61 6b |se );...|...break|
|00000b90| 3b 0d 0a 09 09 7d 0d 0a | 09 09 0d 0a 09 09 2f 2f |;....}..|......//|
|00000ba0| 4d 6f 76 69 6e 67 41 63 | 74 6f 72 2e 44 4d 28 20 |MovingAc|tor.DM( |
|00000bb0| 4d 6f 76 69 6e 67 41 63 | 74 6f 72 20 24 20 22 53 |MovingAc|tor $ "S|
|00000bc0| 65 6c 65 63 74 54 72 61 | 63 65 57 61 79 70 6f 69 |electTra|ceWaypoi|
|00000bd0| 6e 74 20 49 74 65 72 20 | 22 20 24 20 49 74 65 72 |nt Iter |" $ Iter|
|00000be0| 20 29 3b 0d 0a 09 09 69 | 66 28 20 44 6f 54 72 61 | );....i|f( DoTra|
|00000bf0| 63 65 53 74 75 66 66 28 | 20 4d 6f 76 65 6d 65 6e |ceStuff(| Movemen|
|00000c00| 74 47 6f 61 6c 2c 20 4d | 6f 76 69 6e 67 41 63 74 |tGoal, M|ovingAct|
|00000c10| 6f 72 2c 20 49 6e 74 65 | 6e 64 65 64 44 65 73 74 |or, Inte|ndedDest|
|00000c20| 69 6e 61 74 69 6f 6e 2c | 20 54 72 61 63 65 45 6e |ination,| TraceEn|
|00000c30| 64 48 65 69 67 68 74 41 | 64 6a 75 73 74 20 29 20 |dHeightA|djust ) |
|00000c40| 29 0d 0a 09 09 7b 0d 0a | 09 09 09 62 53 65 6c 65 |)....{..|...bSele|
|00000c50| 63 74 54 72 61 63 65 57 | 61 79 70 6f 69 6e 74 20 |ctTraceW|aypoint |
|00000c60| 3d 20 74 72 75 65 3b 0d | 0a 09 09 09 62 72 65 61 |= true;.|....brea|
|00000c70| 6b 3b 0d 0a 09 09 7d 0d | 0a 09 7d 0d 0a 09 0d 0a |k;....}.|..}.....|
|00000c80| 09 72 65 74 75 72 6e 20 | 62 53 65 6c 65 63 74 54 |.return |bSelectT|
|00000c90| 72 61 63 65 57 61 79 70 | 6f 69 6e 74 3b 0d 0a 7d |raceWayp|oint;..}|
|00000ca0| 0d 0a 0d 0a 0d 0a 0d 0a | 73 74 61 74 69 63 20 66 |........|static f|
|00000cb0| 75 6e 63 74 69 6f 6e 20 | 62 6f 6f 6c 20 44 6f 54 |unction |bool DoT|
|00000cc0| 72 61 63 65 53 74 75 66 | 66 28 20 47 6f 61 6c 41 |raceStuf|f( GoalA|
|00000cd0| 62 73 74 72 61 63 74 65 | 72 49 6e 74 65 72 66 20 |bstracte|rInterf |
|00000ce0| 4d 6f 76 65 6d 65 6e 74 | 47 6f 61 6c 2c 20 41 63 |Movement|Goal, Ac|
|00000cf0| 74 6f 72 20 4d 6f 76 69 | 6e 67 41 63 74 6f 72 2c |tor Movi|ngActor,|
|00000d00| 20 56 65 63 74 6f 72 20 | 49 6e 74 65 6e 64 65 64 | Vector |Intended|
|00000d10| 44 65 73 74 69 6e 61 74 | 69 6f 6e 2c 20 66 6c 6f |Destinat|ion, flo|
|00000d20| 61 74 20 54 72 61 63 65 | 45 6e 64 48 65 69 67 68 |at Trace|EndHeigh|
|00000d30| 74 41 64 6a 75 73 74 20 | 29 0d 0a 7b 0d 0a 09 6c |tAdjust |)..{...l|
|00000d40| 6f 63 61 6c 20 62 6f 6f | 6c 20 62 47 6f 74 44 65 |ocal boo|l bGotDe|
|00000d50| 73 74 69 6e 61 74 69 6f | 6e 3b 0d 0a 09 6c 6f 63 |stinatio|n;...loc|
|00000d60| 61 6c 20 56 65 63 74 6f | 72 20 54 72 61 63 65 48 |al Vecto|r TraceH|
|00000d70| 69 74 4c 6f 63 61 74 69 | 6f 6e 2c 20 54 72 61 63 |itLocati|on, Trac|
|00000d80| 65 48 69 74 4e 6f 72 6d | 61 6c 2c 20 54 72 61 63 |eHitNorm|al, Trac|
|00000d90| 65 45 78 74 65 6e 74 2c | 20 54 72 61 63 65 45 6e |eExtent,| TraceEn|
|00000da0| 64 3b 0d 0a 09 6c 6f 63 | 61 6c 20 41 63 74 6f 72 |d;...loc|al Actor|
|00000db0| 20 54 72 61 63 65 48 69 | 74 41 63 74 6f 72 3b 0d | TraceHi|tActor;.|
|00000dc0| 0a 09 0d 0a 09 54 72 61 | 63 65 45 78 74 65 6e 74 |.....Tra|ceExtent|
|00000dd0| 2e 58 20 3d 20 4d 6f 76 | 69 6e 67 41 63 74 6f 72 |.X = Mov|ingActor|
|00000de0| 2e 43 6f 6c 6c 69 73 69 | 6f 6e 52 61 64 69 75 73 |.Collisi|onRadius|
|00000df0| 3b 0d 0a 09 54 72 61 63 | 65 45 78 74 65 6e 74 2e |;...Trac|eExtent.|
|00000e00| 59 20 3d 20 4d 6f 76 69 | 6e 67 41 63 74 6f 72 2e |Y = Movi|ngActor.|
|00000e10| 43 6f 6c 6c 69 73 69 6f | 6e 52 61 64 69 75 73 3b |Collisio|nRadius;|
|00000e20| 0d 0a 09 2f 2f 54 72 61 | 63 65 45 78 74 65 6e 74 |...//Tra|ceExtent|
|00000e30| 2e 5a 20 3d 20 46 4d 61 | 78 28 20 36 2c 20 4d 6f |.Z = FMa|x( 6, Mo|
|00000e40| 76 69 6e 67 41 63 74 6f | 72 2e 43 6f 6c 6c 69 73 |vingActo|r.Collis|
|00000e50| 69 6f 6e 48 65 69 67 68 | 74 20 2d 20 31 38 20 29 |ionHeigh|t - 18 )|
|00000e60| 3b 0d 0a 0d 0a 09 54 72 | 61 63 65 45 6e 64 20 3d |;.....Tr|aceEnd =|
|00000e70| 20 49 6e 74 65 6e 64 65 | 64 44 65 73 74 69 6e 61 | Intende|dDestina|
|00000e80| 74 69 6f 6e 3b 0d 0a 09 | 54 72 61 63 65 48 69 74 |tion;...|TraceHit|
|00000e90| 41 63 74 6f 72 20 3d 20 | 4d 6f 76 69 6e 67 41 63 |Actor = |MovingAc|
|00000ea0| 74 6f 72 2e 54 72 61 63 | 65 28 20 54 72 61 63 65 |tor.Trac|e( Trace|
|00000eb0| 48 69 74 4c 6f 63 61 74 | 69 6f 6e 2c 20 54 72 61 |HitLocat|ion, Tra|
|00000ec0| 63 65 48 69 74 4e 6f 72 | 6d 61 6c 2c 20 54 72 61 |ceHitNor|mal, Tra|
|00000ed0| 63 65 45 6e 64 2c 20 4d | 6f 76 69 6e 67 41 63 74 |ceEnd, M|ovingAct|
|00000ee0| 6f 72 2e 4c 6f 63 61 74 | 69 6f 6e 2c 20 66 61 6c |or.Locat|ion, fal|
|00000ef0| 73 65 2c 20 54 72 61 63 | 65 45 78 74 65 6e 74 20 |se, Trac|eExtent |
|00000f00| 29 3b 0d 0a 09 2f 2f 54 | 72 61 63 65 48 69 74 41 |);...//T|raceHitA|
|00000f10| 63 74 6f 72 20 3d 20 63 | 6c 61 73 73 27 55 74 69 |ctor = c|lass'Uti|
|00000f20| 6c 27 2e 73 74 61 74 69 | 63 2e 56 69 73 69 62 6c |l'.stati|c.Visibl|
|00000f30| 65 54 72 61 63 65 28 20 | 4d 6f 76 69 6e 67 41 63 |eTrace( |MovingAc|
|00000f40| 74 6f 72 2c 20 54 72 61 | 63 65 48 69 74 4c 6f 63 |tor, Tra|ceHitLoc|
|00000f50| 61 74 69 6f 6e 2c 20 54 | 72 61 63 65 48 69 74 4e |ation, T|raceHitN|
|00000f60| 6f 72 6d 61 6c 2c 20 54 | 72 61 63 65 45 6e 64 2c |ormal, T|raceEnd,|
|00000f70| 20 4d 6f 76 69 6e 67 41 | 63 74 6f 72 2e 4c 6f 63 | MovingA|ctor.Loc|
|00000f80| 61 74 69 6f 6e 2c 20 66 | 61 6c 73 65 2c 20 54 72 |ation, f|alse, Tr|
|00000f90| 61 63 65 45 78 74 65 6e | 74 20 29 3b 0d 0a 09 63 |aceExten|t );...c|
|00000fa0| 6c 61 73 73 27 44 65 62 | 75 67 27 2e 73 74 61 74 |lass'Deb|ug'.stat|
|00000fb0| 69 63 2e 44 65 62 75 67 | 4c 6f 67 28 20 4d 6f 76 |ic.Debug|Log( Mov|
|00000fc0| 69 6e 67 41 63 74 6f 72 | 2c 20 22 47 65 74 4d 6f |ingActor|, "GetMo|
|00000fd0| 76 65 6d 65 6e 74 44 65 | 73 74 69 6e 61 74 69 6f |vementDe|stinatio|
|00000fe0| 6e 20 54 72 61 63 65 48 | 69 74 41 63 74 6f 72 30 |n TraceH|itActor0|
|00000ff0| 20 22 20 24 20 54 72 61 | 63 65 48 69 74 41 63 74 | " $ Tra|ceHitAct|
|00001000| 6f 72 2c 20 27 57 61 79 | 70 6f 69 6e 74 53 65 6c |or, 'Way|pointSel|
|00001010| 65 63 74 6f 72 41 70 70 | 72 6f 61 63 68 69 6e 67 |ectorApp|roaching|
|00001020| 27 20 29 3b 0d 0a 09 69 | 66 28 20 54 72 61 63 65 |' );...i|f( Trace|
|00001030| 48 69 74 41 63 74 6f 72 | 20 3d 3d 20 4e 6f 6e 65 |HitActor| == None|
|00001040| 20 29 0d 0a 09 7b 0d 0a | 09 09 54 72 61 63 65 45 | )...{..|..TraceE|
|00001050| 6e 64 2e 5a 20 2d 3d 20 | 54 72 61 63 65 45 6e 64 |nd.Z -= |TraceEnd|
|00001060| 48 65 69 67 68 74 41 64 | 6a 75 73 74 3b 0d 0a 09 |HeightAd|just;...|
|00001070| 09 54 72 61 63 65 48 69 | 74 41 63 74 6f 72 20 3d |.TraceHi|tActor =|
|00001080| 20 4d 6f 76 69 6e 67 41 | 63 74 6f 72 2e 54 72 61 | MovingA|ctor.Tra|
|00001090| 63 65 28 20 54 72 61 63 | 65 48 69 74 4c 6f 63 61 |ce( Trac|eHitLoca|
|000010a0| 74 69 6f 6e 2c 20 54 72 | 61 63 65 48 69 74 4e 6f |tion, Tr|aceHitNo|
|000010b0| 72 6d 61 6c 2c 20 54 72 | 61 63 65 45 6e 64 2c 20 |rmal, Tr|aceEnd, |
|000010c0| 49 6e 74 65 6e 64 65 64 | 44 65 73 74 69 6e 61 74 |Intended|Destinat|
|000010d0| 69 6f 6e 2c 20 66 61 6c | 73 65 2c 20 54 72 61 63 |ion, fal|se, Trac|
|000010e0| 65 45 78 74 65 6e 74 20 | 29 3b 0d 0a 09 09 2f 2f |eExtent |);....//|
|000010f0| 54 72 61 63 65 48 69 74 | 41 63 74 6f 72 20 3d 20 |TraceHit|Actor = |
|00001100| 63 6c 61 73 73 27 55 74 | 69 6c 27 2e 73 74 61 74 |class'Ut|il'.stat|
|00001110| 69 63 2e 56 69 73 69 62 | 6c 65 54 72 61 63 65 28 |ic.Visib|leTrace(|
|00001120| 20 4d 6f 76 69 6e 67 41 | 63 74 6f 72 2c 20 54 72 | MovingA|ctor, Tr|
|00001130| 61 63 65 48 69 74 4c 6f | 63 61 74 69 6f 6e 2c 20 |aceHitLo|cation, |
|00001140| 54 72 61 63 65 48 69 74 | 4e 6f 72 6d 61 6c 2c 20 |TraceHit|Normal, |
|00001150| 54 72 61 63 65 45 6e 64 | 2c 20 49 6e 74 65 6e 64 |TraceEnd|, Intend|
|00001160| 65 64 44 65 73 74 69 6e | 61 74 69 6f 6e 2c 20 66 |edDestin|ation, f|
|00001170| 61 6c 73 65 2c 20 54 72 | 61 63 65 45 78 74 65 6e |alse, Tr|aceExten|
|00001180| 74 20 29 3b 0d 0a 09 09 | 63 6c 61 73 73 27 44 65 |t );....|class'De|
|00001190| 62 75 67 27 2e 73 74 61 | 74 69 63 2e 44 65 62 75 |bug'.sta|tic.Debu|
|000011a0| 67 4c 6f 67 28 20 4d 6f | 76 69 6e 67 41 63 74 6f |gLog( Mo|vingActo|
|000011b0| 72 2c 20 22 47 65 74 4d | 6f 76 65 6d 65 6e 74 44 |r, "GetM|ovementD|
|000011c0| 65 73 74 69 6e 61 74 69 | 6f 6e 20 54 72 61 63 65 |estinati|on Trace|
|000011d0| 48 69 74 41 63 74 6f 72 | 31 20 22 20 24 20 54 72 |HitActor|1 " $ Tr|
|000011e0| 61 63 65 48 69 74 41 63 | 74 6f 72 2c 20 27 57 61 |aceHitAc|tor, 'Wa|
|000011f0| 79 70 6f 69 6e 74 53 65 | 6c 65 63 74 6f 72 41 70 |ypointSe|lectorAp|
|00001200| 70 72 6f 61 63 68 69 6e | 67 27 20 29 3b 0d 0a 09 |proachin|g' );...|
|00001210| 09 69 66 28 20 54 72 61 | 63 65 48 69 74 41 63 74 |.if( Tra|ceHitAct|
|00001220| 6f 72 20 21 3d 20 4e 6f | 6e 65 20 29 0d 0a 09 09 |or != No|ne )....|
|00001230| 7b 0d 0a 09 09 09 4d 6f | 76 65 6d 65 6e 74 47 6f |{.....Mo|vementGo|
|00001240| 61 6c 2e 41 73 73 69 67 | 6e 56 65 63 74 6f 72 28 |al.Assig|nVector(|
|00001250| 20 4d 6f 76 69 6e 67 41 | 63 74 6f 72 2c 20 54 72 | MovingA|ctor, Tr|
|00001260| 61 63 65 48 69 74 4c 6f | 63 61 74 69 6f 6e 20 29 |aceHitLo|cation )|
|00001270| 3b 0d 0a 09 09 09 69 66 | 28 20 4d 6f 76 65 6d 65 |;.....if|( Moveme|
|00001280| 6e 74 47 6f 61 6c 2e 49 | 73 47 6f 61 6c 4e 61 76 |ntGoal.I|sGoalNav|
|00001290| 69 67 61 62 6c 65 28 20 | 4d 6f 76 69 6e 67 41 63 |igable( |MovingAc|
|000012a0| 74 6f 72 20 29 20 29 0d | 0a 09 09 09 7b 0d 0a 09 |tor ) ).|....{...|
|000012b0| 09 09 09 63 6c 61 73 73 | 27 44 65 62 75 67 27 2e |...class|'Debug'.|
|000012c0| 73 74 61 74 69 63 2e 44 | 65 62 75 67 4c 6f 67 28 |static.D|ebugLog(|
|000012d0| 20 4d 6f 76 69 6e 67 41 | 63 74 6f 72 2c 20 22 47 | MovingA|ctor, "G|
|000012e0| 65 74 4d 6f 76 65 6d 65 | 6e 74 44 65 73 74 69 6e |etMoveme|ntDestin|
|000012f0| 61 74 69 6f 6e 20 72 65 | 74 75 72 69 6e 67 20 22 |ation re|turing "|
|00001300| 20 24 20 74 72 75 65 2c | 20 27 57 61 79 70 6f 69 | $ true,| 'Waypoi|
|00001310| 6e 74 53 65 6c 65 63 74 | 6f 72 41 70 70 72 6f 61 |ntSelect|orApproa|
|00001320| 63 68 69 6e 67 27 20 29 | 3b 0d 0a 09 09 09 09 62 |ching' )|;......b|
|00001330| 47 6f 74 44 65 73 74 69 | 6e 61 74 69 6f 6e 20 3d |GotDesti|nation =|
|00001340| 20 74 72 75 65 3b 0d 0a | 09 09 09 7d 0d 0a 09 09 | true;..|...}....|
|00001350| 7d 0d 0a 09 7d 0d 0a 09 | 72 65 74 75 72 6e 20 62 |}...}...|return b|
|00001360| 47 6f 74 44 65 73 74 69 | 6e 61 74 69 6f 6e 3b 0d |GotDesti|nation;.|
|00001370| 0a 7d 0d 0a 0d 0a 0d 0a | 0d 0a 73 74 61 74 69 63 |.}......|..static|
|00001380| 20 66 75 6e 63 74 69 6f | 6e 20 62 6f 6f 6c 20 47 | functio|n bool G|
|00001390| 65 74 4d 6f 76 65 6d 65 | 6e 74 44 65 73 74 69 6e |etMoveme|ntDestin|
|000013a0| 61 74 69 6f 6e 32 28 20 | 47 6f 61 6c 41 62 73 74 |ation2( |GoalAbst|
|000013b0| 72 61 63 74 65 72 49 6e | 74 65 72 66 20 4d 6f 76 |racterIn|terf Mov|
|000013c0| 65 6d 65 6e 74 47 6f 61 | 6c 2c 0d 0a 09 09 41 63 |ementGoa|l,....Ac|
|000013d0| 74 6f 72 20 4d 6f 76 69 | 6e 67 41 63 74 6f 72 2c |tor Movi|ngActor,|
|000013e0| 0d 0a 09 09 42 65 68 61 | 76 69 6f 72 43 6f 6e 73 |....Beha|viorCons|
|000013f0| 74 72 61 69 6e 65 72 20 | 43 6f 6e 73 74 72 61 69 |trainer |Constrai|
|00001400| 6e 65 72 2c 0d 0a 09 09 | 47 6f 61 6c 41 62 73 74 |ner,....|GoalAbst|
|00001410| 72 61 63 74 65 72 49 6e | 74 65 72 66 20 47 6f 61 |racterIn|terf Goa|
|00001420| 6c 20 29 0d 0a 7b 0d 0a | 09 6c 6f 63 61 6c 20 62 |l )..{..|.local b|
|00001430| 6f 6f 6c 20 62 47 6f 74 | 44 65 73 74 69 6e 61 74 |ool bGot|Destinat|
|00001440| 69 6f 6e 3b 0d 0a 09 6c | 6f 63 61 6c 20 49 74 65 |ion;...l|ocal Ite|
|00001450| 6d 53 6f 72 74 65 72 20 | 4e 61 76 69 67 50 6f 69 |mSorter |NavigPoi|
|00001460| 6e 74 53 6f 72 74 65 72 | 3b 0d 0a 09 6c 6f 63 61 |ntSorter|;...loca|
|00001470| 6c 20 41 63 74 6f 72 20 | 47 6f 61 6c 41 63 74 6f |l Actor |GoalActo|
|00001480| 72 2c 20 43 75 72 72 65 | 6e 74 49 74 65 6d 2c 20 |r, Curre|ntItem, |
|00001490| 4e 61 76 69 67 41 63 74 | 6f 72 3b 0d 0a 09 6c 6f |NavigAct|or;...lo|
|000014a0| 63 61 6c 20 50 61 77 6e | 20 47 6f 61 6c 50 61 77 |cal Pawn| GoalPaw|
|000014b0| 6e 2c 20 4d 6f 76 69 6e | 67 50 61 77 6e 3b 0d 0a |n, Movin|gPawn;..|
|000014c0| 09 6c 6f 63 61 6c 20 69 | 6e 74 20 69 2c 20 49 74 |.local i|nt i, It|
|000014d0| 65 6d 43 6f 75 6e 74 3b | 0d 0a 09 0d 0a 09 63 6c |emCount;|......cl|
|000014e0| 61 73 73 27 44 65 62 75 | 67 27 2e 73 74 61 74 69 |ass'Debu|g'.stati|
|000014f0| 63 2e 44 65 62 75 67 4c | 6f 67 28 20 4d 6f 76 69 |c.DebugL|og( Movi|
|00001500| 6e 67 41 63 74 6f 72 2c | 20 22 47 65 74 4d 6f 76 |ngActor,| "GetMov|
|00001510| 65 6d 65 6e 74 44 65 73 | 74 69 6e 61 74 69 6f 6e |ementDes|tination|
|00001520| 22 2c 20 27 57 61 79 70 | 6f 69 6e 74 53 65 6c 65 |", 'Wayp|ointSele|
|00001530| 63 74 6f 72 41 70 70 72 | 6f 61 63 68 69 6e 67 27 |ctorAppr|oaching'|
|00001540| 20 29 3b 0d 0a 09 69 66 | 28 20 4d 6f 76 69 6e 67 | );...if|( Moving|
|00001550| 41 63 74 6f 72 2e 49 73 | 41 28 20 27 50 61 77 6e |Actor.Is|A( 'Pawn|
|00001560| 27 20 29 20 26 26 20 47 | 6f 61 6c 2e 47 65 74 47 |' ) && G|oal.GetG|
|00001570| 6f 61 6c 41 63 74 6f 72 | 28 20 4d 6f 76 69 6e 67 |oalActor|( Moving|
|00001580| 41 63 74 6f 72 2c 20 47 | 6f 61 6c 41 63 74 6f 72 |Actor, G|oalActor|
|00001590| 20 29 20 26 26 20 47 6f | 61 6c 41 63 74 6f 72 2e | ) && Go|alActor.|
|000015a0| 49 73 41 28 20 27 50 61 | 77 6e 27 20 29 20 29 0d |IsA( 'Pa|wn' ) ).|
|000015b0| 0a 09 7b 0d 0a 09 09 47 | 6f 61 6c 50 61 77 6e 20 |..{....G|oalPawn |
|000015c0| 3d 20 50 61 77 6e 28 20 | 47 6f 61 6c 41 63 74 6f |= Pawn( |GoalActo|
|000015d0| 72 20 29 3b 0d 0a 09 09 | 4d 6f 76 69 6e 67 50 61 |r );....|MovingPa|
|000015e0| 77 6e 20 3d 20 50 61 77 | 6e 28 20 4d 6f 76 69 6e |wn = Paw|n( Movin|
|000015f0| 67 41 63 74 6f 72 20 29 | 3b 0d 0a 09 09 0d 0a 09 |gActor )|;.......|
|00001600| 09 4e 61 76 69 67 50 6f | 69 6e 74 53 6f 72 74 65 |.NavigPo|intSorte|
|00001610| 72 20 3d 20 49 74 65 6d | 53 6f 72 74 65 72 28 20 |r = Item|Sorter( |
|00001620| 63 6c 61 73 73 27 53 69 | 6e 67 6c 65 74 6f 6e 27 |class'Si|ngleton'|
|00001630| 2e 73 74 61 74 69 63 2e | 47 65 74 49 6e 73 74 61 |.static.|GetInsta|
|00001640| 6e 63 65 28 20 4d 6f 76 | 69 6e 67 41 63 74 6f 72 |nce( Mov|ingActor|
|00001650| 2e 58 4c 65 76 65 6c 2c | 20 63 6c 61 73 73 27 49 |.XLevel,| class'I|
|00001660| 74 65 6d 53 6f 72 74 65 | 72 27 20 29 20 29 3b 0d |temSorte|r' ) );.|
|00001670| 0a 09 09 4e 61 76 69 67 | 50 6f 69 6e 74 53 6f 72 |...Navig|PointSor|
|00001680| 74 65 72 2e 43 6f 6c 6c | 65 63 74 52 61 64 69 75 |ter.Coll|ectRadiu|
|00001690| 73 49 74 65 6d 73 28 20 | 47 6f 61 6c 41 63 74 6f |sItems( |GoalActo|
|000016a0| 72 2c 20 63 6c 61 73 73 | 27 4e 61 76 69 67 61 74 |r, class|'Navigat|
|000016b0| 69 6f 6e 50 6f 69 6e 74 | 27 2c 20 33 32 30 20 29 |ionPoint|', 320 )|
|000016c0| 3b 0d 0a 09 09 4e 61 76 | 69 67 50 6f 69 6e 74 53 |;....Nav|igPointS|
|000016d0| 6f 72 74 65 72 2e 49 6e | 69 74 53 6f 72 74 65 72 |orter.In|itSorter|
|000016e0| 28 29 3b 0d 0a 09 09 4e | 61 76 69 67 50 6f 69 6e |();....N|avigPoin|
|000016f0| 74 53 6f 72 74 65 72 2e | 53 6f 72 74 49 74 65 6d |tSorter.|SortItem|
|00001700| 73 28 29 3b 0d 0a 09 09 | 0d 0a 09 63 6c 61 73 73 |s();....|...class|
|00001710| 27 44 65 62 75 67 27 2e | 73 74 61 74 69 63 2e 44 |'Debug'.|static.D|
|00001720| 65 62 75 67 4c 6f 67 28 | 20 4d 6f 76 69 6e 67 41 |ebugLog(| MovingA|
|00001730| 63 74 6f 72 2c 20 22 47 | 65 74 4d 6f 76 65 6d 65 |ctor, "G|etMoveme|
|00001740| 6e 74 44 65 73 74 69 6e | 61 74 69 6f 6e 20 47 6f |ntDestin|ation Go|
|00001750| 61 6c 50 61 77 6e 20 22 | 20 24 20 47 6f 61 6c 50 |alPawn "| $ GoalP|
|00001760| 61 77 6e 2c 20 27 57 61 | 79 70 6f 69 6e 74 53 65 |awn, 'Wa|ypointSe|
|00001770| 6c 65 63 74 6f 72 41 70 | 70 72 6f 61 63 68 69 6e |lectorAp|proachin|
|00001780| 67 27 20 29 3b 0d 0a 09 | 63 6c 61 73 73 27 44 65 |g' );...|class'De|
|00001790| 62 75 67 27 2e 73 74 61 | 74 69 63 2e 44 65 62 75 |bug'.sta|tic.Debu|
|000017a0| 67 4c 6f 67 28 20 4d 6f | 76 69 6e 67 41 63 74 6f |gLog( Mo|vingActo|
|000017b0| 72 2c 20 22 47 65 74 4d | 6f 76 65 6d 65 6e 74 44 |r, "GetM|ovementD|
|000017c0| 65 73 74 69 6e 61 74 69 | 6f 6e 20 4d 6f 76 69 6e |estinati|on Movin|
|000017d0| 67 50 61 77 6e 20 22 20 | 24 20 4d 6f 76 69 6e 67 |gPawn " |$ Moving|
|000017e0| 50 61 77 6e 2c 20 27 57 | 61 79 70 6f 69 6e 74 53 |Pawn, 'W|aypointS|
|000017f0| 65 6c 65 63 74 6f 72 41 | 70 70 72 6f 61 63 68 69 |electorA|pproachi|
|00001800| 6e 67 27 20 29 3b 0d 0a | 0d 0a 09 09 69 66 28 20 |ng' );..|....if( |
|00001810| 4e 61 76 69 67 50 6f 69 | 6e 74 53 6f 72 74 65 72 |NavigPoi|ntSorter|
|00001820| 2e 47 65 74 49 74 65 6d | 43 6f 75 6e 74 28 20 49 |.GetItem|Count( I|
|00001830| 74 65 6d 43 6f 75 6e 74 | 20 29 20 29 0d 0a 09 09 |temCount| ) )....|
|00001840| 7b 0d 0a 09 09 09 66 6f | 72 28 20 69 20 3d 20 30 |{.....fo|r( i = 0|
|00001850| 3b 20 69 20 3c 20 49 74 | 65 6d 43 6f 75 6e 74 3b |; i < It|emCount;|
|00001860| 20 69 2b 2b 20 29 0d 0a | 09 09 09 7b 0d 0a 09 09 | i++ )..|...{....|
|00001870| 09 09 43 75 72 72 65 6e | 74 49 74 65 6d 20 3d 20 |..Curren|tItem = |
|00001880| 4e 61 76 69 67 50 6f 69 | 6e 74 53 6f 72 74 65 72 |NavigPoi|ntSorter|
|00001890| 2e 47 65 74 49 74 65 6d | 28 20 69 20 29 3b 0d 0a |.GetItem|( i );..|
|000018a0| 09 63 6c 61 73 73 27 44 | 65 62 75 67 27 2e 73 74 |.class'D|ebug'.st|
|000018b0| 61 74 69 63 2e 44 65 62 | 75 67 4c 6f 67 28 20 4d |atic.Deb|ugLog( M|
|000018c0| 6f 76 69 6e 67 41 63 74 | 6f 72 2c 20 22 47 65 74 |ovingAct|or, "Get|
|000018d0| 4d 6f 76 65 6d 65 6e 74 | 44 65 73 74 69 6e 61 74 |Movement|Destinat|
|000018e0| 69 6f 6e 20 43 75 72 72 | 65 6e 74 49 74 65 6d 20 |ion Curr|entItem |
|000018f0| 22 20 24 20 43 75 72 72 | 65 6e 74 49 74 65 6d 2c |" $ Curr|entItem,|
|00001900| 20 27 57 61 79 70 6f 69 | 6e 74 53 65 6c 65 63 74 | 'Waypoi|ntSelect|
|00001910| 6f 72 41 70 70 72 6f 61 | 63 68 69 6e 67 27 20 29 |orApproa|ching' )|
|00001920| 3b 0d 0a 09 09 09 09 69 | 66 28 20 47 6f 61 6c 50 |;......i|f( GoalP|
|00001930| 61 77 6e 2e 41 63 74 6f | 72 52 65 61 63 68 61 62 |awn.Acto|rReachab|
|00001940| 6c 65 28 20 43 75 72 72 | 65 6e 74 49 74 65 6d 20 |le( Curr|entItem |
|00001950| 29 20 29 0d 0a 09 09 09 | 09 7b 0d 0a 09 09 09 09 |) ).....|.{......|
|00001960| 09 4d 6f 76 65 6d 65 6e | 74 47 6f 61 6c 2e 41 73 |.Movemen|tGoal.As|
|00001970| 73 69 67 6e 4f 62 6a 65 | 63 74 28 20 4d 6f 76 69 |signObje|ct( Movi|
|00001980| 6e 67 50 61 77 6e 2c 20 | 43 75 72 72 65 6e 74 49 |ngPawn, |CurrentI|
|00001990| 74 65 6d 20 29 3b 0d 0a | 09 09 09 09 09 69 66 28 |tem );..|.....if(|
|000019a0| 20 4d 6f 76 65 6d 65 6e | 74 47 6f 61 6c 2e 49 73 | Movemen|tGoal.Is|
|000019b0| 47 6f 61 6c 52 65 61 63 | 68 61 62 6c 65 28 20 4d |GoalReac|hable( M|
|000019c0| 6f 76 69 6e 67 50 61 77 | 6e 20 29 20 29 0d 0a 09 |ovingPaw|n ) )...|
|000019d0| 09 09 09 09 7b 0d 0a 09 | 09 09 09 09 09 62 47 6f |....{...|.....bGo|
|000019e0| 74 44 65 73 74 69 6e 61 | 74 69 6f 6e 20 3d 20 74 |tDestina|tion = t|
|000019f0| 72 75 65 3b 0d 0a 09 09 | 09 09 09 09 62 72 65 61 |rue;....|....brea|
|00001a00| 6b 3b 0d 0a 09 09 09 09 | 09 7d 0d 0a 09 09 09 09 |k;......|.}......|
|00001a10| 09 65 6c 73 65 0d 0a 09 | 09 09 09 09 7b 0d 0a 09 |.else...|....{...|
|00001a20| 09 09 09 09 09 4e 61 76 | 69 67 41 63 74 6f 72 20 |.....Nav|igActor |
|00001a30| 3d 20 4d 6f 76 69 6e 67 | 50 61 77 6e 2e 46 69 6e |= Moving|Pawn.Fin|
|00001a40| 64 50 61 74 68 54 6f 77 | 61 72 64 28 20 43 75 72 |dPathTow|ard( Cur|
|00001a50| 72 65 6e 74 49 74 65 6d | 20 29 3b 0d 0a 09 09 09 |rentItem| );.....|
|00001a60| 09 09 09 69 66 28 20 4e | 61 76 69 67 41 63 74 6f |...if( N|avigActo|
|00001a70| 72 20 21 3d 20 4e 6f 6e | 65 20 29 0d 0a 09 09 09 |r != Non|e ).....|
|00001a80| 09 09 09 7b 0d 0a 09 09 | 09 09 09 09 09 4d 6f 76 |...{....|.....Mov|
|00001a90| 65 6d 65 6e 74 47 6f 61 | 6c 2e 41 73 73 69 67 6e |ementGoa|l.Assign|
|00001aa0| 4f 62 6a 65 63 74 28 20 | 4d 6f 76 69 6e 67 50 61 |Object( |MovingPa|
|00001ab0| 77 6e 2c 20 4e 61 76 69 | 67 41 63 74 6f 72 20 29 |wn, Navi|gActor )|
|00001ac0| 3b 0d 0a 09 09 09 09 09 | 09 09 62 47 6f 74 44 65 |;.......|..bGotDe|
|00001ad0| 73 74 69 6e 61 74 69 6f | 6e 20 3d 20 74 72 75 65 |stinatio|n = true|
|00001ae0| 3b 0d 0a 09 09 09 09 09 | 09 09 62 72 65 61 6b 3b |;.......|..break;|
|00001af0| 0d 0a 09 09 09 09 09 09 | 7d 0d 0a 09 09 09 09 09 |........|}.......|
|00001b00| 09 65 6c 73 65 0d 0a 09 | 09 09 09 09 09 7b 0d 0a |.else...|.....{..|
|00001b10| 09 09 09 20 20 20 20 20 | 20 09 09 09 4e 61 76 69 |... | ...Navi|
|00001b20| 67 50 6f 69 6e 74 53 6f | 72 74 65 72 2e 52 65 6a |gPointSo|rter.Rej|
|00001b30| 65 63 74 49 74 65 6d 28 | 20 69 20 29 3b 0d 0a 09 |ectItem(| i );...|
|00001b40| 09 09 09 09 09 7d 0d 0a | 09 09 09 09 09 7d 0d 0a |.....}..|.....}..|
|00001b50| 09 09 09 09 7d 0d 0a 09 | 09 09 09 65 6c 73 65 0d |....}...|...else.|
|00001b60| 0a 20 20 20 20 20 20 09 | 09 09 7b 0d 0a 09 20 20 |. .|..{... |
|00001b70| 20 20 20 20 09 09 09 4e | 61 76 69 67 50 6f 69 6e | ...N|avigPoin|
|00001b80| 74 53 6f 72 74 65 72 2e | 52 65 6a 65 63 74 49 74 |tSorter.|RejectIt|
|00001b90| 65 6d 28 20 69 20 29 3b | 0d 0a 09 20 20 20 20 09 |em( i );|... .|
|00001ba0| 20 20 20 20 7d 0d 0a 09 | 09 09 7d 0d 0a 09 09 7d | }...|..}....}|
|00001bb0| 0d 0a 09 7d 0d 0a 09 0d | 0a 09 63 6c 61 73 73 27 |...}....|..class'|
|00001bc0| 44 65 62 75 67 27 2e 73 | 74 61 74 69 63 2e 44 65 |Debug'.s|tatic.De|
|00001bd0| 62 75 67 4c 6f 67 28 20 | 4d 6f 76 69 6e 67 41 63 |bugLog( |MovingAc|
|00001be0| 74 6f 72 2c 20 22 47 65 | 74 4d 6f 76 65 6d 65 6e |tor, "Ge|tMovemen|
|00001bf0| 74 44 65 73 74 69 6e 61 | 74 69 6f 6e 20 72 65 74 |tDestina|tion ret|
|00001c00| 75 72 69 6e 67 20 22 20 | 24 20 62 47 6f 74 44 65 |uring " |$ bGotDe|
|00001c10| 73 74 69 6e 61 74 69 6f | 6e 2c 20 27 57 61 79 70 |stinatio|n, 'Wayp|
|00001c20| 6f 69 6e 74 53 65 6c 65 | 63 74 6f 72 41 70 70 72 |ointSele|ctorAppr|
|00001c30| 6f 61 63 68 69 6e 67 27 | 20 29 3b 0d 0a 09 72 65 |oaching'| );...re|
|00001c40| 74 75 72 6e 20 62 47 6f | 74 44 65 73 74 69 6e 61 |turn bGo|tDestina|
|00001c50| 74 69 6f 6e 3b 0d 0a 7d | 0d 0a 0d 0a 00 |tion;..}|..... |
+--------+-------------------------+-------------------------+--------+--------+