home *** CD-ROM | disk | FTP | other *** search
/ GameStar 2005 April / Gamestar_72_2005-04_dvd.iso / Patche / ut2004_patchv3355.exe / UT2004-Patch / System / UTV2004c.u / utvReplication_ScriptText.TextBuffer < prev    next >
Unknown  |  2005-02-15  |  16.8 KB

open in: MacOS 8.1     |     Win98     |     DOS

view JSON data     |     view as text

This file was not able to be converted.
This format is not currently supported by dexvert.

ConfidenceProgramDetectionMatch TypeSupport
100% file data default



hex view
+--------+-------------------------+-------------------------+--------+--------+
|00000000| 00 00 00 00 00 00 00 00 | 66 8c 02 2f 2f 2d 2d 2d |........|f..//---|
|00000010| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 2d |--------|--------|
|00000020| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 2d |--------|--------|
|00000030| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 2d |--------|--------|
|00000040| 2d 2d 2d 2d 2d 2d 2d 2d | 0d 0a 2f 2f 0d 0a 2f 2f |--------|..//..//|
|00000050| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 2d |--------|--------|
|00000060| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 2d |--------|--------|
|00000070| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 2d |--------|--------|
|00000080| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 0d 0a 63 6c 61 |--------|---..cla|
|00000090| 73 73 20 75 74 76 52 65 | 70 6c 69 63 61 74 69 6f |ss utvRe|plicatio|
|000000a0| 6e 20 65 78 74 65 6e 64 | 73 20 41 63 74 6f 72 3b |n extend|s Actor;|
|000000b0| 0d 0a 0d 0a 2f 2f 41 20 | 63 6f 6e 73 74 61 6e 74 |....//A |constant|
|000000c0| 20 6f 66 20 73 6f 72 74 | 73 0d 0a 76 61 72 20 63 | of sort|s..var c|
|000000d0| 6f 6e 66 69 67 20 73 74 | 72 69 6e 67 20 55 74 76 |onfig st|ring Utv|
|000000e0| 50 61 63 6b 61 67 65 3b | 0d 0a 0d 0a 2f 2f 43 6f |Package;|....//Co|
|000000f0| 6e 66 69 67 75 72 61 74 | 69 6f 6e 20 74 68 69 6e |nfigurat|ion thin|
|00000100| 67 73 0d 0a 76 61 72 20 | 63 6f 6e 66 69 67 20 69 |gs..var |config i|
|00000110| 6e 74 20 56 69 65 77 4d | 6f 64 65 3b 09 09 2f 2f |nt ViewM|ode;..//|
|00000120| 30 20 3d 20 6c 6f 63 6b | 65 64 20 6f 6e 20 66 72 |0 = lock|ed on fr|
|00000130| 65 65 66 6c 69 67 68 74 | 2c 20 31 20 3d 20 66 72 |eeflight|, 1 = fr|
|00000140| 65 65 2c 20 32 20 3d 20 | 6c 6f 63 6b 65 64 0d 0a |ee, 2 = |locked..|
|00000150| 0d 0a 73 74 72 75 63 74 | 20 4d 6f 76 65 6d 65 6e |..struct| Movemen|
|00000160| 74 20 7b 0d 0a 09 76 61 | 72 20 66 6c 6f 61 74 20 |t {...va|r float |
|00000170| 74 69 6d 65 3b 0d 0a 09 | 76 61 72 20 76 65 63 74 |time;...|var vect|
|00000180| 6f 72 20 6c 6f 63 3b 0d | 0a 09 76 61 72 20 72 6f |or loc;.|..var ro|
|00000190| 74 61 74 6f 72 20 72 6f | 74 3b 0d 0a 7d 3b 0d 0a |tator ro|t;..};..|
|000001a0| 0d 0a 76 61 72 20 4d 6f | 76 65 6d 65 6e 74 20 6d |..var Mo|vement m|
|000001b0| 6f 76 65 73 5b 31 30 30 | 30 5d 3b 20 20 20 20 09 |oves[100|0]; .|
|000001c0| 2f 2f 41 72 6f 75 6e 64 | 20 31 30 20 73 68 6f 75 |//Around| 10 shou|
|000001d0| 6c 64 20 62 65 20 65 6e | 6f 75 67 68 2e 2e 20 3a |ld be en|ough.. :|
|000001e0| 29 0d 0a 76 61 72 20 69 | 6e 74 20 6d 6f 76 65 68 |)..var i|nt moveh|
|000001f0| 65 61 64 3b 0d 0a 76 61 | 72 20 69 6e 74 20 6d 6f |ead;..va|r int mo|
|00000200| 76 65 74 61 69 6c 3b 0d | 0a 0d 0a 76 61 72 20 62 |vetail;.|...var b|
|00000210| 6f 6f 6c 20 76 69 65 77 | 69 6e 67 53 65 6c 66 3b |ool view|ingSelf;|
|00000220| 0d 0a 76 61 72 20 69 6e | 74 20 6c 61 73 74 56 69 |..var in|t lastVi|
|00000230| 65 77 65 64 53 65 6c 66 | 3b 0d 0a 0d 0a 76 61 72 |ewedSelf|;....var|
|00000240| 20 62 6f 6f 6c 20 53 65 | 65 41 6c 6c 3b 0d 0a 76 | bool Se|eAll;..v|
|00000250| 61 72 20 62 6f 6f 6c 20 | 4e 6f 50 72 69 6d 61 72 |ar bool |NoPrimar|
|00000260| 79 3b 0d 0a 76 61 72 20 | 62 6f 6f 6c 20 46 6f 6c |y;..var |bool Fol|
|00000270| 6c 6f 77 50 72 69 6d 61 | 72 79 3b 0d 0a 76 61 72 |lowPrima|ry;..var|
|00000280| 20 62 6f 6f 6c 20 4f 6c | 64 46 6f 6c 6c 6f 77 3b | bool Ol|dFollow;|
|00000290| 0d 0a 76 61 72 20 62 6f | 6f 6c 20 49 73 44 65 6d |..var bo|ol IsDem|
|000002a0| 6f 3b 0d 0a 76 61 72 20 | 62 6f 6f 6c 20 4d 75 74 |o;..var |bool Mut|
|000002b0| 65 43 68 61 74 3b 0d 0a | 76 61 72 20 73 74 72 69 |eChat;..|var stri|
|000002c0| 6e 67 20 4c 61 73 74 54 | 61 72 67 65 74 4e 61 6d |ng LastT|argetNam|
|000002d0| 65 3b 0d 0a 76 61 72 20 | 62 6f 6f 6c 20 46 72 65 |e;..var |bool Fre|
|000002e0| 65 46 6c 69 67 68 74 3b | 0d 0a 76 61 72 20 56 65 |eFlight;|..var Ve|
|000002f0| 63 74 6f 72 20 4c 6f 63 | 61 6c 50 6f 73 3b 0d 0a |ctor Loc|alPos;..|
|00000300| 76 61 72 20 62 6f 6f 6c | 20 4c 6f 63 61 6c 50 6f |var bool| LocalPo|
|00000310| 73 53 65 74 3b 0d 0a 76 | 61 72 20 62 6f 6f 6c 20 |sSet;..v|ar bool |
|00000320| 6d 6f 76 65 46 6f 72 77 | 61 72 64 2c 6d 6f 76 65 |moveForw|ard,move|
|00000330| 42 61 63 6b 77 61 72 64 | 2c 6d 6f 76 65 4c 65 66 |Backward|,moveLef|
|00000340| 74 2c 6d 6f 76 65 52 69 | 67 68 74 2c 6d 6f 76 65 |t,moveRi|ght,move|
|00000350| 55 70 2c 6d 6f 76 65 44 | 6f 77 6e 3b 09 2f 2f 73 |Up,moveD|own;.//s|
|00000360| 68 6f 75 6c 64 6e 74 20 | 62 65 20 6e 65 65 64 65 |houldnt |be neede|
|00000370| 64 20 62 75 74 20 70 6c | 61 79 65 72 63 6f 6e 74 |d but pl|ayercont|
|00000380| 72 6f 6c 6c 65 72 20 61 | 46 6f 72 77 61 72 64 20 |roller a|Forward |
|00000390| 65 74 63 20 61 6c 77 61 | 79 73 20 30 20 3f 0d 0a |etc alwa|ys 0 ?..|
|000003a0| 0d 0a 73 74 72 75 63 74 | 20 54 49 6e 74 65 72 70 |..struct| TInterp|
|000003b0| 6f 6c 0d 0a 7b 0d 0a 20 | 20 76 61 72 20 66 6c 6f |ol..{.. | var flo|
|000003c0| 61 74 20 6b 31 3b 0d 0a | 20 20 76 61 72 20 66 6c |at k1;..| var fl|
|000003d0| 6f 61 74 20 6b 32 3b 20 | 20 20 2f 2f 73 6c 6f 70 |oat k2; | //slop|
|000003e0| 65 0d 0a 20 20 76 61 72 | 20 66 6c 6f 61 74 20 79 |e.. var| float y|
|000003f0| 31 3b 0d 0a 20 20 76 61 | 72 20 66 6c 6f 61 74 20 |1;.. va|r float |
|00000400| 79 32 3b 20 20 20 2f 2f | 63 75 72 20 26 20 6e 65 |y2; //|cur & ne|
|00000410| 78 74 20 76 61 6c 75 65 | 0d 0a 20 20 76 61 72 20 |xt value|.. var |
|00000420| 66 6c 6f 61 74 20 67 31 | 3b 0d 0a 20 20 76 61 72 |float g1|;.. var|
|00000430| 20 66 6c 6f 61 74 20 63 | 31 3b 0d 0a 20 20 76 61 | float c|1;.. va|
|00000440| 72 20 66 6c 6f 61 74 20 | 64 79 3b 0d 0a 20 20 76 |r float |dy;.. v|
|00000450| 61 72 20 66 6c 6f 61 74 | 20 68 31 3b 0d 0a 7d 3b |ar float| h1;..};|
|00000460| 0d 0a 0d 0a 73 74 72 75 | 63 74 20 54 50 6c 61 79 |....stru|ct TPlay|
|00000470| 65 72 49 6e 74 65 72 70 | 6f 6c 0d 0a 7b 0d 0a 20 |erInterp|ol..{.. |
|00000480| 20 76 61 72 20 66 6c 6f | 61 74 20 78 31 3b 20 20 | var flo|at x1; |
|00000490| 20 20 20 20 20 2f 2f 63 | 75 72 20 26 20 6e 65 78 | //c|ur & nex|
|000004a0| 74 20 74 69 6d 65 76 61 | 6c 75 65 0d 0a 20 20 76 |t timeva|lue.. v|
|000004b0| 61 72 20 66 6c 6f 61 74 | 20 78 32 3b 0d 0a 0d 0a |ar float| x2;....|
|000004c0| 20 20 76 61 72 20 62 6f | 6f 6c 20 6e 6f 69 6e 66 | var bo|ol noinf|
|000004d0| 6f 3b 20 20 20 20 2f 2f | 69 66 20 74 72 75 65 2c |o; //|if true,|
|000004e0| 20 64 6f 20 6c 69 6e 65 | 61 72 20 65 78 74 72 61 | do line|ar extra|
|000004f0| 70 6f 6c 61 74 69 6f 6e | 20 69 6e 73 74 65 61 64 |polation| instead|
|00000500| 0d 0a 0d 0a 20 20 76 61 | 72 20 54 49 6e 74 65 72 |.... va|r TInter|
|00000510| 70 6f 6c 20 63 6f 72 64 | 73 5b 37 5d 3b 20 20 20 |pol cord|s[7]; |
|00000520| 2f 2f 78 2c 20 79 2c 20 | 7a 2c 20 72 6f 74 2e 70 |//x, y, |z, rot.p|
|00000530| 69 74 63 68 2c 20 72 6f | 74 2e 79 61 77 2c 20 76 |itch, ro|t.yaw, v|
|00000540| 69 65 77 72 6f 74 2e 70 | 69 74 63 68 2c 20 76 69 |iewrot.p|itch, vi|
|00000550| 65 77 72 6f 74 2e 79 61 | 77 0d 0a 7d 3b 0d 0a 0d |ewrot.ya|w..};...|
|00000560| 0a 76 61 72 20 54 50 6c | 61 79 65 72 49 6e 74 65 |.var TPl|ayerInte|
|00000570| 72 70 6f 6c 20 69 6e 74 | 65 72 70 6f 6c 3b 0d 0a |rpol int|erpol;..|
|00000580| 0d 0a 76 61 72 20 63 6f | 6e 66 69 67 20 73 74 72 |..var co|nfig str|
|00000590| 69 6e 67 20 43 68 61 74 | 53 74 72 69 6e 67 3b 0d |ing Chat|String;.|
|000005a0| 0a 76 61 72 20 63 6f 6e | 66 69 67 20 62 6f 6f 6c |.var con|fig bool|
|000005b0| 20 77 61 6e 74 42 65 68 | 69 6e 64 76 69 65 77 3b | wantBeh|indview;|
|000005c0| 0d 0a 0d 0a 72 65 70 6c | 69 63 61 74 69 6f 6e 0d |....repl|ication.|
|000005d0| 0a 7b 0d 0a 09 2f 2f 54 | 68 69 6e 67 73 20 74 68 |.{...//T|hings th|
|000005e0| 65 20 73 65 72 76 65 72 | 20 63 61 6c 6c 73 20 6f |e server| calls o|
|000005f0| 6e 20 75 73 0d 0a 09 72 | 65 6c 69 61 62 6c 65 20 |n us...r|eliable |
|00000600| 69 66 20 28 52 6f 6c 65 | 20 3d 3d 20 52 4f 4c 45 |if (Role| == ROLE|
|00000610| 5f 41 75 74 68 6f 72 69 | 74 79 29 0d 0a 09 09 47 |_Authori|ty)....G|
|00000620| 65 74 46 72 6f 6d 53 65 | 72 76 65 72 2c 20 47 65 |etFromSe|rver, Ge|
|00000630| 74 54 61 72 67 65 74 3b | 0d 0a 0d 0a 09 2f 2f 54 |tTarget;|.....//T|
|00000640| 68 69 6e 67 73 20 77 65 | 20 63 61 6e 20 63 61 6c |hings we| can cal|
|00000650| 6c 20 6f 6e 20 74 68 65 | 20 73 65 72 76 65 72 0d |l on the| server.|
|00000660| 0a 09 72 65 6c 69 61 62 | 6c 65 20 69 66 20 28 52 |..reliab|le if (R|
|00000670| 6f 6c 65 3c 52 4f 4c 45 | 5f 41 75 74 68 6f 72 69 |ole<ROLE|_Authori|
|00000680| 74 79 29 0d 0a 09 09 53 | 65 6e 64 54 6f 53 65 72 |ty)....S|endToSer|
|00000690| 76 65 72 2c 20 53 65 6e | 64 54 61 72 67 65 74 3b |ver, Sen|dTarget;|
|000006a0| 0d 0a 7d 0d 0a 0d 0a 76 | 61 72 20 75 74 76 49 6e |..}....v|ar utvIn|
|000006b0| 74 65 72 61 63 74 69 6f | 6e 20 75 74 69 3b 0d 0a |teractio|n uti;..|
|000006c0| 0d 0a 76 61 72 20 66 6c | 6f 61 74 20 63 75 72 72 |..var fl|oat curr|
|000006d0| 65 6e 74 54 69 6d 65 3b | 0d 0a 76 61 72 20 66 6c |entTime;|..var fl|
|000006e0| 6f 61 74 20 6c 61 73 74 | 53 65 6e 64 3b 0d 0a 0d |oat last|Send;...|
|000006f0| 0a 76 61 72 20 62 6f 6f | 6c 20 77 61 73 45 6e 64 |.var boo|l wasEnd|
|00000700| 65 64 3b 0d 0a 0d 0a 73 | 69 6d 75 6c 61 74 65 64 |ed;....s|imulated|
|00000710| 20 65 76 65 6e 74 20 50 | 6f 73 74 42 65 67 69 6e | event P|ostBegin|
|00000720| 50 6c 61 79 28 29 0d 0a | 7b 0d 0a 09 6c 6f 63 61 |Play()..|{...loca|
|00000730| 6c 20 50 6c 61 79 65 72 | 43 6f 6e 74 72 6f 6c 6c |l Player|Controll|
|00000740| 65 72 20 70 3b 0d 0a 0d | 0a 09 4c 6f 67 20 28 22 |er p;...|..Log ("|
|00000750| 75 74 76 3a 20 50 6f 73 | 74 42 65 67 69 6e 50 6c |utv: Pos|tBeginPl|
|00000760| 61 79 20 69 6e 20 72 65 | 70 6c 69 63 61 74 69 6f |ay in re|plicatio|
|00000770| 6e 22 29 3b 0d 0a 0d 0a | 09 70 20 3d 20 6c 65 76 |n");....|.p = lev|
|00000780| 65 6c 2e 47 65 74 4c 6f | 63 61 6c 50 6c 61 79 65 |el.GetLo|calPlaye|
|00000790| 72 43 6f 6e 74 72 6f 6c | 6c 65 72 20 28 29 3b 0d |rControl|ler ();.|
|000007a0| 0a 09 6c 61 73 74 56 69 | 65 77 65 64 53 65 6c 66 |..lastVi|ewedSelf|
|000007b0| 20 3d 20 32 3b 0d 0a 09 | 63 6c 61 73 73 27 75 74 | = 2;...|class'ut|
|000007c0| 76 52 65 70 6c 69 63 61 | 74 69 6f 6e 27 2e 64 65 |vReplica|tion'.de|
|000007d0| 66 61 75 6c 74 2e 77 61 | 6e 74 42 65 68 69 6e 64 |fault.wa|ntBehind|
|000007e0| 76 69 65 77 20 3d 20 74 | 72 75 65 3b 0d 0a 0d 0a |view = t|rue;....|
|000007f0| 09 2f 2f 4f 6e 73 6c 61 | 75 67 68 74 20 66 69 78 |.//Onsla|ught fix|
|00000800| 65 73 0d 0a 09 4f 6e 73 | 6c 61 75 67 68 74 46 69 |es...Ons|laughtFi|
|00000810| 78 28 29 3b 0d 0a 7d 0d | 0a 0d 0a 2f 2f 4f 6e 73 |x();..}.|...//Ons|
|00000820| 6c 61 75 67 68 74 20 72 | 65 6c 69 65 73 20 6f 6e |laught r|elies on|
|00000830| 20 52 50 43 27 73 20 74 | 6f 20 72 65 63 65 69 76 | RPC's t|o receiv|
|00000840| 65 20 74 68 65 20 63 75 | 72 72 65 6e 74 20 70 6f |e the cu|rrent po|
|00000850| 77 65 72 6c 69 6e 6b 20 | 73 65 74 75 70 2e 0d 0a |werlink |setup...|
|00000860| 2f 2f 55 6e 66 6f 72 74 | 75 6e 61 74 65 6c 79 20 |//Unfort|unately |
|00000870| 69 74 20 69 73 20 6e 6f | 74 20 72 65 61 64 79 20 |it is no|t ready |
|00000880| 74 6f 20 72 65 63 65 69 | 76 65 20 74 68 65 6d 20 |to recei|ve them |
|00000890| 75 6e 74 69 6c 20 61 66 | 74 65 72 20 74 68 65 0d |until af|ter the.|
|000008a0| 0a 2f 2f 66 69 72 73 74 | 20 74 69 63 6b 2e 20 55 |.//first| tick. U|
|000008b0| 54 56 20 73 6f 6d 65 74 | 69 6d 65 73 20 73 65 6e |TV somet|imes sen|
|000008c0| 64 20 74 68 65 6d 20 74 | 6f 6f 20 73 6f 6f 6e 2c |d them t|oo soon,|
|000008d0| 20 73 6f 20 74 68 69 73 | 20 66 75 6e 63 74 69 6f | so this| functio|
|000008e0| 6e 20 6d 61 6b 65 73 20 | 73 75 72 65 0d 0a 2f 2f |n makes |sure..//|
|000008f0| 74 68 61 74 20 74 68 65 | 20 6f 6e 73 6c 61 75 67 |that the| onslaug|
|00000900| 68 74 20 68 75 64 20 68 | 61 73 20 72 75 6e 20 6f |ht hud h|as run o|
|00000910| 6e 65 20 74 69 63 6b 20 | 62 65 66 6f 72 65 20 69 |ne tick |before i|
|00000920| 74 20 68 61 70 70 65 6e | 73 2e 0d 0a 73 69 6d 75 |t happen|s...simu|
|00000930| 6c 61 74 65 64 20 66 75 | 6e 63 74 69 6f 6e 20 4f |lated fu|nction O|
|00000940| 6e 73 6c 61 75 67 68 74 | 46 69 78 28 29 0d 0a 7b |nslaught|Fix()..{|
|00000950| 0d 0a 09 6c 6f 63 61 6c | 20 50 6c 61 79 65 72 43 |...local| PlayerC|
|00000960| 6f 6e 74 72 6f 6c 6c 65 | 72 20 70 3b 0d 0a 20 20 |ontrolle|r p;.. |
|00000970| 20 20 6c 6f 63 61 6c 20 | 4f 4e 53 48 55 44 4f 6e | local |ONSHUDOn|
|00000980| 73 6c 61 75 67 68 74 20 | 6f 68 3b 0d 0a 0d 0a 09 |slaught |oh;.....|
|00000990| 70 20 3d 20 6c 65 76 65 | 6c 2e 47 65 74 4c 6f 63 |p = leve|l.GetLoc|
|000009a0| 61 6c 50 6c 61 79 65 72 | 43 6f 6e 74 72 6f 6c 6c |alPlayer|Controll|
|000009b0| 65 72 20 28 29 3b 0d 0a | 0d 0a 09 2f 2f 53 6f 6d |er ();..|...//Som|
|000009c0| 65 74 69 6d 65 73 20 74 | 68 69 73 20 63 61 6e 27 |etimes t|his can'|
|000009d0| 74 20 62 65 20 66 6f 75 | 6e 64 2c 20 73 6f 20 75 |t be fou|nd, so u|
|000009e0| 73 65 20 61 6c 74 65 72 | 6e 61 74 69 76 65 20 6d |se alter|native m|
|000009f0| 65 74 68 6f 64 0d 0a 09 | 69 66 20 28 70 20 3d 3d |ethod...|if (p ==|
|00000a00| 20 6e 6f 6e 65 29 20 7b | 0d 0a 09 20 20 20 4c 6f | none) {|... Lo|
|00000a10| 67 28 22 75 74 76 3a 20 | 4c 65 76 65 6c 2e 47 65 |g("utv: |Level.Ge|
|00000a20| 74 4c 6f 63 61 6c 50 6c | 61 79 65 72 43 6f 6e 74 |tLocalPl|ayerCont|
|00000a30| 72 6f 6c 6c 65 72 20 77 | 61 73 20 66 61 6c 73 65 |roller w|as false|
|00000a40| 2c 20 74 72 79 69 6e 67 | 20 61 6c 74 65 72 6e 61 |, trying| alterna|
|00000a50| 74 65 20 6d 65 74 68 6f | 64 22 29 3b 0d 0a 09 20 |te metho|d");... |
|00000a60| 20 20 6f 68 20 3d 20 6e | 6f 6e 65 3b 0d 0a 09 20 | oh = n|one;... |
|00000a70| 20 20 66 6f 72 65 61 63 | 68 20 64 79 6e 61 6d 69 | foreac|h dynami|
|00000a80| 63 61 63 74 6f 72 73 28 | 63 6c 61 73 73 27 4f 4e |cactors(|class'ON|
|00000a90| 53 48 55 44 4f 6e 73 6c | 61 75 67 68 74 27 2c 20 |SHUDOnsl|aught', |
|00000aa0| 6f 68 29 20 7b 0d 0a 09 | 20 20 20 20 20 20 20 4c |oh) {...| L|
|00000ab0| 6f 67 28 22 75 74 76 3a | 20 46 6f 75 6e 64 20 6f |og("utv:| Found o|
|00000ac0| 6e 73 6c 61 75 67 68 74 | 20 68 75 64 20 77 69 74 |nslaught| hud wit|
|00000ad0| 68 20 61 6c 74 65 72 6e | 61 74 65 20 6d 65 74 68 |h altern|ate meth|
|00000ae0| 6f 64 22 29 3b 0d 0a 09 | 20 20 20 20 20 20 20 62 |od");...| b|
|00000af0| 72 65 61 6b 3b 0d 0a 09 | 20 20 20 7d 0d 0a 09 20 |reak;...| }... |
|00000b00| 20 20 69 66 20 28 6f 68 | 20 3d 3d 20 6e 6f 6e 65 | if (oh| == none|
|00000b10| 29 0d 0a 09 20 20 20 20 | 20 20 20 4c 6f 67 28 22 |)... | Log("|
|00000b20| 75 74 76 3a 20 41 6c 74 | 65 72 6e 61 74 65 20 4f |utv: Alt|ernate O|
|00000b30| 6e 73 6c 61 75 67 68 74 | 20 6e 6f 64 65 20 66 69 |nslaught| node fi|
|00000b40| 78 20 66 61 69 6c 65 64 | 22 29 3b 0d 0a 09 7d 0d |x failed|");...}.|
|00000b50| 0a 09 65 6c 73 65 20 7b | 0d 0a 20 20 20 20 20 20 |..else {|.. |
|00000b60| 20 20 6f 68 20 3d 20 4f | 4e 53 48 55 44 4f 6e 73 | oh = O|NSHUDOns|
|00000b70| 6c 61 75 67 68 74 28 70 | 2e 6d 79 48 55 44 29 3b |laught(p|.myHUD);|
|00000b80| 0d 0a 20 20 20 20 7d 0d | 0a 0d 0a 20 20 20 20 69 |.. }.|... i|
|00000b90| 66 20 28 6f 68 20 21 3d | 20 6e 6f 6e 65 29 20 7b |f (oh !=| none) {|
|00000ba0| 0d 0a 20 20 20 20 20 20 | 20 20 4c 6f 67 28 22 75 |.. | Log("u|
|00000bb0| 74 76 3a 20 50 72 65 70 | 61 72 69 6e 67 20 6f 6e |tv: Prep|aring on|
|00000bc0| 73 6c 61 75 67 68 74 20 | 48 55 44 20 66 6f 72 20 |slaught |HUD for |
|00000bd0| 70 6f 77 65 72 6c 69 6e | 6b 20 72 65 63 65 70 74 |powerlin|k recept|
|00000be0| 69 6f 6e 22 29 3b 0d 0a | 20 20 20 20 20 20 20 20 |ion");..| |
|00000bf0| 6f 68 2e 4c 69 6e 6b 41 | 63 74 6f 72 73 28 29 3b |oh.LinkA|ctors();|
|00000c00| 0d 0a 20 20 20 20 20 20 | 20 20 6f 68 2e 54 69 63 |.. | oh.Tic|
|00000c10| 6b 28 30 2e 31 29 3b 0d | 0a 20 20 20 20 7d 0d 0a |k(0.1);.|. }..|
|00000c20| 7d 0d 0a 0d 0a 73 69 6d | 75 6c 61 74 65 64 20 65 |}....sim|ulated e|
|00000c30| 76 65 6e 74 20 54 69 63 | 6b 20 28 66 6c 6f 61 74 |vent Tic|k (float|
|00000c40| 20 64 65 6c 74 61 74 69 | 6d 65 29 0d 0a 7b 0d 0a | deltati|me)..{..|
|00000c50| 09 6c 6f 63 61 6c 20 50 | 6c 61 79 65 72 43 6f 6e |.local P|layerCon|
|00000c60| 74 72 6f 6c 6c 65 72 20 | 70 3b 0d 0a 09 6c 6f 63 |troller |p;...loc|
|00000c70| 61 6c 20 73 74 72 69 6e | 67 20 73 3b 0d 0a 09 6c |al strin|g s;...l|
|00000c80| 6f 63 61 6c 20 73 74 72 | 69 6e 67 20 63 63 2c 20 |ocal str|ing cc, |
|00000c90| 77 3b 0d 0a 0d 0a 09 73 | 75 70 65 72 2e 54 69 63 |w;.....s|uper.Tic|
|00000ca0| 6b 20 28 64 65 6c 74 61 | 74 69 6d 65 29 3b 0d 0a |k (delta|time);..|
|00000cb0| 0d 0a 09 63 75 72 72 65 | 6e 74 54 69 6d 65 20 2b |...curre|ntTime +|
|00000cc0| 3d 20 64 65 6c 74 61 54 | 69 6d 65 3b 0d 0a 0d 0a |= deltaT|ime;....|
|00000cd0| 09 2f 2f 57 61 69 74 20 | 77 69 74 68 20 63 72 65 |.//Wait |with cre|
|00000ce0| 61 74 69 6e 67 20 74 68 | 65 20 69 6e 74 65 72 61 |ating th|e intera|
|00000cf0| 63 74 69 6f 6e 20 75 6e | 74 69 6c 20 77 65 20 6b |ction un|til we k|
|00000d00| 6e 6f 77 20 6f 75 72 20 | 72 6f 6c 65 0d 0a 09 69 |now our |role...i|
|00000d10| 66 20 28 28 47 65 74 53 | 74 61 74 65 4e 61 6d 65 |f ((GetS|tateName|
|00000d20| 20 28 29 20 21 3d 20 27 | 53 65 63 6f 6e 64 61 72 | () != '|Secondar|
|00000d30| 79 27 29 20 26 26 20 28 | 47 65 74 53 74 61 74 65 |y') && (|GetState|
|00000d40| 4e 61 6d 65 28 29 20 21 | 3d 20 27 50 72 69 6d 61 |Name() !|= 'Prima|
|00000d50| 72 79 27 29 29 20 7b 0d | 0a 09 09 6c 6f 67 20 28 |ry')) {.|...log (|
|00000d60| 22 75 74 76 3a 20 57 61 | 69 74 69 6e 67 20 66 6f |"utv: Wa|iting fo|
|00000d70| 72 20 72 6f 6c 65 20 69 | 6e 66 6f 72 6d 61 74 69 |r role i|nformati|
|00000d80| 6f 6e 22 29 3b 0d 0a 09 | 09 72 65 74 75 72 6e 3b |on");...|.return;|
|00000d90| 0d 0a 09 7d 0d 0a 0d 0a | 09 70 20 3d 20 4c 65 76 |...}....|.p = Lev|
|00000da0| 65 6c 2e 47 65 74 4c 6f | 63 61 6c 50 6c 61 79 65 |el.GetLo|calPlaye|
|00000db0| 72 43 6f 6e 74 72 6f 6c | 6c 65 72 28 29 3b 0d 0a |rControl|ler();..|
|00000dc0| 09 69 66 28 70 21 3d 6e | 6f 6e 65 20 26 26 20 21 |.if(p!=n|one && !|
|00000dd0| 4c 6f 63 61 6c 50 6f 73 | 53 65 74 29 7b 0d 0a 09 |LocalPos|Set){...|
|00000de0| 09 6c 6f 63 61 6c 50 6f | 73 53 65 74 3d 74 72 75 |.localPo|sSet=tru|
|00000df0| 65 3b 0d 0a 09 09 6c 6f | 63 61 6c 50 6f 73 3d 70 |e;....lo|calPos=p|
|00000e00| 2e 6c 6f 63 61 74 69 6f | 6e 3b 0d 0a 09 7d 0d 0a |.locatio|n;...}..|
|00000e10| 09 69 66 20 28 75 74 69 | 20 3d 3d 20 6e 6f 6e 65 |.if (uti| == none|
|00000e20| 29 20 7b 0d 0a 09 09 69 | 66 20 28 28 70 20 21 3d |) {....i|f ((p !=|
|00000e30| 20 6e 6f 6e 65 29 20 26 | 26 20 28 70 2e 50 6c 61 | none) &|& (p.Pla|
|00000e40| 79 65 72 20 21 3d 20 6e | 6f 6e 65 29 20 26 26 20 |yer != n|one) && |
|00000e50| 28 70 2e 50 6c 61 79 65 | 72 2e 49 6e 74 65 72 61 |(p.Playe|r.Intera|
|00000e60| 63 74 69 6f 6e 4d 61 73 | 74 65 72 20 21 3d 20 6e |ctionMas|ter != n|
|00000e70| 6f 6e 65 29 29 20 7b 0d | 0a 09 09 09 4c 6f 67 20 |one)) {.|....Log |
|00000e80| 28 22 75 74 76 3a 20 43 | 72 65 61 74 69 6e 67 20 |("utv: C|reating |
|00000e90| 75 74 76 49 6e 74 65 72 | 61 63 74 69 6f 6e 22 29 |utvInter|action")|
|00000ea0| 3b 0d 0a 09 09 09 75 74 | 69 20 3d 20 75 74 76 49 |;.....ut|i = utvI|
|00000eb0| 6e 74 65 72 61 63 74 69 | 6f 6e 20 28 70 2e 70 6c |nteracti|on (p.pl|
|00000ec0| 61 79 65 72 2e 49 6e 74 | 65 72 61 63 74 69 6f 6e |ayer.Int|eraction|
|00000ed0| 4d 61 73 74 65 72 2e 41 | 64 64 49 6e 74 65 72 61 |Master.A|ddIntera|
|00000ee0| 63 74 69 6f 6e 20 28 63 | 6c 61 73 73 27 75 74 76 |ction (c|lass'utv|
|00000ef0| 52 65 70 6c 69 63 61 74 | 69 6f 6e 27 2e 64 65 66 |Replicat|ion'.def|
|00000f00| 61 75 6c 74 2e 55 74 76 | 50 61 63 6b 61 67 65 20 |ault.Utv|Package |
|00000f10| 24 20 22 2e 75 74 76 49 | 6e 74 65 72 61 63 74 69 |$ ".utvI|nteracti|
|00000f20| 6f 6e 22 2c 20 70 2e 70 | 6c 61 79 65 72 29 29 3b |on", p.p|layer));|
|00000f30| 0d 0a 09 09 09 75 74 69 | 2e 53 65 74 53 74 61 74 |.....uti|.SetStat|
|00000f40| 65 20 28 47 65 74 53 74 | 61 74 65 4e 61 6d 65 20 |e (GetSt|ateName |
|00000f50| 28 29 20 3d 3d 20 27 50 | 72 69 6d 61 72 79 27 29 |() == 'P|rimary')|
|00000f60| 3b 0d 0a 09 09 09 75 74 | 69 2e 75 74 76 52 65 70 |;.....ut|i.utvRep|
|00000f70| 3d 73 65 6c 66 3b 0d 0a | 09 09 7d 0d 0a 09 7d 0d |=self;..|..}...}.|
|00000f80| 0a 0d 0a 09 2f 2f 43 68 | 65 63 6b 20 69 66 20 74 |....//Ch|eck if t|
|00000f90| 68 65 20 70 6c 61 79 65 | 72 20 68 61 73 20 75 73 |he playe|r has us|
|00000fa0| 65 64 20 75 74 76 73 61 | 79 0d 0a 09 69 66 20 28 |ed utvsa|y...if (|
|00000fb0| 63 6c 61 73 73 27 75 74 | 76 52 65 70 6c 69 63 61 |class'ut|vReplica|
|00000fc0| 74 69 6f 6e 27 2e 64 65 | 66 61 75 6c 74 2e 43 68 |tion'.de|fault.Ch|
|00000fd0| 61 74 53 74 72 69 6e 67 | 20 21 3d 20 22 22 29 20 |atString| != "") |
|00000fe0| 7b 0d 0a 09 09 2f 2f 49 | 66 20 79 6f 75 20 64 6f |{....//I|f you do|
|00000ff0| 6e 27 74 20 77 61 74 63 | 68 20 63 68 61 74 20 79 |n't watc|h chat y|
|00001000| 6f 75 20 61 72 65 20 6e | 6f 74 20 61 6c 6c 6f 77 |ou are n|ot allow|
|00001010| 65 64 20 74 6f 20 73 65 | 6e 64 20 65 69 74 68 65 |ed to se|nd eithe|
|00001020| 72 0d 0a 09 09 69 66 20 | 28 21 4d 75 74 65 43 68 |r....if |(!MuteCh|
|00001030| 61 74 29 20 7b 0d 0a 09 | 09 20 20 20 20 2f 2f 4d |at) {...|. //M|
|00001040| 61 6b 65 20 73 75 72 65 | 20 6d 65 73 73 61 67 65 |ake sure| message|
|00001050| 20 63 6f 6c 6f 72 20 69 | 73 20 73 65 74 20 74 6f | color i|s set to|
|00001060| 20 70 72 65 76 65 6e 74 | 20 63 6f 6c 6f 72 6e 69 | prevent| colorni|
|00001070| 63 6b 73 20 74 6f 20 69 | 6e 74 65 72 66 65 72 65 |cks to i|nterfere|
|00001080| 0d 0a 09 09 20 20 20 20 | 77 20 3d 20 63 68 72 28 |.... |w = chr(|
|00001090| 32 37 29 24 63 68 72 28 | 32 35 35 29 24 63 68 72 |27)$chr(|255)$chr|
|000010a0| 28 32 35 35 29 24 63 68 | 72 28 32 35 35 29 3b 0d |(255)$ch|r(255);.|
|000010b0| 0a 09 09 20 20 20 20 63 | 63 20 3d 20 22 22 3b 0d |... c|c = "";.|
|000010c0| 0a 09 09 20 20 20 20 69 | 66 20 28 47 65 74 53 74 |... i|f (GetSt|
|000010d0| 61 74 65 4e 61 6d 65 28 | 29 20 3d 3d 20 27 50 72 |ateName(|) == 'Pr|
|000010e0| 69 6d 61 72 79 27 29 0d | 0a 09 09 20 20 20 20 20 |imary').|... |
|000010f0| 20 20 20 63 63 20 3d 20 | 63 68 72 28 32 37 29 24 | cc = |chr(27)$|
|00001100| 22 e0 e0 60 22 3b 0d 0a | 09 09 09 73 20 3d 20 47 |"..`";..|...s = G|
|00001110| 65 74 55 72 6c 4f 70 74 | 69 6f 6e 20 28 22 4e 61 |etUrlOpt|ion ("Na|
|00001120| 6d 65 22 29 20 24 20 77 | 20 24 20 22 3a 20 22 20 |me") $ w| $ ": " |
|00001130| 24 20 63 63 20 24 20 63 | 6c 61 73 73 27 75 74 76 |$ cc $ c|lass'utv|
|00001140| 52 65 70 6c 69 63 61 74 | 69 6f 6e 27 2e 64 65 66 |Replicat|ion'.def|
|00001150| 61 75 6c 74 2e 43 68 61 | 74 53 74 72 69 6e 67 3b |ault.Cha|tString;|
|00001160| 0d 0a 09 09 09 75 74 69 | 2e 53 68 6f 77 43 68 61 |.....uti|.ShowCha|
|00001170| 74 20 28 73 29 3b 0d 0a | 09 09 09 53 65 6e 64 54 |t (s);..|...SendT|
|00001180| 6f 53 65 72 76 65 72 20 | 28 22 31 20 22 20 24 20 |oServer |("1 " $ |
|00001190| 73 29 3b 0d 0a 09 09 09 | 4c 6f 67 20 28 22 75 74 |s);.....|Log ("ut|
|000011a0| 76 3a 20 53 65 6e 64 69 | 6e 67 20 63 68 61 74 3a |v: Sendi|ng chat:|
|000011b0| 20 22 20 24 20 73 29 3b | 0d 0a 09 09 7d 0d 0a 09 | " $ s);|....}...|
|000011c0| 09 63 6c 61 73 73 27 75 | 74 76 52 65 70 6c 69 63 |.class'u|tvReplic|
|000011d0| 61 74 69 6f 6e 27 2e 64 | 65 66 61 75 6c 74 2e 43 |ation'.d|efault.C|
|000011e0| 68 61 74 53 74 72 69 6e | 67 20 3d 20 22 22 3b 0d |hatStrin|g = "";.|
|000011f0| 0a 09 7d 0d 0a 7d 0d 0a | 0d 0a 66 75 6e 63 74 69 |..}..}..|..functi|
|00001200| 6f 6e 20 53 65 6e 64 54 | 6f 53 65 72 76 65 72 20 |on SendT|oServer |
|00001210| 28 73 74 72 69 6e 67 20 | 73 29 0d 0a 7b 0d 0a 7d |(string |s)..{..}|
|00001220| 0d 0a 0d 0a 66 75 6e 63 | 74 69 6f 6e 20 53 65 6e |....func|tion Sen|
|00001230| 64 54 61 72 67 65 74 20 | 28 41 63 74 6f 72 20 74 |dTarget |(Actor t|
|00001240| 29 0d 0a 7b 0d 0a 7d 0d | 0a 0d 0a 73 69 6d 75 6c |)..{..}.|...simul|
|00001250| 61 74 65 64 20 66 75 6e | 63 74 69 6f 6e 20 47 65 |ated fun|ction Ge|
|00001260| 74 54 61 72 67 65 74 20 | 28 41 63 74 6f 72 20 74 |tTarget |(Actor t|
|00001270| 29 0d 0a 7b 0d 0a 09 6c | 6f 63 61 6c 20 50 6c 61 |)..{...l|ocal Pla|
|00001280| 79 65 72 43 6f 6e 74 72 | 6f 6c 6c 65 72 20 70 3b |yerContr|oller p;|
|00001290| 0d 0a 0d 0a 20 20 20 20 | 2f 2f 49 6e 20 73 65 65 |.... |//In see|
|000012a0| 61 6c 6c 20 6d 6f 64 65 | 2c 20 77 65 20 64 6f 6e |all mode|, we don|
|000012b0| 27 74 20 77 61 6e 74 20 | 74 6f 20 6d 65 73 73 20 |'t want |to mess |
|000012c0| 77 69 74 68 20 77 68 61 | 74 20 74 68 65 20 63 6c |with wha|t the cl|
|000012d0| 69 65 6e 74 20 69 73 20 | 6c 6f 6f 6b 69 6e 67 20 |ient is |looking |
|000012e0| 61 74 0d 0a 20 20 20 20 | 69 66 20 28 21 46 6f 6c |at.. |if (!Fol|
|000012f0| 6c 6f 77 50 72 69 6d 61 | 72 79 29 0d 0a 20 20 20 |lowPrima|ry).. |
|00001300| 20 20 20 20 20 72 65 74 | 75 72 6e 3b 0d 0a 0d 0a | ret|urn;....|
|00001310| 09 2f 2f 41 6c 77 61 79 | 73 20 75 70 64 61 74 65 |.//Alway|s update|
|00001320| 2c 20 73 69 6e 63 65 20 | 74 68 69 73 20 6f 6e 65 |, since |this one|
|00001330| 20 69 73 20 67 75 61 72 | 61 6e 74 65 65 64 20 74 | is guar|anteed t|
|00001340| 6f 20 62 65 20 63 6f 72 | 72 65 63 74 0d 0a 09 70 |o be cor|rect...p|
|00001350| 20 3d 20 6c 65 76 65 6c | 2e 47 65 74 4c 6f 63 61 | = level|.GetLoca|
|00001360| 6c 50 6c 61 79 65 72 43 | 6f 6e 74 72 6f 6c 6c 65 |lPlayerC|ontrolle|
|00001370| 72 20 28 29 3b 0d 0a 09 | 69 66 28 70 3d 3d 74 20 |r ();...|if(p==t |
|00001380| 7c 7c 20 74 3d 3d 70 2e | 70 61 77 6e 29 7b 0d 0a ||| t==p.|pawn){..|
|00001390| 09 09 69 66 28 6c 61 73 | 74 56 69 65 77 65 64 53 |..if(las|tViewedS|
|000013a0| 65 6c 66 3e 32 29 7b 0d | 0a 09 09 20 20 20 20 69 |elf>2){.|... i|
|000013b0| 66 20 28 70 2e 56 69 65 | 77 54 61 72 67 65 74 20 |f (p.Vie|wTarget |
|000013c0| 21 3d 20 74 29 0d 0a 20 | 20 20 20 09 09 09 70 2e |!= t).. | ...p.|
|000013d0| 53 65 74 56 69 65 77 54 | 61 72 67 65 74 20 28 74 |SetViewT|arget (t|
|000013e0| 29 3b 0d 0a 09 09 09 76 | 69 65 77 69 6e 67 53 65 |);.....v|iewingSe|
|000013f0| 6c 66 3d 74 72 75 65 3b | 0d 0a 09 09 7d 65 6c 73 |lf=true;|....}els|
|00001400| 65 7b 0d 0a 09 09 09 6c | 61 73 74 56 69 65 77 65 |e{.....l|astViewe|
|00001410| 64 53 65 6c 66 2b 2b 3b | 0d 0a 09 09 7d 0d 0a 09 |dSelf++;|....}...|
|00001420| 7d 65 6c 73 65 7b 0d 0a | 09 09 76 69 65 77 69 6e |}else{..|..viewin|
|00001430| 67 53 65 6c 66 3d 66 61 | 6c 73 65 3b 0d 0a 09 09 |gSelf=fa|lse;....|
|00001440| 6c 61 73 74 56 69 65 77 | 65 64 53 65 6c 66 3d 30 |lastView|edSelf=0|
|00001450| 3b 0d 0a 09 09 69 66 20 | 28 70 2e 56 69 65 77 54 |;....if |(p.ViewT|
|00001460| 61 72 67 65 74 20 21 3d | 20 74 29 0d 0a 20 20 20 |arget !=| t).. |
|00001470| 20 09 09 70 2e 53 65 74 | 56 69 65 77 54 61 72 67 | ..p.Set|ViewTarg|
|00001480| 65 74 20 28 74 29 3b 0d | 0a 09 7d 0d 0a 7d 0d 0a |et (t);.|..}..}..|
|00001490| 0d 0a 73 69 6d 75 6c 61 | 74 65 64 20 66 75 6e 63 |..simula|ted func|
|000014a0| 74 69 6f 6e 20 47 6f 74 | 49 6e 69 74 4d 73 67 20 |tion Got|InitMsg |
|000014b0| 28 73 74 72 69 6e 67 20 | 73 29 0d 0a 7b 0d 0a 20 |(string |s)..{.. |
|000014c0| 09 6c 6f 63 61 6c 20 73 | 74 72 69 6e 67 20 74 6d |.local s|tring tm|
|000014d0| 70 73 3b 0d 0a 20 09 6c | 6f 63 61 6c 20 69 6e 74 |ps;.. .l|ocal int|
|000014e0| 20 69 2c 61 3b 0d 0a 0d | 0a 20 09 2f 2f 50 61 72 | i,a;...|. .//Par|
|000014f0| 73 65 20 6f 75 74 20 74 | 68 65 20 76 61 6c 75 65 |se out t|he value|
|00001500| 73 0d 0a 20 09 69 20 3d | 20 49 6e 53 74 72 20 28 |s.. .i =| InStr (|
|00001510| 73 2c 20 22 20 22 29 3b | 0d 0a 20 09 74 6d 70 73 |s, " ");|.. .tmps|
|00001520| 20 3d 20 4d 69 64 20 28 | 73 2c 20 30 2c 20 69 29 | = Mid (|s, 0, i)|
|00001530| 3b 0d 0a 20 09 61 20 3d | 20 69 6e 74 20 28 74 6d |;.. .a =| int (tm|
|00001540| 70 73 29 3b 0d 0a 09 69 | 66 20 28 61 20 3d 3d 20 |ps);...i|f (a == |
|00001550| 31 29 0d 0a 09 09 47 6f | 74 6f 53 74 61 74 65 20 |1)....Go|toState |
|00001560| 28 27 50 72 69 6d 61 72 | 79 27 29 3b 0d 0a 09 65 |('Primar|y');...e|
|00001570| 6c 73 65 0d 0a 09 09 47 | 6f 74 6f 53 74 61 74 65 |lse....G|otoState|
|00001580| 20 28 27 53 65 63 6f 6e | 64 61 72 79 27 29 3b 0d | ('Secon|dary');.|
|00001590| 0a 20 09 73 20 3d 20 4d | 69 64 20 28 73 2c 20 69 |. .s = M|id (s, i|
|000015a0| 20 2b 20 31 29 3b 0d 0a | 0d 0a 20 09 61 20 3d 20 | + 1);..|.. .a = |
|000015b0| 69 6e 74 20 28 73 29 3b | 0d 0a 0d 0a 20 09 69 66 |int (s);|.... .if|
|000015c0| 20 28 61 20 3d 3d 20 33 | 29 20 7b 20 20 20 20 20 | (a == 3|) { |
|000015d0| 20 20 20 20 20 20 20 20 | 2f 2f 4c 6f 6f 6b 69 6e | |//Lookin|
|000015e0| 67 20 61 74 20 61 20 73 | 65 72 76 65 72 20 64 65 |g at a s|erver de|
|000015f0| 6d 6f 0d 0a 20 09 20 20 | 20 20 4e 6f 50 72 69 6d |mo.. . | NoPrim|
|00001600| 61 72 79 3d 74 72 75 65 | 3b 0d 0a 20 09 20 20 20 |ary=true|;.. . |
|00001610| 20 49 73 44 65 6d 6f 3d | 74 72 75 65 3b 0d 0a 20 | IsDemo=|true;.. |
|00001620| 09 20 20 20 20 4f 6c 64 | 46 6f 6c 6c 6f 77 3d 66 |. Old|Follow=f|
|00001630| 61 6c 73 65 3b 0d 0a 20 | 09 20 20 20 20 46 6f 6c |alse;.. |. Fol|
|00001640| 6c 6f 77 50 72 69 6d 61 | 72 79 3d 66 61 6c 73 65 |lowPrima|ry=false|
|00001650| 3b 0d 0a 20 09 20 20 20 | 20 53 65 65 41 6c 6c 3d |;.. . | SeeAll=|
|00001660| 74 72 75 65 3b 0d 0a 20 | 09 20 20 20 20 46 72 65 |true;.. |. Fre|
|00001670| 65 46 6c 69 67 68 74 3d | 74 72 75 65 3b 0d 0a 20 |eFlight=|true;.. |
|00001680| 09 7d 0d 0a 20 09 65 6c | 73 65 20 69 66 20 28 61 |.}.. .el|se if (a|
|00001690| 20 3d 3d 20 34 29 20 7b | 20 20 20 20 20 20 20 20 | == 4) {| |
|000016a0| 2f 2f 43 6c 69 65 6e 74 | 20 64 65 6d 6f 0d 0a 20 |//Client| demo.. |
|000016b0| 09 20 20 20 20 49 73 44 | 65 6d 6f 3d 74 72 75 65 |. IsD|emo=true|
|000016c0| 3b 0d 0a 20 20 20 20 20 | 20 20 20 53 65 65 41 6c |;.. | SeeAl|
|000016d0| 6c 3d 66 61 6c 73 65 3b | 0d 0a 20 20 20 20 20 20 |l=false;|.. |
|000016e0| 20 20 4e 6f 50 72 69 6d | 61 72 79 3d 66 61 6c 73 | NoPrim|ary=fals|
|000016f0| 65 3b 0d 0a 20 09 7d 0d | 0a 0d 0a 20 09 65 6c 73 |e;.. .}.|... .els|
|00001700| 65 20 69 66 20 28 61 20 | 3d 3d 20 32 29 7b 20 20 |e if (a |== 2){ |
|00001710| 20 20 20 20 20 20 20 20 | 20 20 20 20 2f 2f 4e 6f | | //No|
|00001720| 70 72 69 6d 61 72 79 20 | 61 6e 64 20 73 65 65 61 |primary |and seea|
|00001730| 6c 6c 0d 0a 20 09 09 53 | 65 65 41 6c 6c 3d 74 72 |ll.. ..S|eeAll=tr|
|00001740| 75 65 3b 0d 0a 20 09 09 | 4e 6f 50 72 69 6d 61 72 |ue;.. ..|NoPrimar|
|00001750| 79 3d 74 72 75 65 3b 0d | 0a 20 09 09 4f 6c 64 46 |y=true;.|. ..OldF|
|00001760| 6f 6c 6c 6f 77 3d 66 61 | 6c 73 65 3b 0d 0a 09 09 |ollow=fa|lse;....|
|00001770| 46 6f 6c 6c 6f 77 50 72 | 69 6d 61 72 79 3d 66 61 |FollowPr|imary=fa|
|00001780| 6c 73 65 3b 0d 0a 09 09 | 46 72 65 65 46 6c 69 67 |lse;....|FreeFlig|
|00001790| 68 74 3d 74 72 75 65 3b | 0d 0a 09 7d 20 65 6c 73 |ht=true;|...} els|
|000017a0| 65 20 69 66 20 28 61 20 | 3d 3d 20 31 29 7b 20 20 |e if (a |== 1){ |
|000017b0| 20 20 20 20 20 2f 2f 53 | 65 65 61 6c 6c 20 77 69 | //S|eeall wi|
|000017c0| 74 68 20 70 72 69 6d 61 | 72 79 0d 0a 09 09 53 65 |th prima|ry....Se|
|000017d0| 65 41 6c 6c 3d 74 72 75 | 65 3b 0d 0a 20 09 09 4e |eAll=tru|e;.. ..N|
|000017e0| 6f 50 72 69 6d 61 72 79 | 3d 66 61 6c 73 65 3b 0d |oPrimary|=false;.|
|000017f0| 0a 09 7d 65 6c 73 65 7b | 20 20 20 20 20 20 20 20 |..}else{| |
|00001800| 20 20 20 20 20 20 20 20 | 20 20 20 20 2f 2f 52 65 | | //Re|
|00001810| 67 75 6c 61 72 20 70 72 | 69 6d 61 72 79 0d 0a 09 |gular pr|imary...|
|00001820| 09 53 65 65 41 6c 6c 3d | 66 61 6c 73 65 3b 0d 0a |.SeeAll=|false;..|
|00001830| 20 09 09 4e 6f 50 72 69 | 6d 61 72 79 3d 66 61 6c | ..NoPri|mary=fal|
|00001840| 73 65 3b 0d 0a 09 7d 0d | 0a 7d 0d 0a 0d 0a 73 69 |se;...}.|.}....si|
|00001850| 6d 75 6c 61 74 65 64 20 | 66 75 6e 63 74 69 6f 6e |mulated |function|
|00001860| 20 47 65 74 46 72 6f 6d | 53 65 72 76 65 72 20 28 | GetFrom|Server (|
|00001870| 73 74 72 69 6e 67 20 73 | 29 0d 0a 7b 0d 0a 09 6c |string s|)..{...l|
|00001880| 6f 63 61 6c 20 69 6e 74 | 20 69 2c 20 63 6d 64 3b |ocal int| i, cmd;|
|00001890| 0d 0a 09 6c 6f 63 61 6c | 20 73 74 72 69 6e 67 20 |...local| string |
|000018a0| 74 6d 70 3b 0d 0a 0d 0a | 09 2f 2f 46 69 6e 64 20 |tmp;....|.//Find |
|000018b0| 74 68 65 20 63 6f 6d 6d | 61 6e 64 20 6e 75 6d 62 |the comm|and numb|
|000018c0| 65 72 0d 0a 09 69 20 3d | 20 49 6e 53 74 72 20 28 |er...i =| InStr (|
|000018d0| 73 2c 20 22 20 22 29 3b | 0d 0a 09 74 6d 70 20 3d |s, " ");|...tmp =|
|000018e0| 20 4d 69 64 20 28 73 2c | 20 30 2c 20 69 29 3b 0d | Mid (s,| 0, i);.|
|000018f0| 0a 09 63 6d 64 20 3d 20 | 69 6e 74 20 28 74 6d 70 |..cmd = |int (tmp|
|00001900| 29 3b 0d 0a 09 73 20 3d | 20 4d 69 64 20 28 73 2c |);...s =| Mid (s,|
|00001910| 20 69 20 2b 20 31 29 3b | 0d 0a 0d 0a 09 73 77 69 | i + 1);|.....swi|
|00001920| 74 63 68 20 28 63 6d 64 | 29 20 7b 0d 0a 09 09 63 |tch (cmd|) {....c|
|00001930| 61 73 65 20 38 3a 0d 0a | 09 09 09 4c 6f 67 28 22 |ase 8:..|...Log("|
|00001940| 75 74 76 3a 20 47 6f 74 | 20 69 6e 69 74 20 22 20 |utv: Got| init " |
|00001950| 24 20 73 29 3b 0d 0a 09 | 09 09 47 6f 74 49 6e 69 |$ s);...|..GotIni|
|00001960| 74 4d 73 67 28 73 29 3b | 0d 0a 09 09 09 62 72 65 |tMsg(s);|.....bre|
|00001970| 61 6b 3b 0d 0a 09 7d 0d | 0a 0d 0a 09 2f 2f 4e 6f |ak;...}.|....//No|
|00001980| 20 6e 65 65 64 20 74 6f | 20 63 68 65 63 6b 20 74 | need to| check t|
|00001990| 68 65 20 66 6f 6c 6c 6f | 77 69 6e 67 20 69 66 20 |he follo|wing if |
|000019a0| 77 65 20 61 72 65 20 6e | 6f 74 20 69 6e 69 74 69 |we are n|ot initi|
|000019b0| 61 6c 69 7a 65 64 20 79 | 65 74 0d 0a 09 69 66 20 |alized y|et...if |
|000019c0| 28 75 74 69 20 3d 3d 20 | 6e 6f 6e 65 29 0d 0a 09 |(uti == |none)...|
|000019d0| 09 72 65 74 75 72 6e 3b | 0d 0a 0d 0a 09 73 77 69 |.return;|.....swi|
|000019e0| 74 63 68 20 28 63 6d 64 | 29 20 7b 0d 0a 09 09 63 |tch (cmd|) {....c|
|000019f0| 61 73 65 20 31 3a 0d 0a | 09 09 09 69 66 20 28 21 |ase 1:..|...if (!|
|00001a00| 4d 75 74 65 43 68 61 74 | 29 0d 0a 09 09 09 09 75 |MuteChat|)......u|
|00001a10| 74 69 2e 53 68 6f 77 43 | 68 61 74 20 28 73 29 3b |ti.ShowC|hat (s);|
|00001a20| 0d 0a 09 09 09 62 72 65 | 61 6b 3b 0d 0a 09 09 63 |.....bre|ak;....c|
|00001a30| 61 73 65 20 32 3a 0d 0a | 09 09 09 52 65 63 65 69 |ase 2:..|...Recei|
|00001a40| 76 65 4d 6f 76 65 6d 65 | 6e 74 20 28 73 29 3b 0d |veMoveme|nt (s);.|
|00001a50| 0a 09 09 09 62 72 65 61 | 6b 3b 0d 0a 09 09 63 61 |....brea|k;....ca|
|00001a60| 73 65 20 34 3a 0d 0a 09 | 09 09 75 74 69 2e 47 6f |se 4:...|..uti.Go|
|00001a70| 74 53 74 61 74 75 73 20 | 28 73 29 3b 0d 0a 09 09 |tStatus |(s);....|
|00001a80| 09 62 72 65 61 6b 3b 0d | 0a 09 09 63 61 73 65 20 |.break;.|...case |
|00001a90| 37 3a 0d 0a 09 09 09 75 | 74 69 2e 47 6f 74 42 69 |7:.....u|ti.GotBi|
|00001aa0| 67 53 74 61 74 75 73 20 | 28 73 29 3b 0d 0a 09 09 |gStatus |(s);....|
|00001ab0| 09 62 72 65 61 6b 3b 0d | 0a 09 7d 0d 0a 7d 0d 0a |.break;.|..}..}..|
|00001ac0| 0d 0a 2f 2f 53 74 75 62 | 20 66 75 6e 63 74 69 6f |..//Stub| functio|
|00001ad0| 6e 0d 0a 73 69 6d 75 6c | 61 74 65 64 20 66 75 6e |n..simul|ated fun|
|00001ae0| 63 74 69 6f 6e 20 52 65 | 63 65 69 76 65 4d 6f 76 |ction Re|ceiveMov|
|00001af0| 65 6d 65 6e 74 20 28 73 | 74 72 69 6e 67 20 73 29 |ement (s|tring s)|
|00001b00| 0d 0a 7b 0d 0a 7d 0d 0a | 0d 0a 65 78 65 63 20 66 |..{..}..|..exec f|
|00001b10| 75 6e 63 74 69 6f 6e 20 | 75 74 76 73 61 79 20 28 |unction |utvsay (|
|00001b20| 73 74 72 69 6e 67 20 73 | 29 0d 0a 7b 0d 0a 09 4c |string s|)..{...L|
|00001b30| 6f 67 20 28 22 75 74 76 | 3a 20 47 6f 74 20 75 74 |og ("utv|: Got ut|
|00001b40| 76 73 61 79 3a 20 22 20 | 24 20 73 29 3b 0d 0a 7d |vsay: " |$ s);..}|
|00001b50| 0d 0a 0d 0a 2f 2f 2f 2f | 2f 2f 2f 2f 2f 2f 2f 2f |....////|////////|
|00001b60| 2f 2f 2f 2f 2f 2f 2f 2f | 2f 2f 2f 2f 2f 2f 2f 2f |////////|////////|
|00001b70| 2f 2f 2f 2f 2f 2f 2f 2f | 2f 2f 2f 2f 2f 2f 2f 2f |////////|////////|
|00001b80| 2f 2f 2f 2f 2f 0d 0a 2f | 2f 2f 2f 2f 2f 2f 2f 2f |/////../|////////|
|00001b90| 2f 2f 2f 2f 2f 2f 2f 2f | 2f 2f 2f 2f 2f 2f 2f 2f |////////|////////|
|00001ba0| 2f 2f 2f 2f 2f 2f 2f 2f | 2f 2f 2f 2f 2f 2f 2f 2f |////////|////////|
|00001bb0| 2f 2f 2f 2f 2f 2f 2f 2f | 0d 0a 0d 0a 73 74 61 74 |////////|....stat|
|00001bc0| 65 20 50 72 69 6d 61 72 | 79 20 7b 0d 0a 0d 0a 09 |e Primar|y {.....|
|00001bd0| 73 69 6d 75 6c 61 74 65 | 64 20 66 75 6e 63 74 69 |simulate|d functi|
|00001be0| 6f 6e 20 42 65 67 69 6e | 53 74 61 74 65 20 28 29 |on Begin|State ()|
|00001bf0| 0d 0a 09 7b 0d 0a 09 09 | 6c 6f 67 20 28 22 75 74 |...{....|log ("ut|
|00001c00| 76 3a 20 45 6e 74 65 72 | 69 6e 67 20 70 72 69 6d |v: Enter|ing prim|
|00001c10| 61 72 79 20 73 74 61 74 | 65 22 29 3b 0d 0a 09 7d |ary stat|e");...}|
|00001c20| 0d 0a 0d 0a 09 73 69 6d | 75 6c 61 74 65 64 20 66 |.....sim|ulated f|
|00001c30| 75 6e 63 74 69 6f 6e 20 | 43 68 65 63 6b 47 61 6d |unction |CheckGam|
|00001c40| 65 45 6e 64 20 28 29 0d | 0a 09 7b 0d 0a 09 09 6c |eEnd ().|..{....l|
|00001c50| 6f 63 61 6c 20 50 6c 61 | 79 65 72 43 6f 6e 74 72 |ocal Pla|yerContr|
|00001c60| 6f 6c 6c 65 72 20 70 3b | 0d 0a 0d 0a 09 09 69 66 |oller p;|......if|
|00001c70| 20 28 21 77 61 73 45 6e | 64 65 64 29 20 7b 0d 0a | (!wasEn|ded) {..|
|00001c80| 09 09 09 70 20 3d 20 4c | 65 76 65 6c 2e 47 65 74 |...p = L|evel.Get|
|00001c90| 4c 6f 63 61 6c 50 6c 61 | 79 65 72 43 6f 6e 74 72 |LocalPla|yerContr|
|00001ca0| 6f 6c 6c 65 72 28 29 3b | 0d 0a 09 09 09 69 66 20 |oller();|.....if |
|00001cb0| 28 70 2e 49 73 49 6e 53 | 74 61 74 65 28 27 47 61 |(p.IsInS|tate('Ga|
|00001cc0| 6d 65 45 6e 64 65 64 27 | 29 29 20 7b 0d 0a 09 09 |meEnded'|)) {....|
|00001cd0| 09 09 77 61 73 45 6e 64 | 65 64 20 3d 20 74 72 75 |..wasEnd|ed = tru|
|00001ce0| 65 3b 0d 0a 09 09 09 09 | 53 65 6e 64 54 6f 53 65 |e;......|SendToSe|
|00001cf0| 72 76 65 72 20 28 22 33 | 22 29 3b 0d 0a 09 09 09 |rver ("3|");.....|
|00001d00| 09 4c 6f 67 20 28 22 75 | 74 76 3a 20 53 65 6e 64 |.Log ("u|tv: Send|
|00001d10| 20 67 61 6d 65 65 6e 64 | 20 74 6f 20 73 65 72 76 | gameend| to serv|
|00001d20| 65 72 22 29 3b 0d 0a 09 | 09 09 7d 0d 0a 09 09 7d |er");...|..}....}|
|00001d30| 0d 0a 09 7d 0d 0a 0d 0a | 09 73 69 6d 75 6c 61 74 |...}....|.simulat|
|00001d40| 65 64 20 66 75 6e 63 74 | 69 6f 6e 20 53 65 6e 64 |ed funct|ion Send|
|00001d50| 49 6e 74 65 72 70 6f 6c | 56 61 6c 75 65 73 20 28 |Interpol|Values (|
|00001d60| 29 0d 0a 09 7b 0d 0a 09 | 09 6c 6f 63 61 6c 20 73 |)...{...|.local s|
|00001d70| 74 72 69 6e 67 20 73 3b | 0d 0a 09 09 6c 6f 63 61 |tring s;|....loca|
|00001d80| 6c 20 70 6c 61 79 65 72 | 63 6f 6e 74 72 6f 6c 6c |l player|controll|
|00001d90| 65 72 20 70 3b 0d 0a 0d | 0a 09 09 70 20 3d 20 6c |er p;...|...p = l|
|00001da0| 65 76 65 6c 2e 47 65 74 | 4c 6f 63 61 6c 50 6c 61 |evel.Get|LocalPla|
|00001db0| 79 65 72 43 6f 6e 74 72 | 6f 6c 6c 65 72 20 28 29 |yerContr|oller ()|
|00001dc0| 3b 0d 0a 09 09 73 20 3d | 20 22 32 20 22 20 2f 2a |;....s =| "2 " /*|
|00001dd0| 20 24 20 63 75 72 72 65 | 6e 74 54 69 6d 65 20 24 | $ curre|ntTime $|
|00001de0| 20 22 20 22 20 2a 2f 20 | 24 20 70 2e 4c 6f 63 61 | " " */ |$ p.Loca|
|00001df0| 74 69 6f 6e 20 24 20 22 | 20 22 20 24 20 70 2e 52 |tion $ "| " $ p.R|
|00001e00| 6f 74 61 74 69 6f 6e 3b | 0d 0a 09 09 53 65 6e 64 |otation;|....Send|
|00001e10| 54 6f 53 65 72 76 65 72 | 20 28 73 29 3b 0d 0a 09 |ToServer| (s);...|
|00001e20| 7d 0d 0a 0d 0a 09 73 69 | 6d 75 6c 61 74 65 64 20 |}.....si|mulated |
|00001e30| 66 75 6e 63 74 69 6f 6e | 20 54 69 63 6b 20 28 66 |function| Tick (f|
|00001e40| 6c 6f 61 74 20 64 65 6c | 74 61 29 0d 0a 09 7b 0d |loat del|ta)...{.|
|00001e50| 0a 09 09 6c 6f 63 61 6c | 20 50 6c 61 79 65 72 43 |...local| PlayerC|
|00001e60| 6f 6e 74 72 6f 6c 6c 65 | 72 20 70 3b 0d 0a 0d 0a |ontrolle|r p;....|
|00001e70| 09 09 67 6c 6f 62 61 6c | 2e 74 69 63 6b 20 28 64 |..global|.tick (d|
|00001e80| 65 6c 74 61 29 3b 0d 0a | 0d 0a 09 09 2f 2f 53 65 |elta);..|....//Se|
|00001e90| 6e 64 20 6f 75 74 20 76 | 61 6c 75 65 73 20 66 6f |nd out v|alues fo|
|00001ea0| 72 20 69 6e 74 65 72 70 | 6f 6c 61 74 69 6f 6e 0d |r interp|olation.|
|00001eb0| 0a 09 09 69 66 20 28 63 | 75 72 72 65 6e 74 54 69 |...if (c|urrentTi|
|00001ec0| 6d 65 20 2d 20 4c 61 73 | 74 53 65 6e 64 20 3e 20 |me - Las|tSend > |
|00001ed0| 30 2e 35 29 20 7b 0d 0a | 09 09 09 70 20 3d 20 6c |0.5) {..|...p = l|
|00001ee0| 65 76 65 6c 2e 47 65 74 | 4c 6f 63 61 6c 50 6c 61 |evel.Get|LocalPla|
|00001ef0| 79 65 72 43 6f 6e 74 72 | 6f 6c 6c 65 72 20 28 29 |yerContr|oller ()|
|00001f00| 3b 0d 0a 09 09 09 53 65 | 6e 64 49 6e 74 65 72 70 |;.....Se|ndInterp|
|00001f10| 6f 6c 56 61 6c 75 65 73 | 20 28 29 3b 0d 0a 09 09 |olValues| ();....|
|00001f20| 09 4c 61 73 74 53 65 6e | 64 20 3d 20 63 75 72 72 |.LastSen|d = curr|
|00001f30| 65 6e 74 54 69 6d 65 3b | 0d 0a 0d 0a 09 09 09 53 |entTime;|.......S|
|00001f40| 65 6e 64 54 61 72 67 65 | 74 20 28 70 2e 56 69 65 |endTarge|t (p.Vie|
|00001f50| 77 54 61 72 67 65 74 29 | 3b 0d 0a 09 09 7d 0d 0a |wTarget)|;....}..|
|00001f60| 0d 0a 09 09 2f 2f 43 68 | 65 63 6b 20 69 66 20 74 |....//Ch|eck if t|
|00001f70| 68 65 20 67 61 6d 65 20 | 68 61 73 20 73 74 61 72 |he game |has star|
|00001f80| 74 65 64 0d 0a 09 09 43 | 68 65 63 6b 47 61 6d 65 |ted....C|heckGame|
|00001f90| 45 6e 64 20 28 29 3b 0d | 0a 09 7d 0d 0a 0d 0a 7d |End ();.|..}....}|
|00001fa0| 0d 0a 0d 0a 73 74 61 74 | 65 20 53 65 63 6f 6e 64 |....stat|e Second|
|00001fb0| 61 72 79 0d 0a 7b 0d 0a | 09 2f 2f 45 69 74 68 65 |ary..{..|.//Eithe|
|00001fc0| 72 20 78 32 20 6f 72 20 | 62 6f 74 68 20 78 32 20 |r x2 or |both x2 |
|00001fd0| 61 6e 64 20 78 33 20 63 | 61 6e 20 62 65 20 7a 65 |and x3 c|an be ze|
|00001fe0| 72 6f 2c 20 61 6e 64 20 | 69 6e 64 69 63 61 74 65 |ro, and |indicate|
|00001ff0| 73 20 6e 6f 20 6b 6e 6f | 77 6e 20 69 6e 66 6f 20 |s no kno|wn info |
|00002000| 61 74 20 74 68 61 74 20 | 74 69 6d 65 0d 0a 09 73 |at that |time...s|
|00002010| 69 6d 75 6c 61 74 65 64 | 20 66 75 6e 63 74 69 6f |imulated| functio|
|00002020| 6e 20 43 61 6c 63 75 6c | 61 74 65 49 6e 74 65 72 |n Calcul|ateInter|
|00002030| 70 6f 6c 20 28 69 6e 74 | 20 63 6f 72 64 2c 20 66 |pol (int| cord, f|
|00002040| 6c 6f 61 74 20 78 31 2c | 20 66 6c 6f 61 74 20 78 |loat x1,| float x|
|00002050| 32 2c 20 66 6c 6f 61 74 | 20 78 33 2c 20 66 6c 6f |2, float| x3, flo|
|00002060| 61 74 20 79 31 2c 20 66 | 6c 6f 61 74 20 79 32 2c |at y1, f|loat y2,|
|00002070| 20 66 6c 6f 61 74 20 79 | 33 29 0d 0a 09 7b 0d 0a | float y|3)...{..|
|00002080| 09 09 6c 6f 63 61 6c 20 | 54 49 6e 74 65 72 70 6f |..local |TInterpo|
|00002090| 6c 20 70 3b 0d 0a 0d 0a | 09 09 2f 2f 52 65 74 72 |l p;....|..//Retr|
|000020a0| 69 65 76 65 20 6c 61 73 | 74 20 6f 6e 65 0d 0a 09 |ieve las|t one...|
|000020b0| 09 70 20 3d 20 69 6e 74 | 65 72 70 6f 6c 2e 63 6f |.p = int|erpol.co|
|000020c0| 72 64 73 5b 63 6f 72 64 | 5d 3b 0d 0a 0d 0a 09 09 |rds[cord|];......|
|000020d0| 2f 2f 4a 75 73 74 20 73 | 74 6f 70 20 69 66 20 77 |//Just s|top if w|
|000020e0| 65 20 64 6f 6e 27 74 20 | 65 76 65 6e 20 68 61 76 |e don't |even hav|
|000020f0| 65 20 74 77 6f 20 70 6f | 69 6e 74 73 0d 0a 09 09 |e two po|ints....|
|00002100| 69 66 20 28 78 32 20 3d | 3d 20 30 29 20 7b 0d 0a |if (x2 =|= 0) {..|
|00002110| 09 09 09 78 32 20 3d 20 | 78 31 3b 0d 0a 09 09 09 |...x2 = |x1;.....|
|00002120| 79 32 20 3d 20 79 31 3b | 0d 0a 09 09 7d 0d 0a 0d |y2 = y1;|....}...|
|00002130| 0a 09 09 70 2e 79 31 20 | 3d 20 79 31 3b 0d 0a 09 |...p.y1 |= y1;...|
|00002140| 09 70 2e 79 32 20 3d 20 | 79 32 3b 0d 0a 0d 0a 09 |.p.y2 = |y2;.....|
|00002150| 09 2f 2f 43 61 6c 63 75 | 6c 61 74 65 20 73 74 61 |.//Calcu|late sta|
|00002160| 72 74 20 61 6e 64 20 65 | 6e 64 73 6c 6f 70 65 0d |rt and e|ndslope.|
|00002170| 0a 09 09 70 2e 6b 31 20 | 3d 20 70 2e 6b 32 3b 0d |...p.k1 |= p.k2;.|
|00002180| 0a 0d 0a 09 09 2f 2f 49 | 66 20 6e 6f 20 69 6e 66 |.....//I|f no inf|
|00002190| 6f 20 61 74 20 78 33 2c | 20 6d 61 6b 65 20 74 68 |o at x3,| make th|
|000021a0| 65 20 64 65 72 69 76 61 | 74 69 76 65 20 7a 65 72 |e deriva|tive zer|
|000021b0| 6f 0d 0a 09 09 69 66 20 | 28 78 33 20 3d 3d 20 30 |o....if |(x3 == 0|
|000021c0| 29 0d 0a 09 09 09 70 2e | 6b 32 20 3d 20 30 3b 0d |).....p.|k2 = 0;.|
|000021d0| 0a 09 09 65 6c 73 65 0d | 0a 09 09 09 70 2e 6b 32 |...else.|....p.k2|
|000021e0| 20 3d 20 28 79 33 20 2d | 20 79 31 29 20 2f 20 28 | = (y3 -| y1) / (|
|000021f0| 78 33 20 2d 20 78 31 29 | 3b 0d 0a 0d 0a 09 09 70 |x3 - x1)|;......p|
|00002200| 2e 68 31 20 3d 20 78 32 | 20 2d 20 78 31 3b 0d 0a |.h1 = x2| - x1;..|
|00002210| 09 09 70 2e 64 79 20 3d | 20 79 32 20 2d 20 79 31 |..p.dy =| y2 - y1|
|00002220| 3b 0d 0a 0d 0a 09 09 70 | 2e 67 31 20 3d 20 70 2e |;......p|.g1 = p.|
|00002230| 68 31 20 2a 20 70 2e 6b | 31 20 2d 20 70 2e 64 79 |h1 * p.k|1 - p.dy|
|00002240| 3b 0d 0a 09 09 70 2e 63 | 31 20 3d 20 32 20 2a 20 |;....p.c|1 = 2 * |
|00002250| 70 2e 64 79 20 2d 20 70 | 2e 68 31 20 2a 20 28 70 |p.dy - p|.h1 * (p|
|00002260| 2e 6b 31 20 2b 20 70 2e | 6b 32 29 3b 0d 0a 0d 0a |.k1 + p.|k2);....|
|00002270| 09 09 69 6e 74 65 72 70 | 6f 6c 2e 63 6f 72 64 73 |..interp|ol.cords|
|00002280| 5b 63 6f 72 64 5d 20 3d | 20 70 3b 0d 0a 0d 0a 09 |[cord] =| p;.....|
|00002290| 09 2f 2f 64 6f 68 0d 0a | 09 09 69 6e 74 65 72 70 |.//doh..|..interp|
|000022a0| 6f 6c 2e 78 31 20 3d 20 | 78 31 3b 0d 0a 09 09 69 |ol.x1 = |x1;....i|
|000022b0| 6e 74 65 72 70 6f 6c 2e | 78 32 20 3d 20 78 32 3b |nterpol.|x2 = x2;|
|000022c0| 0d 0a 0d 0a 09 09 69 6e | 74 65 72 70 6f 6c 2e 6e |......in|terpol.n|
|000022d0| 6f 69 6e 66 6f 20 3d 20 | 28 28 78 32 20 3d 3d 20 |oinfo = |((x2 == |
|000022e0| 30 29 20 7c 7c 20 28 78 | 33 20 3d 3d 20 30 29 29 |0) || (x|3 == 0))|
|000022f0| 3b 0d 0a 09 7d 0d 0a 0d | 0a 09 2f 2f 47 65 74 20 |;...}...|..//Get |
|00002300| 70 6f 73 69 74 69 6f 6e | 20 61 63 63 6f 72 64 69 |position| accordi|
|00002310| 6e 67 20 74 6f 20 74 69 | 6d 65 73 74 61 6d 70 20 |ng to ti|mestamp |
|00002320| 76 61 72 69 61 62 6c 65 | 0d 0a 09 73 69 6d 75 6c |variable|...simul|
|00002330| 61 74 65 64 20 66 75 6e | 63 74 69 6f 6e 20 66 6c |ated fun|ction fl|
|00002340| 6f 61 74 20 47 65 74 49 | 6e 74 65 72 70 6f 6c 61 |oat GetI|nterpola|
|00002350| 74 65 64 50 6f 73 20 28 | 69 6e 74 20 63 6f 72 64 |tedPos (|int cord|
|00002360| 29 0d 0a 09 7b 0d 0a 09 | 09 6c 6f 63 61 6c 20 54 |)...{...|.local T|
|00002370| 49 6e 74 65 72 70 6f 6c | 20 70 3b 0d 0a 09 09 6c |Interpol| p;....l|
|00002380| 6f 63 61 6c 20 66 6c 6f | 61 74 20 68 31 3b 0d 0a |ocal flo|at h1;..|
|00002390| 09 09 6c 6f 63 61 6c 20 | 66 6c 6f 61 74 20 74 3b |..local |float t;|
|000023a0| 0d 0a 09 09 6c 6f 63 61 | 6c 20 66 6c 6f 61 74 20 |....loca|l float |
|000023b0| 78 31 3b 0d 0a 09 09 6c | 6f 63 61 6c 20 66 6c 6f |x1;....l|ocal flo|
|000023c0| 61 74 20 78 32 3b 0d 0a | 09 09 6c 6f 63 61 6c 20 |at x2;..|..local |
|000023d0| 66 6c 6f 61 74 20 72 65 | 73 3b 0d 0a 0d 0a 09 09 |float re|s;......|
|000023e0| 70 20 3d 20 69 6e 74 65 | 72 70 6f 6c 2e 63 6f 72 |p = inte|rpol.cor|
|000023f0| 64 73 20 5b 63 6f 72 64 | 5d 3b 0d 0a 09 09 78 31 |ds [cord|];....x1|
|00002400| 20 3d 20 69 6e 74 65 72 | 70 6f 6c 2e 78 31 3b 0d | = inter|pol.x1;.|
|00002410| 0a 09 09 78 32 20 3d 20 | 69 6e 74 65 72 70 6f 6c |...x2 = |interpol|
|00002420| 2e 78 32 3b 0d 0a 0d 0a | 09 09 68 31 20 3d 20 78 |.x2;....|..h1 = x|
|00002430| 32 20 2d 20 78 31 3b 0d | 0a 0d 0a 09 09 2f 2f 61 |2 - x1;.|.....//a|
|00002440| 73 73 65 72 74 3a 20 78 | 31 20 3c 20 74 69 6d 65 |ssert: x|1 < time|
|00002450| 73 74 61 6d 70 20 3c 20 | 78 32 0d 0a 09 09 69 66 |stamp < |x2....if|
|00002460| 20 28 78 32 20 3d 3d 20 | 78 31 29 0d 0a 09 09 09 | (x2 == |x1).....|
|00002470| 72 65 74 75 72 6e 20 30 | 3b 0d 0a 0d 0a 09 09 74 |return 0|;......t|
|00002480| 20 3d 20 28 63 75 72 72 | 65 6e 74 54 69 6d 65 20 | = (curr|entTime |
|00002490| 2d 20 78 31 29 20 2f 20 | 28 78 32 20 2d 20 78 31 |- x1) / |(x2 - x1|
|000024a0| 29 3b 0d 0a 0d 0a 09 09 | 72 65 73 20 3d 20 70 2e |);......|res = p.|
|000024b0| 79 31 20 2b 20 74 20 2a | 20 28 70 2e 64 79 29 20 |y1 + t *| (p.dy) |
|000024c0| 2b 20 74 20 2a 20 28 31 | 20 2d 20 74 29 20 2a 20 |+ t * (1| - t) * |
|000024d0| 70 2e 67 31 20 2b 20 74 | 2a 74 20 2a 20 28 31 20 |p.g1 + t|*t * (1 |
|000024e0| 2d 20 74 29 20 2a 20 70 | 2e 63 31 3b 0d 0a 09 09 |- t) * p|.c1;....|
|000024f0| 72 65 74 75 72 6e 20 72 | 65 73 3b 0d 0a 09 7d 0d |return r|es;...}.|
|00002500| 0a 0d 0a 09 2f 2f 4d 61 | 6b 65 73 20 73 75 72 65 |....//Ma|kes sure|
|00002510| 20 74 68 65 20 61 62 73 | 6f 6c 75 74 65 20 64 69 | the abs|olute di|
|00002520| 66 66 65 72 65 6e 63 65 | 73 20 62 65 74 77 65 65 |fference|s betwee|
|00002530| 6e 20 70 69 74 63 68 20 | 26 20 79 61 77 20 69 73 |n pitch |& yaw is|
|00002540| 6e 27 74 20 6d 6f 72 65 | 20 74 68 61 6e 20 33 32 |n't more| than 32|
|00002550| 6b 20 28 73 69 6e 63 65 | 20 69 74 27 73 20 6d 6f |k (since| it's mo|
|00002560| 64 20 36 35 6b 20 61 6e | 79 77 61 79 29 0d 0a 09 |d 65k an|yway)...|
|00002570| 73 69 6d 75 6c 61 74 65 | 64 20 66 75 6e 63 74 69 |simulate|d functi|
|00002580| 6f 6e 20 46 69 78 52 6f | 74 44 69 73 74 20 28 6f |on FixRo|tDist (o|
|00002590| 75 74 20 69 6e 74 20 74 | 31 2c 20 6f 75 74 20 69 |ut int t|1, out i|
|000025a0| 6e 74 20 74 32 2c 20 6f | 70 74 69 6f 6e 61 6c 20 |nt t2, o|ptional |
|000025b0| 62 6f 6f 6c 20 64 6f 77 | 6e 29 0d 0a 09 7b 0d 0a |bool dow|n)...{..|
|000025c0| 09 09 69 66 20 28 41 62 | 73 20 28 74 31 20 2d 20 |..if (Ab|s (t1 - |
|000025d0| 74 32 29 20 3e 20 33 32 | 37 36 38 29 20 7b 0d 0a |t2) > 32|768) {..|
|000025e0| 09 09 09 69 66 20 28 74 | 31 20 3e 20 33 32 37 36 |...if (t|1 > 3276|
|000025f0| 38 29 0d 0a 09 20 20 20 | 20 20 20 09 09 74 32 20 |8)... | ..t2 |
|00002600| 2b 3d 20 36 35 35 33 36 | 3b 0d 0a 09 09 09 65 6c |+= 65536|;.....el|
|00002610| 73 65 0d 0a 09 09 09 09 | 74 32 20 2d 3d 20 36 35 |se......|t2 -= 65|
|00002620| 35 33 36 3b 0d 0a 09 20 | 20 09 7d 0d 0a 09 7d 0d |536;... | .}...}.|
|00002630| 0a 0d 0a 09 73 69 6d 75 | 6c 61 74 65 64 20 66 75 |....simu|lated fu|
|00002640| 6e 63 74 69 6f 6e 20 43 | 68 65 63 6b 47 61 6d 65 |nction C|heckGame|
|00002650| 45 6e 64 20 28 29 0d 0a | 09 7b 0d 0a 09 09 6c 6f |End ()..|.{....lo|
|00002660| 63 61 6c 20 50 6c 61 79 | 65 72 43 6f 6e 74 72 6f |cal Play|erContro|
|00002670| 6c 6c 65 72 20 70 3b 0d | 0a 0d 0a 09 09 69 66 20 |ller p;.|.....if |
|00002680| 28 21 77 61 73 45 6e 64 | 65 64 29 20 7b 0d 0a 09 |(!wasEnd|ed) {...|
|00002690| 09 09 70 20 3d 20 4c 65 | 76 65 6c 2e 47 65 74 4c |..p = Le|vel.GetL|
|000026a0| 6f 63 61 6c 50 6c 61 79 | 65 72 43 6f 6e 74 72 6f |ocalPlay|erContro|
|000026b0| 6c 6c 65 72 28 29 3b 0d | 0a 09 09 09 69 66 20 28 |ller();.|....if (|
|000026c0| 70 2e 49 73 49 6e 53 74 | 61 74 65 28 27 47 61 6d |p.IsInSt|ate('Gam|
|000026d0| 65 45 6e 64 65 64 27 29 | 29 20 7b 0d 0a 09 09 09 |eEnded')|) {.....|
|000026e0| 09 77 61 73 45 6e 64 65 | 64 20 3d 20 74 72 75 65 |.wasEnde|d = true|
|000026f0| 3b 0d 0a 09 09 09 09 53 | 65 6e 64 54 6f 53 65 72 |;......S|endToSer|
|00002700| 76 65 72 20 28 22 33 22 | 29 3b 0d 0a 09 09 09 7d |ver ("3"|);.....}|
|00002710| 0d 0a 09 09 7d 0d 0a 09 | 7d 0d 0a 0d 0a 09 73 69 |....}...|}.....si|
|00002720| 6d 75 6c 61 74 65 64 20 | 66 75 6e 63 74 69 6f 6e |mulated |function|
|00002730| 20 54 69 63 6b 20 28 66 | 6c 6f 61 74 20 64 65 6c | Tick (f|loat del|
|00002740| 74 61 29 0d 0a 09 7b 0d | 0a 09 09 6c 6f 63 61 6c |ta)...{.|...local|
|00002750| 20 76 65 63 74 6f 72 20 | 70 6f 73 3b 0d 0a 09 09 | vector |pos;....|
|00002760| 6c 6f 63 61 6c 20 72 6f | 74 61 74 6f 72 20 72 6f |local ro|tator ro|
|00002770| 74 3b 0d 0a 09 09 6c 6f | 63 61 6c 20 73 74 72 69 |t;....lo|cal stri|
|00002780| 6e 67 20 57 61 72 6e 4d | 73 67 3b 0d 0a 09 09 6c |ng WarnM|sg;....l|
|00002790| 6f 63 61 6c 20 50 6c 61 | 79 65 72 43 6f 6e 74 72 |ocal Pla|yerContr|
|000027a0| 6f 6c 6c 65 72 20 70 2c | 20 69 74 3b 0d 0a 09 09 |oller p,| it;....|
|000027b0| 6c 6f 63 61 6c 20 50 61 | 77 6e 20 74 61 72 67 65 |local Pa|wn targe|
|000027c0| 74 3b 0d 0a 0d 0a 09 09 | 67 6c 6f 62 61 6c 2e 74 |t;......|global.t|
|000027d0| 69 63 6b 20 28 64 65 6c | 74 61 29 3b 0d 0a 0d 0a |ick (del|ta);....|
|000027e0| 09 09 69 66 28 4e 6f 50 | 72 69 6d 61 72 79 29 0d |..if(NoP|rimary).|
|000027f0| 0a 09 09 09 43 68 65 63 | 6b 47 61 6d 65 45 6e 64 |....Chec|kGameEnd|
|00002800| 28 29 3b 0d 0a 0d 0a 09 | 09 70 20 3d 20 4c 65 76 |();.....|.p = Lev|
|00002810| 65 6c 2e 47 65 74 4c 6f | 63 61 6c 50 6c 61 79 65 |el.GetLo|calPlaye|
|00002820| 72 43 6f 6e 74 72 6f 6c | 6c 65 72 20 28 29 3b 0d |rControl|ler ();.|
|00002830| 0a 0d 0a 20 20 20 20 20 | 20 20 20 2f 2f 54 68 69 |... | //Thi|
|00002840| 73 20 73 61 76 65 73 20 | 62 61 6e 64 77 69 64 74 |s saves |bandwidt|
|00002850| 68 20 66 6f 72 20 74 68 | 65 20 73 65 72 76 65 72 |h for th|e server|
|00002860| 20 62 65 63 61 75 73 65 | 20 74 68 65 20 63 6c 69 | because| the cli|
|00002870| 65 6e 74 20 73 74 6f 70 | 73 0d 0a 20 20 20 20 20 |ent stop|s.. |
|00002880| 20 20 20 2f 2f 73 65 6e | 64 69 6e 67 20 53 65 72 | //sen|ding Ser|
|00002890| 76 65 72 4d 6f 76 65 20 | 61 6c 6c 20 74 68 65 20 |verMove |all the |
|000028a0| 74 69 6d 65 0d 0a 20 20 | 20 20 09 69 66 20 28 28 |time.. | .if ((|
|000028b0| 70 20 21 3d 20 6e 6f 6e | 65 29 20 26 26 20 28 70 |p != non|e) && (p|
|000028c0| 2e 52 6f 6c 65 20 3c 20 | 52 4f 4c 45 5f 41 75 74 |.Role < |ROLE_Aut|
|000028d0| 68 6f 72 69 74 79 29 29 | 20 7b 0d 0a 09 20 20 20 |hority))| {... |
|000028e0| 20 20 20 20 20 6c 6f 67 | 28 22 75 74 76 3a 20 43 | log|("utv: C|
|000028f0| 68 61 6e 67 69 6e 67 20 | 63 6f 6e 74 72 6f 6c 6c |hanging |controll|
|00002900| 65 72 20 72 6f 6c 65 20 | 74 6f 20 52 4f 4c 45 5f |er role |to ROLE_|
|00002910| 41 75 74 68 6f 72 69 74 | 79 22 29 3b 0d 0a 20 20 |Authorit|y");.. |
|00002920| 20 20 09 20 20 20 20 70 | 2e 52 6f 6c 65 20 3d 20 | . p|.Role = |
|00002930| 52 4f 4c 45 5f 41 75 74 | 68 6f 72 69 74 79 3b 0d |ROLE_Aut|hority;.|
|00002940| 0a 20 20 20 20 09 7d 0d | 0a 0d 0a 20 20 20 20 20 |. .}.|... |
|00002950| 20 20 20 2f 2f 49 66 20 | 77 61 74 63 68 69 6e 67 | //If |watching|
|00002960| 20 61 20 64 65 6d 6f 2c | 20 64 6f 20 64 69 6c 61 | a demo,| do dila|
|00002970| 74 69 6f 6e 20 61 64 6a | 75 73 74 6d 65 6e 74 20 |tion adj|ustment |
|00002980| 66 6f 72 20 73 6d 6f 6f | 74 68 6e 65 73 73 0d 0a |for smoo|thness..|
|00002990| 20 20 20 20 20 20 20 20 | 69 66 20 28 28 49 73 44 | |if ((IsD|
|000029a0| 65 6d 6f 29 20 26 26 20 | 28 4c 65 76 65 6c 2e 54 |emo) && |(Level.T|
|000029b0| 69 6d 65 44 69 6c 61 74 | 69 6f 6e 20 3e 20 31 2e |imeDilat|ion > 1.|
|000029c0| 30 29 29 20 7b 0d 0a 20 | 20 20 20 20 20 20 20 20 |0)) {.. | |
|000029d0| 20 20 20 2f 2f 4c 6f 67 | 28 22 75 74 76 3a 20 53 | //Log|("utv: S|
|000029e0| 65 74 74 69 6e 67 20 74 | 69 6d 65 64 69 6c 61 74 |etting t|imedilat|
|000029f0| 69 6f 6e 20 74 6f 20 31 | 2e 30 22 29 3b 0d 0a 20 |ion to 1|.0");.. |
|00002a00| 20 20 20 20 20 20 20 20 | 20 20 20 2f 2f 4c 65 76 | | //Lev|
|00002a10| 65 6c 2e 54 69 6d 65 44 | 69 6c 61 74 69 6f 6e 20 |el.TimeD|ilation |
|00002a20| 3d 20 31 2e 30 3b 0d 0a | 20 20 20 20 20 20 20 20 |= 1.0;..| |
|00002a30| 7d 0d 0a 0d 0a 20 20 20 | 20 20 20 20 20 2f 2f 57 |}.... | //W|
|00002a40| 68 65 6e 20 77 61 74 63 | 68 69 6e 67 20 61 20 73 |hen watc|hing a s|
|00002a50| 65 72 76 65 72 20 64 65 | 6d 6f 2c 20 74 68 65 20 |erver de|mo, the |
|00002a60| 76 69 65 77 20 72 6f 74 | 61 74 69 6f 6e 20 69 73 |view rot|ation is|
|00002a70| 20 6e 6f 74 20 75 70 64 | 61 74 65 64 20 63 6f 72 | not upd|ated cor|
|00002a80| 72 65 63 74 6c 79 0d 0a | 20 20 20 20 20 20 20 20 |rectly..| |
|00002a90| 69 66 20 28 28 49 73 44 | 65 6d 6f 29 20 26 26 20 |if ((IsD|emo) && |
|00002aa0| 28 53 65 65 41 6c 6c 29 | 29 20 7b 0d 0a 20 20 20 |(SeeAll)|) {.. |
|00002ab0| 20 20 20 20 20 20 20 20 | 20 69 66 20 28 28 70 2e | | if ((p.|
|00002ac0| 56 69 65 77 54 61 72 67 | 65 74 20 21 3d 20 6e 6f |ViewTarg|et != no|
|00002ad0| 6e 65 29 20 26 26 20 28 | 70 2e 56 69 65 77 54 61 |ne) && (|p.ViewTa|
|00002ae0| 72 67 65 74 20 21 3d 20 | 70 29 29 20 7b 0d 0a 20 |rget != |p)) {.. |
|00002af0| 20 20 20 20 20 20 20 20 | 20 20 20 20 20 20 20 74 | | t|
|00002b00| 61 72 67 65 74 20 3d 20 | 50 61 77 6e 28 70 2e 56 |arget = |Pawn(p.V|
|00002b10| 69 65 77 54 61 72 67 65 | 74 29 3b 0d 0a 20 20 20 |iewTarge|t);.. |
|00002b20| 20 20 20 20 20 20 20 20 | 20 20 20 20 20 69 66 20 | | if |
|00002b30| 28 74 61 72 67 65 74 2e | 43 6f 6e 74 72 6f 6c 6c |(target.|Controll|
|00002b40| 65 72 20 21 3d 20 6e 6f | 6e 65 29 20 7b 0d 0a 20 |er != no|ne) {.. |
|00002b50| 20 20 20 20 20 20 20 20 | 20 20 20 20 20 20 20 20 | | |
|00002b60| 20 20 20 70 2e 54 61 72 | 67 65 74 56 69 65 77 52 | p.Tar|getViewR|
|00002b70| 6f 74 61 74 69 6f 6e 20 | 3d 20 74 61 72 67 65 74 |otation |= target|
|00002b80| 2e 43 6f 6e 74 72 6f 6c | 6c 65 72 2e 52 6f 74 61 |.Control|ler.Rota|
|00002b90| 74 69 6f 6e 3b 0d 0a 20 | 20 20 20 20 20 20 20 20 |tion;.. | |
|00002ba0| 20 20 20 20 20 20 20 7d | 0d 0a 20 20 20 20 20 20 | }|.. |
|00002bb0| 20 20 20 20 20 20 7d 0d | 0a 20 20 20 20 20 20 20 | }.|. |
|00002bc0| 20 7d 0d 0a 0d 0a 20 20 | 20 20 20 20 20 20 2f 2f | }.... | //|
|00002bd0| 41 20 63 6c 69 65 6e 74 | 73 69 64 65 20 64 65 6d |A client|side dem|
|00002be0| 6f 20 6e 65 65 64 73 20 | 74 6f 20 62 65 20 61 64 |o needs |to be ad|
|00002bf0| 6a 75 73 74 65 64 20 61 | 73 20 77 65 6c 6c 0d 0a |justed a|s well..|
|00002c00| 20 20 20 20 20 20 20 20 | 69 66 20 28 28 49 73 44 | |if ((IsD|
|00002c10| 65 6d 6f 29 20 26 26 20 | 28 21 53 65 65 41 6c 6c |emo) && |(!SeeAll|
|00002c20| 29 29 20 7b 0d 0a 20 20 | 20 20 20 20 20 20 20 20 |)) {.. | |
|00002c30| 20 20 4c 6f 67 28 22 73 | 65 61 72 63 68 22 29 3b | Log("s|earch");|
|00002c40| 0d 0a 20 20 20 20 20 20 | 20 20 20 20 20 20 66 6f |.. | fo|
|00002c50| 72 65 61 63 68 20 64 79 | 6e 61 6d 69 63 61 63 74 |reach dy|namicact|
|00002c60| 6f 72 73 28 63 6c 61 73 | 73 27 50 6c 61 79 65 72 |ors(clas|s'Player|
|00002c70| 43 6f 6e 74 72 6f 6c 6c | 65 72 27 2c 20 69 74 29 |Controll|er', it)|
|00002c80| 20 7b 0d 0a 20 20 20 20 | 20 20 20 20 20 20 20 20 | {.. | |
|00002c90| 20 20 20 20 69 74 2e 53 | 65 74 56 69 65 77 54 61 | it.S|etViewTa|
|00002ca0| 72 67 65 74 28 70 2e 50 | 61 77 6e 29 3b 0d 0a 20 |rget(p.P|awn);.. |
|00002cb0| 20 20 20 20 20 20 20 20 | 20 20 20 7d 0d 0a 20 20 | | }.. |
|00002cc0| 20 20 20 20 20 20 7d 0d | 0a 0d 0a 09 09 50 72 6f | }.|.....Pro|
|00002cd0| 63 65 73 73 4d 6f 76 65 | 6d 65 6e 74 20 28 29 3b |cessMove|ment ();|
|00002ce0| 0d 0a 0d 0a 09 09 2f 2f | 53 65 72 76 65 72 20 77 |......//|Server w|
|00002cf0| 69 6c 6c 20 66 69 6c 74 | 65 72 20 70 61 63 6b 65 |ill filt|er packe|
|00002d00| 74 73 20 66 6f 72 20 75 | 73 20 69 66 20 77 65 20 |ts for u|s if we |
|00002d10| 64 6f 6e 27 74 20 66 6f | 6c 6c 6f 77 20 70 72 69 |don't fo|llow pri|
|00002d20| 6d 61 72 79 2c 20 73 6f | 20 63 68 65 63 6b 20 69 |mary, so| check i|
|00002d30| 66 20 69 74 20 68 61 73 | 20 63 68 61 6e 67 65 64 |f it has| changed|
|00002d40| 0d 0a 09 09 69 66 20 28 | 46 6f 6c 6c 6f 77 50 72 |....if (|FollowPr|
|00002d50| 69 6d 61 72 79 20 21 3d | 20 4f 6c 64 46 6f 6c 6c |imary !=| OldFoll|
|00002d60| 6f 77 29 20 7b 0d 0a 09 | 09 20 20 20 20 4f 6c 64 |ow) {...|. Old|
|00002d70| 46 6f 6c 6c 6f 77 20 3d | 20 46 6f 6c 6c 6f 77 50 |Follow =| FollowP|
|00002d80| 72 69 6d 61 72 79 3b 0d | 0a 20 20 20 20 09 09 69 |rimary;.|. ..i|
|00002d90| 66 20 28 46 6f 6c 6c 6f | 77 50 72 69 6d 61 72 79 |f (Follo|wPrimary|
|00002da0| 29 0d 0a 09 20 20 20 20 | 20 20 20 20 20 20 20 20 |)... | |
|00002db0| 53 65 6e 64 54 6f 53 65 | 72 76 65 72 28 22 41 22 |SendToSe|rver("A"|
|00002dc0| 29 3b 0d 0a 20 20 20 20 | 09 20 20 20 20 65 6c 73 |);.. |. els|
|00002dd0| 65 0d 0a 20 20 20 09 20 | 20 20 20 09 20 20 20 20 |e.. . | . |
|00002de0| 53 65 6e 64 54 6f 53 65 | 72 76 65 72 28 22 42 22 |SendToSe|rver("B"|
|00002df0| 29 3b 0d 0a 20 20 20 09 | 20 20 20 20 7d 0d 0a 0d |);.. .| }...|
|00002e00| 0a 09 09 69 66 28 46 6f | 6c 6c 6f 77 50 72 69 6d |...if(Fo|llowPrim|
|00002e10| 61 72 79 29 7b 0d 0a 09 | 09 09 2f 2f 44 6f 20 77 |ary){...|..//Do w|
|00002e20| 65 20 68 61 76 65 20 69 | 6e 74 65 72 70 6f 6c 61 |e have i|nterpola|
|00002e30| 74 69 6f 6e 20 64 61 74 | 61 20 74 6f 20 61 63 74 |tion dat|a to act|
|00002e40| 20 6f 6e 3f 0d 0a 09 09 | 09 69 66 20 28 28 69 6e | on?....|.if ((in|
|00002e50| 74 65 72 70 6f 6c 2e 78 | 32 20 3c 20 63 75 72 72 |terpol.x|2 < curr|
|00002e60| 65 6e 74 54 69 6d 65 29 | 20 7c 7c 20 28 69 6e 74 |entTime)| || (int|
|00002e70| 65 72 70 6f 6c 2e 78 31 | 20 3d 3d 20 69 6e 74 65 |erpol.x1| == inte|
|00002e80| 72 70 6f 6c 2e 78 32 29 | 29 20 7b 0d 0a 09 09 09 |rpol.x2)|) {.....|
|00002e90| 09 57 61 72 6e 4d 73 67 | 20 3d 20 22 57 61 69 74 |.WarnMsg| = "Wait|
|00002ea0| 69 6e 67 20 6f 6e 20 6d | 6f 76 65 6d 65 6e 74 20 |ing on m|ovement |
|00002eb0| 69 6e 74 65 72 70 6f 6c | 61 74 69 6f 6e 20 64 61 |interpol|ation da|
|00002ec0| 74 61 22 3b 0d 0a 09 09 | 09 7d 0d 0a 09 09 09 65 |ta";....|.}.....e|
|00002ed0| 6c 73 65 20 7b 0d 0a 09 | 09 09 09 2f 2f 43 61 6c |lse {...|...//Cal|
|00002ee0| 63 75 6c 61 74 65 20 69 | 6e 74 65 72 70 6f 6c 61 |culate i|nterpola|
|00002ef0| 74 65 64 20 70 6f 73 69 | 74 69 6f 6e 20 61 6e 64 |ted posi|tion and|
|00002f00| 20 72 6f 74 61 74 69 6f | 6e 0d 0a 09 09 09 09 70 | rotatio|n......p|
|00002f10| 6f 73 2e 78 20 3d 20 47 | 65 74 49 6e 74 65 72 70 |os.x = G|etInterp|
|00002f20| 6f 6c 61 74 65 64 50 6f | 73 20 28 30 29 3b 0d 0a |olatedPo|s (0);..|
|00002f30| 09 09 09 09 70 6f 73 2e | 79 20 3d 20 47 65 74 49 |....pos.|y = GetI|
|00002f40| 6e 74 65 72 70 6f 6c 61 | 74 65 64 50 6f 73 20 28 |nterpola|tedPos (|
|00002f50| 31 29 3b 0d 0a 09 09 09 | 09 70 6f 73 2e 7a 20 3d |1);.....|.pos.z =|
|00002f60| 20 47 65 74 49 6e 74 65 | 72 70 6f 6c 61 74 65 64 | GetInte|rpolated|
|00002f70| 50 6f 73 20 28 32 29 3b | 0d 0a 0d 0a 09 09 09 09 |Pos (2);|........|
|00002f80| 72 6f 74 2e 70 69 74 63 | 68 20 3d 20 47 65 74 49 |rot.pitc|h = GetI|
|00002f90| 6e 74 65 72 70 6f 6c 61 | 74 65 64 50 6f 73 20 28 |nterpola|tedPos (|
|00002fa0| 33 29 3b 0d 0a 09 09 09 | 09 72 6f 74 2e 79 61 77 |3);.....|.rot.yaw|
|00002fb0| 20 3d 20 47 65 74 49 6e | 74 65 72 70 6f 6c 61 74 | = GetIn|terpolat|
|00002fc0| 65 64 50 6f 73 20 28 34 | 29 3b 0d 0a 09 09 09 09 |edPos (4|);......|
|00002fd0| 72 6f 74 2e 72 6f 6c 6c | 20 3d 20 30 3b 0d 0a 0d |rot.roll| = 0;...|
|00002fe0| 0a 09 09 09 09 2f 2f 41 | 6c 77 61 79 73 20 73 65 |.....//A|lways se|
|00002ff0| 74 20 74 68 65 20 6c 6f | 63 61 74 69 6f 6e 0d 0a |t the lo|cation..|
|00003000| 09 09 09 09 69 66 28 76 | 69 65 77 69 6e 67 53 65 |....if(v|iewingSe|
|00003010| 6c 66 29 0d 0a 09 20 20 | 20 09 09 09 09 70 2e 53 |lf)... | ....p.S|
|00003020| 65 74 4c 6f 63 61 74 69 | 6f 6e 20 28 70 6f 73 29 |etLocati|on (pos)|
|00003030| 3b 0d 0a 0d 0a 09 09 09 | 09 2f 2f 46 6f 72 63 65 |;.......|.//Force|
|00003040| 20 62 65 68 69 6e 64 76 | 69 65 77 20 64 65 70 65 | behindv|iew depe|
|00003050| 6e 64 69 6e 67 20 6f 6e | 20 75 73 65 72 20 70 72 |nding on| user pr|
|00003060| 65 66 20 77 68 65 6e 20 | 73 70 65 63 63 69 6e 67 |ef when |speccing|
|00003070| 20 73 6f 6d 65 74 68 69 | 6e 67 0d 0a 09 09 09 09 | somethi|ng......|
|00003080| 69 66 20 28 28 70 2e 76 | 69 65 77 74 61 72 67 65 |if ((p.v|iewtarge|
|00003090| 74 20 3d 3d 20 6e 6f 6e | 65 29 20 7c 7c 20 28 70 |t == non|e) || (p|
|000030a0| 2e 56 69 65 77 54 61 72 | 67 65 74 20 3d 3d 20 70 |.ViewTar|get == p|
|000030b0| 29 29 20 7b 0d 0a 09 09 | 09 09 09 70 2e 62 42 65 |)) {....|...p.bBe|
|000030c0| 68 69 6e 64 56 69 65 77 | 20 3d 20 66 61 6c 73 65 |hindView| = false|
|000030d0| 3b 0d 0a 09 09 09 09 7d | 0d 0a 09 09 09 09 65 6c |;......}|......el|
|000030e0| 73 65 20 7b 0d 0a 09 09 | 09 09 09 70 2e 62 42 65 |se {....|...p.bBe|
|000030f0| 68 69 6e 64 56 69 65 77 | 20 3d 20 63 6c 61 73 73 |hindView| = class|
|00003100| 27 75 74 76 52 65 70 6c | 69 63 61 74 69 6f 6e 27 |'utvRepl|ication'|
|00003110| 2e 64 65 66 61 75 6c 74 | 2e 77 61 6e 74 42 65 68 |.default|.wantBeh|
|00003120| 69 6e 64 76 69 65 77 3b | 0d 0a 09 09 09 09 7d 0d |indview;|......}.|
|00003130| 0a 0d 0a 09 09 09 09 2f | 2f 4e 6f 77 20 64 65 74 |......./|/Now det|
|00003140| 65 72 6d 69 6e 65 20 77 | 68 61 74 20 74 6f 20 64 |ermine w|hat to d|
|00003150| 6f 20 77 69 74 68 20 74 | 68 65 20 72 6f 74 61 74 |o with t|he rotat|
|00003160| 69 6f 6e 0d 0a 09 09 09 | 09 73 77 69 74 63 68 20 |ion.....|.switch |
|00003170| 28 63 6c 61 73 73 27 75 | 74 76 52 65 70 6c 69 63 |(class'u|tvReplic|
|00003180| 61 74 69 6f 6e 27 2e 64 | 65 66 61 75 6c 74 2e 56 |ation'.d|efault.V|
|00003190| 69 65 77 4d 6f 64 65 29 | 20 7b 0d 0a 09 09 09 09 |iewMode)| {......|
|000031a0| 09 63 61 73 65 20 30 3a | 0d 0a 09 09 09 09 09 09 |.case 0:|........|
|000031b0| 69 66 20 28 28 70 2e 56 | 69 65 77 54 61 72 67 65 |if ((p.V|iewTarge|
|000031c0| 74 20 3d 3d 20 6e 6f 6e | 65 29 20 7c 7c 20 28 70 |t == non|e) || (p|
|000031d0| 2e 56 69 65 77 54 61 72 | 67 65 74 20 3d 3d 20 70 |.ViewTar|get == p|
|000031e0| 29 29 20 7b 0d 0a 09 09 | 09 09 09 09 09 70 2e 53 |)) {....|.....p.S|
|000031f0| 65 74 52 6f 74 61 74 69 | 6f 6e 20 28 72 6f 74 29 |etRotati|on (rot)|
|00003200| 3b 0d 0a 09 09 09 09 09 | 09 7d 0d 0a 09 09 09 09 |;.......|.}......|
|00003210| 09 09 62 72 65 61 6b 3b | 0d 0a 09 09 09 09 09 63 |..break;|.......c|
|00003220| 61 73 65 20 31 3a 0d 0a | 09 09 09 09 09 09 70 2e |ase 1:..|......p.|
|00003230| 53 65 74 52 6f 74 61 74 | 69 6f 6e 20 28 72 6f 74 |SetRotat|ion (rot|
|00003240| 29 3b 0d 0a 09 09 09 09 | 09 09 62 72 65 61 6b 3b |);......|..break;|
|00003250| 0d 0a 09 09 09 09 09 63 | 61 73 65 20 32 3a 0d 0a |.......c|ase 2:..|
|00003260| 09 09 09 09 09 09 62 72 | 65 61 6b 3b 0d 0a 09 09 |......br|eak;....|
|00003270| 09 09 7d 0d 0a 09 09 09 | 7d 0d 0a 09 09 7d 20 65 |..}.....|}....} e|
|00003280| 6c 73 65 20 7b 09 2f 2f | 6e 6f 74 20 66 6f 6c 6c |lse {.//|not foll|
|00003290| 6f 77 69 6e 67 20 70 72 | 69 6d 61 72 79 0d 0a 09 |owing pr|imary...|
|000032a0| 09 09 69 66 28 46 72 65 | 65 46 6c 69 67 68 74 29 |..if(Fre|eFlight)|
|000032b0| 7b 0d 0a 0d 0a 09 09 09 | 09 2f 2f 4c 6f 63 61 6c |{.......|.//Local|
|000032c0| 50 6f 73 2b 3d 70 2e 61 | 46 6f 72 77 61 72 64 2a |Pos+=p.a|Forward*|
|000032d0| 64 65 6c 74 61 2a 30 2e | 31 35 2a 56 65 63 74 6f |delta*0.|15*Vecto|
|000032e0| 72 28 70 2e 72 6f 74 61 | 74 69 6f 6e 29 3b 0d 0a |r(p.rota|tion);..|
|000032f0| 09 09 09 09 2f 2f 4c 6f | 63 61 6c 50 6f 73 2d 3d |....//Lo|calPos-=|
|00003300| 70 2e 61 53 74 72 61 66 | 65 2a 64 65 6c 74 61 2a |p.aStraf|e*delta*|
|00003310| 30 2e 31 35 2a 56 65 63 | 74 6f 72 28 70 2e 72 6f |0.15*Vec|tor(p.ro|
|00003320| 74 61 74 69 6f 6e 29 20 | 43 72 6f 73 73 20 56 65 |tation) |Cross Ve|
|00003330| 63 74 28 30 2c 30 2c 31 | 29 3b 0d 0a 09 09 09 09 |ct(0,0,1|);......|
|00003340| 69 66 28 4d 6f 76 65 46 | 6f 72 77 61 72 64 29 0d |if(MoveF|orward).|
|00003350| 0a 09 09 09 09 09 4c 6f | 63 61 6c 50 6f 73 2b 3d |......Lo|calPos+=|
|00003360| 64 65 6c 74 61 2a 31 30 | 30 30 2a 56 65 63 74 6f |delta*10|00*Vecto|
|00003370| 72 28 70 2e 72 6f 74 61 | 74 69 6f 6e 29 3b 0d 0a |r(p.rota|tion);..|
|00003380| 09 09 09 09 69 66 28 4d | 6f 76 65 42 61 63 6b 77 |....if(M|oveBackw|
|00003390| 61 72 64 29 0d 0a 09 09 | 09 09 09 4c 6f 63 61 6c |ard)....|...Local|
|000033a0| 50 6f 73 2d 3d 64 65 6c | 74 61 2a 31 30 30 30 2a |Pos-=del|ta*1000*|
|000033b0| 56 65 63 74 6f 72 28 70 | 2e 72 6f 74 61 74 69 6f |Vector(p|.rotatio|
|000033c0| 6e 29 3b 0d 0a 09 09 09 | 09 69 66 28 4d 6f 76 65 |n);.....|.if(Move|
|000033d0| 52 69 67 68 74 29 0d 0a | 09 09 09 09 09 4c 6f 63 |Right)..|.....Loc|
|000033e0| 61 6c 50 6f 73 2d 3d 64 | 65 6c 74 61 2a 31 30 30 |alPos-=d|elta*100|
|000033f0| 30 2a 56 65 63 74 6f 72 | 28 70 2e 72 6f 74 61 74 |0*Vector|(p.rotat|
|00003400| 69 6f 6e 29 20 43 72 6f | 73 73 20 56 65 63 74 28 |ion) Cro|ss Vect(|
|00003410| 30 2c 30 2c 31 29 3b 0d | 0a 09 09 09 09 69 66 28 |0,0,1);.|.....if(|
|00003420| 4d 6f 76 65 4c 65 66 74 | 29 0d 0a 09 09 09 09 09 |MoveLeft|).......|
|00003430| 4c 6f 63 61 6c 50 6f 73 | 2b 3d 64 65 6c 74 61 2a |LocalPos|+=delta*|
|00003440| 31 30 30 30 2a 56 65 63 | 74 6f 72 28 70 2e 72 6f |1000*Vec|tor(p.ro|
|00003450| 74 61 74 69 6f 6e 29 20 | 43 72 6f 73 73 20 56 65 |tation) |Cross Ve|
|00003460| 63 74 28 30 2c 30 2c 31 | 29 3b 0d 0a 09 09 09 09 |ct(0,0,1|);......|
|00003470| 69 66 28 4d 6f 76 65 55 | 70 29 0d 0a 09 09 09 09 |if(MoveU|p)......|
|00003480| 09 4c 6f 63 61 6c 50 6f | 73 2b 3d 64 65 6c 74 61 |.LocalPo|s+=delta|
|00003490| 2a 31 30 30 30 2a 56 65 | 63 74 28 30 2c 30 2c 31 |*1000*Ve|ct(0,0,1|
|000034a0| 29 3b 0d 0a 09 09 09 09 | 69 66 28 4d 6f 76 65 44 |);......|if(MoveD|
|000034b0| 6f 77 6e 29 0d 0a 09 09 | 09 09 09 4c 6f 63 61 6c |own)....|...Local|
|000034c0| 50 6f 73 2d 3d 64 65 6c | 74 61 2a 31 30 30 30 2a |Pos-=del|ta*1000*|
|000034d0| 56 65 63 74 28 30 2c 30 | 2c 31 29 3b 0d 0a 0d 0a |Vect(0,0|,1);....|
|000034e0| 09 09 09 09 2f 2f 70 2e | 43 6c 69 65 6e 74 4d 65 |....//p.|ClientMe|
|000034f0| 73 73 61 67 65 20 28 22 | 4d 6f 76 65 20 22 20 24 |ssage ("|Move " $|
|00003500| 20 4d 6f 76 65 46 6f 72 | 77 61 72 64 20 24 20 22 | MoveFor|ward $ "|
|00003510| 20 2d 20 22 20 24 20 4c | 6f 63 61 6c 50 6f 73 20 | - " $ L|ocalPos |
|00003520| 24 20 22 20 2d 20 22 20 | 24 20 64 65 6c 74 61 29 |$ " - " |$ delta)|
|00003530| 3b 0d 0a 0d 0a 09 09 09 | 09 70 2e 62 42 65 68 69 |;.......|.p.bBehi|
|00003540| 6e 64 56 69 65 77 3d 66 | 61 6c 73 65 3b 0d 0a 09 |ndView=f|alse;...|
|00003550| 09 09 09 69 66 20 28 70 | 2e 56 69 65 77 54 61 72 |...if (p|.ViewTar|
|00003560| 67 65 74 20 21 3d 20 70 | 29 0d 0a 20 20 20 20 09 |get != p|).. .|
|00003570| 09 09 09 70 2e 53 65 74 | 56 69 65 77 54 61 72 67 |...p.Set|ViewTarg|
|00003580| 65 74 28 70 29 3b 0d 0a | 09 09 09 09 70 2e 53 65 |et(p);..|....p.Se|
|00003590| 74 4c 6f 63 61 74 69 6f | 6e 28 4c 6f 63 61 6c 50 |tLocatio|n(LocalP|
|000035a0| 6f 73 29 3b 0d 0a 09 09 | 09 09 69 66 28 70 2e 70 |os);....|..if(p.p|
|000035b0| 61 77 6e 21 3d 6e 6f 6e | 65 29 7b 0d 0a 09 09 09 |awn!=non|e){.....|
|000035c0| 09 09 70 2e 50 61 77 6e | 2e 53 65 74 4c 6f 63 61 |..p.Pawn|.SetLoca|
|000035d0| 74 69 6f 6e 28 4c 6f 63 | 61 6c 50 6f 73 29 3b 0d |tion(Loc|alPos);.|
|000035e0| 0a 09 09 09 09 7d 0d 0a | 09 09 09 7d 20 65 6c 73 |.....}..|...} els|
|000035f0| 65 20 7b 0d 0a 09 09 09 | 09 70 2e 62 42 65 68 69 |e {.....|.p.bBehi|
|00003600| 6e 64 56 69 65 77 20 3d | 20 63 6c 61 73 73 27 75 |ndView =| class'u|
|00003610| 74 76 52 65 70 6c 69 63 | 61 74 69 6f 6e 27 2e 64 |tvReplic|ation'.d|
|00003620| 65 66 61 75 6c 74 2e 77 | 61 6e 74 42 65 68 69 6e |efault.w|antBehin|
|00003630| 64 76 69 65 77 3b 0d 0a | 09 09 09 09 74 61 72 67 |dview;..|....targ|
|00003640| 65 74 3d 47 65 74 50 61 | 77 6e 46 72 6f 6d 4e 61 |et=GetPa|wnFromNa|
|00003650| 6d 65 28 4c 61 73 74 54 | 61 72 67 65 74 4e 61 6d |me(LastT|argetNam|
|00003660| 65 29 3b 0d 0a 09 09 09 | 09 69 66 28 74 61 72 67 |e);.....|.if(targ|
|00003670| 65 74 21 3d 6e 6f 6e 65 | 29 7b 0d 0a 09 09 09 09 |et!=none|){......|
|00003680| 20 20 20 20 69 66 20 28 | 70 2e 56 69 65 77 54 61 | if (|p.ViewTa|
|00003690| 72 67 65 74 20 21 3d 20 | 74 61 72 67 65 74 29 0d |rget != |target).|
|000036a0| 0a 20 20 20 20 09 09 09 | 09 09 70 2e 53 65 74 56 |. ...|..p.SetV|
|000036b0| 69 65 77 54 61 72 67 65 | 74 28 74 61 72 67 65 74 |iewTarge|t(target|
|000036c0| 29 3b 0d 0a 09 09 09 09 | 09 70 2e 54 61 72 67 65 |);......|.p.Targe|
|000036d0| 74 45 79 65 48 65 69 67 | 68 74 20 3d 20 74 61 72 |tEyeHeig|ht = tar|
|000036e0| 67 65 74 2e 42 61 73 65 | 45 79 65 48 65 69 67 68 |get.Base|EyeHeigh|
|000036f0| 74 3b 0d 0a 09 09 09 09 | 7d 0d 0a 09 09 09 7d 0d |t;......|}.....}.|
|00003700| 0a 09 09 7d 0d 0a 09 09 | 75 74 69 2e 53 65 74 57 |...}....|uti.SetW|
|00003710| 61 72 6e 69 6e 67 20 28 | 57 61 72 6e 4d 73 67 29 |arning (|WarnMsg)|
|00003720| 3b 0d 0a 09 7d 0d 0a 0d | 0a 09 73 69 6d 75 6c 61 |;...}...|..simula|
|00003730| 74 65 64 20 66 75 6e 63 | 74 69 6f 6e 20 4d 6f 76 |ted func|tion Mov|
|00003740| 65 6d 65 6e 74 20 47 65 | 74 4e 65 78 74 4d 6f 76 |ement Ge|tNextMov|
|00003750| 65 6d 65 6e 74 20 28 69 | 6e 74 20 6e 75 6d 29 0d |ement (i|nt num).|
|00003760| 0a 09 7b 0d 0a 09 09 6c | 6f 63 61 6c 20 69 6e 74 |..{....l|ocal int|
|00003770| 20 69 3b 0d 0a 09 09 6c | 6f 63 61 6c 20 69 6e 74 | i;....l|ocal int|
|00003780| 20 69 6e 64 65 78 3b 0d | 0a 0d 0a 09 09 69 6e 64 | index;.|.....ind|
|00003790| 65 78 20 3d 20 6d 6f 76 | 65 74 61 69 6c 3b 0d 0a |ex = mov|etail;..|
|000037a0| 09 09 66 6f 72 20 28 69 | 20 3d 20 30 3b 20 69 20 |..for (i| = 0; i |
|000037b0| 3c 20 6e 75 6d 3b 20 2b | 2b 69 29 20 7b 0d 0a 09 |< num; +|+i) {...|
|000037c0| 09 09 69 6e 64 65 78 2b | 2b 3b 0d 0a 09 09 09 69 |..index+|+;.....i|
|000037d0| 66 20 28 69 6e 64 65 78 | 20 3d 3d 20 31 30 30 30 |f (index| == 1000|
|000037e0| 29 0d 0a 09 09 09 09 69 | 6e 64 65 78 20 3d 20 30 |)......i|ndex = 0|
|000037f0| 3b 0d 0a 09 09 7d 0d 0a | 0d 0a 09 09 72 65 74 75 |;....}..|....retu|
|00003800| 72 6e 20 6d 6f 76 65 73 | 20 5b 69 6e 64 65 78 5d |rn moves| [index]|
|00003810| 3b 0d 0a 09 7d 0d 0a 0d | 0a 09 73 69 6d 75 6c 61 |;...}...|..simula|
|00003820| 74 65 64 20 66 75 6e 63 | 74 69 6f 6e 20 50 72 6f |ted func|tion Pro|
|00003830| 63 65 73 73 4d 6f 76 65 | 6d 65 6e 74 20 28 29 0d |cessMove|ment ().|
|00003840| 0a 09 7b 0d 0a 09 09 6c | 6f 63 61 6c 20 4d 6f 76 |..{....l|ocal Mov|
|00003850| 65 6d 65 6e 74 20 6d 31 | 2c 20 6d 32 2c 20 6d 33 |ement m1|, m2, m3|
|00003860| 3b 0d 0a 0d 0a 09 09 69 | 66 20 28 6d 6f 76 65 74 |;......i|f (movet|
|00003870| 61 69 6c 20 3d 3d 20 6d | 6f 76 65 68 65 61 64 29 |ail == m|ovehead)|
|00003880| 0d 0a 09 09 09 72 65 74 | 75 72 6e 3b 0d 0a 0d 0a |.....ret|urn;....|
|00003890| 09 09 69 66 20 28 6d 6f | 76 65 73 5b 6d 6f 76 65 |..if (mo|ves[move|
|000038a0| 74 61 69 6c 5d 2e 74 69 | 6d 65 20 3c 20 63 75 72 |tail].ti|me < cur|
|000038b0| 72 65 6e 74 54 69 6d 65 | 29 20 7b 0d 0a 09 09 09 |rentTime|) {.....|
|000038c0| 6d 31 20 3d 20 6d 6f 76 | 65 73 5b 6d 6f 76 65 74 |m1 = mov|es[movet|
|000038d0| 61 69 6c 5d 3b 0d 0a 09 | 09 09 2f 2f 6c 6f 67 20 |ail];...|..//log |
|000038e0| 28 22 50 72 6f 63 65 73 | 73 69 6e 67 20 6d 6f 76 |("Proces|sing mov|
|000038f0| 65 20 74 6f 3a 20 22 20 | 24 20 74 6d 70 2e 6c 6f |e to: " |$ tmp.lo|
|00003900| 63 20 24 20 22 20 2d 20 | 22 20 24 20 74 6d 70 2e |c $ " - |" $ tmp.|
|00003910| 72 6f 74 29 3b 0d 0a 0d | 0a 09 09 09 6d 6f 76 65 |rot);...|....move|
|00003920| 74 61 69 6c 2b 2b 3b 0d | 0a 09 09 09 69 66 20 28 |tail++;.|....if (|
|00003930| 6d 6f 76 65 74 61 69 6c | 20 3d 3d 20 31 30 30 30 |movetail| == 1000|
|00003940| 29 0d 0a 09 09 09 09 6d | 6f 76 65 74 61 69 6c 20 |)......m|ovetail |
|00003950| 3d 20 30 3b 0d 0a 0d 0a | 09 09 09 2f 2f 43 61 6c |= 0;....|...//Cal|
|00003960| 63 75 6c 61 74 65 20 6e | 65 77 20 69 6e 74 65 72 |culate n|ew inter|
|00003970| 70 6f 6c 61 74 69 6f 6e | 20 76 61 6c 75 65 73 0d |polation| values.|
|00003980| 0a 0d 0a 09 09 09 6d 32 | 20 3d 20 47 65 74 4e 65 |......m2| = GetNe|
|00003990| 78 74 4d 6f 76 65 6d 65 | 6e 74 20 28 30 29 3b 0d |xtMoveme|nt (0);.|
|000039a0| 0a 09 09 09 6d 33 20 3d | 20 47 65 74 4e 65 78 74 |....m3 =| GetNext|
|000039b0| 4d 6f 76 65 6d 65 6e 74 | 20 28 31 29 3b 0d 0a 0d |Movement| (1);...|
|000039c0| 0a 09 09 09 2f 2f 4c 6f | 67 20 28 22 70 72 6f 63 |....//Lo|g ("proc|
|000039d0| 65 73 73 69 6e 67 20 6d | 6f 76 65 73 20 66 72 6f |essing m|oves fro|
|000039e0| 6d 3a 20 22 20 24 20 6d | 31 2e 74 69 6d 65 20 24 |m: " $ m|1.time $|
|000039f0| 20 22 20 2d 20 22 20 24 | 20 6d 32 2e 74 69 6d 65 | " - " $| m2.time|
|00003a00| 20 24 20 22 20 2d 20 22 | 20 24 20 6d 33 2e 74 69 | $ " - "| $ m3.ti|
|00003a10| 6d 65 29 3b 0d 0a 0d 0a | 09 09 09 46 69 78 52 6f |me);....|...FixRo|
|00003a20| 74 44 69 73 74 20 28 6d | 31 2e 72 6f 74 2e 70 69 |tDist (m|1.rot.pi|
|00003a30| 74 63 68 2c 20 6d 32 2e | 72 6f 74 2e 70 69 74 63 |tch, m2.|rot.pitc|
|00003a40| 68 29 3b 0d 0a 09 09 09 | 46 69 78 52 6f 74 44 69 |h);.....|FixRotDi|
|00003a50| 73 74 20 28 6d 32 2e 72 | 6f 74 2e 70 69 74 63 68 |st (m2.r|ot.pitch|
|00003a60| 2c 20 6d 33 2e 72 6f 74 | 2e 70 69 74 63 68 2c 20 |, m3.rot|.pitch, |
|00003a70| 74 72 75 65 29 3b 0d 0a | 09 09 09 46 69 78 52 6f |true);..|...FixRo|
|00003a80| 74 44 69 73 74 20 28 6d | 31 2e 72 6f 74 2e 79 61 |tDist (m|1.rot.ya|
|00003a90| 77 2c 20 6d 32 2e 72 6f | 74 2e 79 61 77 29 3b 0d |w, m2.ro|t.yaw);.|
|00003aa0| 0a 09 09 09 46 69 78 52 | 6f 74 44 69 73 74 20 28 |....FixR|otDist (|
|00003ab0| 6d 32 2e 72 6f 74 2e 79 | 61 77 2c 20 6d 33 2e 72 |m2.rot.y|aw, m3.r|
|00003ac0| 6f 74 2e 79 61 77 2c 20 | 74 72 75 65 29 3b 0d 0a |ot.yaw, |true);..|
|00003ad0| 0d 0a 09 09 09 2f 2f 43 | 6f 6f 72 64 69 6e 61 74 |.....//C|oordinat|
|00003ae0| 65 73 0d 0a 09 09 09 43 | 61 6c 63 75 6c 61 74 65 |es.....C|alculate|
|00003af0| 49 6e 74 65 72 70 6f 6c | 20 28 30 2c 20 6d 31 2e |Interpol| (0, m1.|
|00003b00| 74 69 6d 65 2c 20 6d 32 | 2e 74 69 6d 65 2c 20 6d |time, m2|.time, m|
|00003b10| 33 2e 74 69 6d 65 2c 20 | 6d 31 2e 6c 6f 63 2e 78 |3.time, |m1.loc.x|
|00003b20| 2c 20 6d 32 2e 6c 6f 63 | 2e 78 2c 20 6d 33 2e 6c |, m2.loc|.x, m3.l|
|00003b30| 6f 63 2e 78 29 3b 0d 0a | 09 09 09 43 61 6c 63 75 |oc.x);..|...Calcu|
|00003b40| 6c 61 74 65 49 6e 74 65 | 72 70 6f 6c 20 28 31 2c |lateInte|rpol (1,|
|00003b50| 20 6d 31 2e 74 69 6d 65 | 2c 20 6d 32 2e 74 69 6d | m1.time|, m2.tim|
|00003b60| 65 2c 20 6d 33 2e 74 69 | 6d 65 2c 20 6d 31 2e 6c |e, m3.ti|me, m1.l|
|00003b70| 6f 63 2e 79 2c 20 6d 32 | 2e 6c 6f 63 2e 79 2c 20 |oc.y, m2|.loc.y, |
|00003b80| 6d 33 2e 6c 6f 63 2e 79 | 29 3b 0d 0a 09 09 09 43 |m3.loc.y|);.....C|
|00003b90| 61 6c 63 75 6c 61 74 65 | 49 6e 74 65 72 70 6f 6c |alculate|Interpol|
|00003ba0| 20 28 32 2c 20 6d 31 2e | 74 69 6d 65 2c 20 6d 32 | (2, m1.|time, m2|
|00003bb0| 2e 74 69 6d 65 2c 20 6d | 33 2e 74 69 6d 65 2c 20 |.time, m|3.time, |
|00003bc0| 6d 31 2e 6c 6f 63 2e 7a | 2c 20 6d 32 2e 6c 6f 63 |m1.loc.z|, m2.loc|
|00003bd0| 2e 7a 2c 20 6d 33 2e 6c | 6f 63 2e 7a 29 3b 0d 0a |.z, m3.l|oc.z);..|
|00003be0| 0d 0a 09 09 09 2f 2f 52 | 6f 74 61 74 69 6f 6e 0d |.....//R|otation.|
|00003bf0| 0a 09 09 09 43 61 6c 63 | 75 6c 61 74 65 49 6e 74 |....Calc|ulateInt|
|00003c00| 65 72 70 6f 6c 20 28 33 | 2c 20 6d 31 2e 74 69 6d |erpol (3|, m1.tim|
|00003c10| 65 2c 20 6d 32 2e 74 69 | 6d 65 2c 20 6d 33 2e 74 |e, m2.ti|me, m3.t|
|00003c20| 69 6d 65 2c 20 6d 31 2e | 72 6f 74 2e 70 69 74 63 |ime, m1.|rot.pitc|
|00003c30| 68 2c 20 6d 32 2e 72 6f | 74 2e 70 69 74 63 68 2c |h, m2.ro|t.pitch,|
|00003c40| 20 6d 33 2e 72 6f 74 2e | 70 69 74 63 68 29 3b 0d | m3.rot.|pitch);.|
|00003c50| 0a 09 09 09 43 61 6c 63 | 75 6c 61 74 65 49 6e 74 |....Calc|ulateInt|
|00003c60| 65 72 70 6f 6c 20 28 34 | 2c 20 6d 31 2e 74 69 6d |erpol (4|, m1.tim|
|00003c70| 65 2c 20 6d 32 2e 74 69 | 6d 65 2c 20 6d 33 2e 74 |e, m2.ti|me, m3.t|
|00003c80| 69 6d 65 2c 20 6d 31 2e | 72 6f 74 2e 79 61 77 2c |ime, m1.|rot.yaw,|
|00003c90| 20 6d 32 2e 72 6f 74 2e | 79 61 77 2c 20 6d 33 2e | m2.rot.|yaw, m3.|
|00003ca0| 72 6f 74 2e 79 61 77 29 | 3b 0d 0a 09 09 7d 0d 0a |rot.yaw)|;....}..|
|00003cb0| 09 7d 0d 0a 0d 0a 09 73 | 69 6d 75 6c 61 74 65 64 |.}.....s|imulated|
|00003cc0| 20 66 75 6e 63 74 69 6f | 6e 20 52 65 63 65 69 76 | functio|n Receiv|
|00003cd0| 65 4d 6f 76 65 6d 65 6e | 74 20 28 73 74 72 69 6e |eMovemen|t (strin|
|00003ce0| 67 20 73 29 0d 0a 09 7b | 0d 0a 09 20 09 6c 6f 63 |g s)...{|... .loc|
|00003cf0| 61 6c 20 4d 6f 76 65 6d | 65 6e 74 20 74 6d 70 3b |al Movem|ent tmp;|
|00003d00| 0d 0a 09 20 09 6c 6f 63 | 61 6c 20 73 74 72 69 6e |... .loc|al strin|
|00003d10| 67 20 74 6d 70 73 3b 0d | 0a 09 20 09 6c 6f 63 61 |g tmps;.|.. .loca|
|00003d20| 6c 20 69 6e 74 20 69 3b | 0d 0a 0d 0a 09 20 09 2f |l int i;|..... ./|
|00003d30| 2f 50 61 72 73 65 20 6f | 75 74 20 74 68 65 20 76 |/Parse o|ut the v|
|00003d40| 61 6c 75 65 73 0d 0a 09 | 20 09 69 20 3d 20 49 6e |alues...| .i = In|
|00003d50| 53 74 72 20 28 73 2c 20 | 22 20 22 29 3b 0d 0a 09 |Str (s, |" ");...|
|00003d60| 20 09 74 6d 70 73 20 3d | 20 4d 69 64 20 28 73 2c | .tmps =| Mid (s,|
|00003d70| 20 30 2c 20 69 29 3b 0d | 0a 09 20 09 74 6d 70 2e | 0, i);.|.. .tmp.|
|00003d80| 6c 6f 63 20 3d 20 76 65 | 63 74 6f 72 20 28 74 6d |loc = ve|ctor (tm|
|00003d90| 70 73 29 3b 0d 0a 09 20 | 09 73 20 3d 20 4d 69 64 |ps);... |.s = Mid|
|00003da0| 20 28 73 2c 20 69 20 2b | 20 31 29 3b 0d 0a 0d 0a | (s, i +| 1);....|
|00003db0| 09 20 09 74 6d 70 2e 72 | 6f 74 20 3d 20 72 6f 74 |. .tmp.r|ot = rot|
|00003dc0| 61 74 6f 72 20 28 73 29 | 3b 0d 0a 0d 0a 09 09 2f |ator (s)|;....../|
|00003dd0| 2f 4c 6f 67 20 28 22 47 | 6f 74 20 6d 6f 76 65 6d |/Log ("G|ot movem|
|00003de0| 65 6e 74 3a 20 22 20 24 | 20 74 6d 70 2e 74 69 6d |ent: " $| tmp.tim|
|00003df0| 65 20 24 20 22 20 2d 20 | 22 20 24 20 74 6d 70 2e |e $ " - |" $ tmp.|
|00003e00| 6c 6f 63 20 24 20 22 20 | 2d 20 22 20 24 20 74 6d |loc $ " |- " $ tm|
|00003e10| 70 2e 72 6f 74 29 3b 0d | 0a 0d 0a 09 20 09 2f 2f |p.rot);.|.... .//|
|00003e20| 74 65 73 74 0d 0a 09 20 | 09 74 6d 70 2e 74 69 6d |test... |.tmp.tim|
|00003e30| 65 20 3d 20 63 75 72 72 | 65 6e 74 54 69 6d 65 20 |e = curr|entTime |
|00003e40| 2b 20 35 3b 0d 0a 0d 0a | 09 20 09 2f 2f 41 6e 64 |+ 5;....|. .//And|
|00003e50| 20 69 6e 73 65 72 74 20 | 69 74 20 69 6e 74 6f 20 | insert |it into |
|00003e60| 74 68 65 20 71 75 65 75 | 65 0d 0a 09 20 09 69 66 |the queu|e... .if|
|00003e70| 20 28 6d 6f 76 65 68 65 | 61 64 20 3d 3d 20 6d 6f | (movehe|ad == mo|
|00003e80| 76 65 74 61 69 6c 29 20 | 7b 0d 0a 09 20 09 09 6d |vetail) |{... ..m|
|00003e90| 6f 76 65 73 5b 6d 6f 76 | 65 68 65 61 64 5d 20 3d |oves[mov|ehead] =|
|00003ea0| 20 74 6d 70 3b 0d 0a 09 | 20 09 09 6d 6f 76 65 68 | tmp;...| ..moveh|
|00003eb0| 65 61 64 2b 2b 3b 0d 0a | 09 20 09 09 69 66 20 28 |ead++;..|. ..if (|
|00003ec0| 6d 6f 76 65 68 65 61 64 | 20 3d 3d 20 31 30 30 30 |movehead| == 1000|
|00003ed0| 29 0d 0a 09 20 09 09 09 | 6d 6f 76 65 68 65 61 64 |)... ...|movehead|
|00003ee0| 20 3d 20 30 3b 0d 0a 09 | 20 09 7d 0d 0a 09 20 09 | = 0;...| .}... .|
|00003ef0| 65 6c 73 65 20 7b 0d 0a | 09 20 09 09 2f 2f 4d 61 |else {..|. ..//Ma|
|00003f00| 6b 65 20 73 75 72 65 20 | 77 65 20 6f 6e 6c 79 20 |ke sure |we only |
|00003f10| 69 6e 73 65 72 74 20 6e | 65 77 65 72 20 74 68 69 |insert n|ewer thi|
|00003f20| 6e 67 73 0d 0a 09 20 09 | 09 69 20 3d 20 6d 6f 76 |ngs... .|.i = mov|
|00003f30| 65 68 65 61 64 20 2d 20 | 31 3b 0d 0a 09 20 09 09 |ehead - |1;... ..|
|00003f40| 69 66 20 28 69 20 3c 20 | 30 29 0d 0a 09 20 09 09 |if (i < |0)... ..|
|00003f50| 09 69 20 3d 20 39 39 39 | 3b 0d 0a 09 20 09 09 69 |.i = 999|;... ..i|
|00003f60| 66 20 28 74 6d 70 2e 74 | 69 6d 65 20 3e 20 6d 6f |f (tmp.t|ime > mo|
|00003f70| 76 65 73 5b 69 5d 2e 74 | 69 6d 65 29 20 7b 0d 0a |ves[i].t|ime) {..|
|00003f80| 09 20 09 09 09 6d 6f 76 | 65 73 5b 6d 6f 76 65 68 |. ...mov|es[moveh|
|00003f90| 65 61 64 5d 20 3d 20 74 | 6d 70 3b 0d 0a 09 20 09 |ead] = t|mp;... .|
|00003fa0| 09 09 6d 6f 76 65 68 65 | 61 64 2b 2b 3b 0d 0a 09 |..movehe|ad++;...|
|00003fb0| 20 09 09 09 69 66 20 28 | 6d 6f 76 65 68 65 61 64 | ...if (|movehead|
|00003fc0| 20 3d 3d 20 31 30 30 30 | 29 0d 0a 09 20 09 09 09 | == 1000|)... ...|
|00003fd0| 09 6d 6f 76 65 68 65 61 | 64 20 3d 20 30 3b 0d 0a |.movehea|d = 0;..|
|00003fe0| 09 20 09 09 7d 0d 0a 09 | 20 09 7d 0d 0a 09 7d 0d |. ..}...| .}...}.|
|00003ff0| 0a 0d 0a 09 73 69 6d 75 | 6c 61 74 65 64 20 66 75 |....simu|lated fu|
|00004000| 6e 63 74 69 6f 6e 20 42 | 65 67 69 6e 53 74 61 74 |nction B|eginStat|
|00004010| 65 20 28 29 0d 0a 09 7b | 0d 0a 09 09 6c 6f 67 20 |e ()...{|....log |
|00004020| 28 22 75 74 76 3a 20 45 | 6e 74 65 72 69 6e 67 20 |("utv: E|ntering |
|00004030| 73 65 63 6f 6e 64 61 72 | 79 20 73 74 61 74 65 22 |secondar|y state"|
|00004040| 29 3b 0d 0a 09 7d 0d 0a | 7d 0d 0a 0d 0a 73 69 6d |);...}..|}....sim|
|00004050| 75 6c 61 74 65 64 20 66 | 75 6e 63 74 69 6f 6e 20 |ulated f|unction |
|00004060| 20 47 65 74 4e 65 78 74 | 50 6c 61 79 65 72 28 29 | GetNext|Player()|
|00004070| 0d 0a 7b 0d 0a 09 6c 6f | 63 61 6c 20 50 61 77 6e |..{...lo|cal Pawn|
|00004080| 20 74 65 6d 70 50 61 77 | 6e 3b 0d 0a 09 6c 6f 63 | tempPaw|n;...loc|
|00004090| 61 6c 20 73 74 72 69 6e | 67 20 74 61 72 67 65 74 |al strin|g target|
|000040a0| 4e 61 6d 65 3b 0d 0a 09 | 6c 6f 63 61 6c 20 62 6f |Name;...|local bo|
|000040b0| 6f 6c 20 67 65 74 4e 65 | 78 74 3b 0d 0a 0d 0a 09 |ol getNe|xt;.....|
|000040c0| 67 65 74 4e 65 78 74 3d | 74 72 75 65 3b 0d 0a 09 |getNext=|true;...|
|000040d0| 66 6f 72 65 61 63 68 20 | 41 6c 6c 41 63 74 6f 72 |foreach |AllActor|
|000040e0| 73 28 63 6c 61 73 73 27 | 50 61 77 6e 27 2c 74 65 |s(class'|Pawn',te|
|000040f0| 6d 70 50 61 77 6e 29 7b | 0d 0a 09 09 69 66 28 74 |mpPawn){|....if(t|
|00004100| 65 6d 70 50 61 77 6e 2e | 50 6c 61 79 65 72 52 65 |empPawn.|PlayerRe|
|00004110| 70 6c 69 63 61 74 69 6f | 6e 49 6e 66 6f 21 3d 6e |plicatio|nInfo!=n|
|00004120| 6f 6e 65 29 7b 0d 0a 09 | 09 09 69 66 28 47 65 74 |one){...|..if(Get|
|00004130| 4e 65 78 74 29 7b 0d 0a | 09 09 09 09 47 65 74 4e |Next){..|....GetN|
|00004140| 65 78 74 3d 66 61 6c 73 | 65 3b 0d 0a 09 09 09 09 |ext=fals|e;......|
|00004150| 54 61 72 67 65 74 4e 61 | 6d 65 3d 74 65 6d 70 50 |TargetNa|me=tempP|
|00004160| 61 77 6e 2e 50 6c 61 79 | 65 72 52 65 70 6c 69 63 |awn.Play|erReplic|
|00004170| 61 74 69 6f 6e 49 6e 66 | 6f 2e 50 6c 61 79 65 72 |ationInf|o.Player|
|00004180| 4e 61 6d 65 3b 0d 0a 09 | 09 09 7d 0d 0a 0d 0a 09 |Name;...|..}.....|
|00004190| 09 09 69 66 28 74 65 6d | 70 50 61 77 6e 2e 50 6c |..if(tem|pPawn.Pl|
|000041a0| 61 79 65 72 52 65 70 6c | 69 63 61 74 69 6f 6e 49 |ayerRepl|icationI|
|000041b0| 6e 66 6f 2e 50 6c 61 79 | 65 72 4e 61 6d 65 3d 3d |nfo.Play|erName==|
|000041c0| 4c 61 73 74 54 61 72 67 | 65 74 4e 61 6d 65 29 7b |LastTarg|etName){|
|000041d0| 0d 0a 09 09 09 09 47 65 | 74 4e 65 78 74 3d 74 72 |......Ge|tNext=tr|
|000041e0| 75 65 3b 0d 0a 09 09 09 | 7d 0d 0a 09 09 7d 0d 0a |ue;.....|}....}..|
|000041f0| 09 7d 0d 0a 09 4c 61 73 | 74 54 61 72 67 65 74 4e |.}...Las|tTargetN|
|00004200| 61 6d 65 3d 54 61 72 67 | 65 74 4e 61 6d 65 3b 0d |ame=Targ|etName;.|
|00004210| 0a 7d 0d 0a 0d 0a 73 69 | 6d 75 6c 61 74 65 64 20 |.}....si|mulated |
|00004220| 66 75 6e 63 74 69 6f 6e | 20 50 61 77 6e 20 47 65 |function| Pawn Ge|
|00004230| 74 50 61 77 6e 46 72 6f | 6d 4e 61 6d 65 28 73 74 |tPawnFro|mName(st|
|00004240| 72 69 6e 67 20 6e 61 6d | 65 29 0d 0a 7b 0d 0a 09 |ring nam|e)..{...|
|00004250| 6c 6f 63 61 6c 20 50 61 | 77 6e 20 74 65 6d 70 50 |local Pa|wn tempP|
|00004260| 61 77 6e 3b 0d 0a 0d 0a | 09 66 6f 72 65 61 63 68 |awn;....|.foreach|
|00004270| 20 41 6c 6c 41 63 74 6f | 72 73 28 63 6c 61 73 73 | AllActo|rs(class|
|00004280| 27 50 61 77 6e 27 2c 74 | 65 6d 70 50 61 77 6e 29 |'Pawn',t|empPawn)|
|00004290| 7b 0d 0a 09 09 69 66 28 | 74 65 6d 70 50 61 77 6e |{....if(|tempPawn|
|000042a0| 2e 50 6c 61 79 65 72 52 | 65 70 6c 69 63 61 74 69 |.PlayerR|eplicati|
|000042b0| 6f 6e 49 6e 66 6f 21 3d | 6e 6f 6e 65 20 26 26 20 |onInfo!=|none && |
|000042c0| 74 65 6d 70 50 61 77 6e | 2e 50 6c 61 79 65 72 52 |tempPawn|.PlayerR|
|000042d0| 65 70 6c 69 63 61 74 69 | 6f 6e 49 6e 66 6f 2e 50 |eplicati|onInfo.P|
|000042e0| 6c 61 79 65 72 4e 61 6d | 65 3d 3d 6e 61 6d 65 29 |layerNam|e==name)|
|000042f0| 7b 0d 0a 09 09 09 72 65 | 74 75 72 6e 20 74 65 6d |{.....re|turn tem|
|00004300| 70 50 61 77 6e 3b 0d 0a | 09 09 09 62 72 65 61 6b |pPawn;..|...break|
|00004310| 3b 0d 0a 09 09 7d 0d 0a | 09 7d 0d 0a 09 72 65 74 |;....}..|.}...ret|
|00004320| 75 72 6e 20 6e 6f 6e 65 | 3b 0d 0a 7d 0d 0a 0d 0a |urn none|;..}....|
|00004330| 00 | |. | |
+--------+-------------------------+-------------------------+--------+--------+