*E@(fK-AsJeNone GetTimeStampLogEventString BufferLogGetID GameStartedGetWeaponName LogSpree LogComboCoreEngineUTStatsBeta4_2_Rev100 FindMutator AddToBufferIPOnlySystem AddMutatorLogStandardInfoLogKillLogMutatorListzzSetup SpectatorConsoleCommandLogIPGetIPFixAssaultGameCodeSetIP TeamGamePlusAssaultLogAssaultObj GetFortNameProcessBufferCriticalEventClientMessage GetShotCount GetHitCount GetDamageGetAccu GetAccuracy PreBeginPlayPostBeginPlayGetRI PlayerInfoUTStats InstaGibDM UTStatsAHPawn FortStandard PlayerPawnUTStatsHTTPClientUser UTStatsSAbHidden LogPickup LogGameEnd LogSuicide UBrowserClientVoiceMessage GetLocalIPIpAddrToString FortInfo UTGLCatcher StartLogGetLogFileNameLogPlayerConnectLogPlayerInfoTick LogTeamKillLogMapParametersLogItemActivateLogServerInfoTouchLogItemDeactivate zzVersionLogPlayerDisconnectLogGameParameters LogPingsGetAbsoluteTimeIpDrv LogGameStartLogSpecialEvent TeamMessage bIsPlayerGetNextIntDescTypeGetPlayerNetworkAddress DeltaTimeOtherNum EventTypeIndexMItem GameClass NumPlayersScorebWorld MessageTypePRI RecipientGame KillerIDKillerWeaponNameVictimWeaponName InstigatorArg2Arg3Arg4Reason nextPawnSpreebBeep TimeSecondsEngineVersion PawnList CurrentID BaseMutator LocalLogLocalLogFileName NextMutator PlayerIDSender MessageID Checksum VictimIDArg1 bDisabled GameNameKilledMessagingSpectator DamageTypeIpAddrFUBrowserHTTPClientPartTeams TeamInfo MaxTeams TimeLimitABotpackDeathMatchPlusji ScriptText CountDown bTournament FortNameS bFinalFort bFirstBlood GameCodeUTSAccuBeta4_2 ReturnValuePiMutator LevelInfo GameInfoPlayerReplicationInfoStatLogUTSReplicationInfo UTSDamageMut StatLogFileGameReplicationInfoUTSDMzzPID bDeleteObjbUTStatsRunningzzIndexzzRIbInstazzIP InventoryLevelActorPlayerTag zzLogger zzAssault bEndGame bFinalObj zzNumForts zzRemFortsEventzzFSbTaken zzFortNamezzFIClassPackage bObjFound bUTGLEnabled bGameStarted zzComboCode zzBuffer TextBufferzzGLTagzzMutatorList zzEndTime zzWarmupTimezzPHPoszzPawnzzIDzzSpreezzCombozzKills zzDeaths zzSuicides zzTeamKills zzLastKill zzJoinTime bHasFlagzzLoginUTSAHUTSHTTPzzServerActors zzUTGLVer zzMutatorObjectzzMyIP zzKillerID zzVictimID FunctionStruct bDisconnectzzNow zzKilledNewPawn UnrealShare bReconnected StrProperty zzPlayerID zzAccuracy zzEfficiencyzzTTLzzTimeOnServerStructPropertyzzTagzzTypezzValueClassProperty NamePropertyPID zzGLInfo zzOffsetObjectProperty zzFortIDFloatProperty BoolPropertyzzEntryzzDesczzNum IntPropertyDisabledClassesMutName ByteProperty InternetLink3!@L\:HA+!JԞD=$:e-%n-%n}"#}"#8LNt8LNtt{#U"{"{"{"{"{"{"{"{"{"{"{7̮7̮t> Yt{#Uttt{#Uttt{#Ut{#Utt{#Ut{#U=$:e8LN23^23^ I]0.4.2q( @N#5@d;OMa@Sln- 67̮ oE=btE=btE=bԑE=bt{#UE=bE=bE=bE=bԓ ԓ  24"=@p@@pT+@|^@ @N@CZ'[E123^釅m 8N l@X@@@VW]9VY!`@02.Kbc&hAEB}NS@@Dm@GF_F@ e%s@@<xQn@iS@t?rv@1z@y{@@@A@@~BfH@@@GI@J@M$*V@-<LWO2"pp, game_start P[62`fw3*z[Assault succeeded!3-l'3 !! [%, 6,!' 6x LI/O!=0%F0, 600%#spree_dbl&#spree_mult,#spree_ult,#spree_monZ*get Engine.GameEngine ServerActors~ZGLACTOR-M'### ___________________________________### ### # # ### ### ### # ### ### ### # # # # # # # # # ### # # # ### # # # # ### ### # # # # # ### # # ### ### # ### # # # # ### ### ___________________________________###p### - Version : a### - UTGL Running :T-M### ___________________________________pppppp, info, Log_Standard, UTStatspppppp, info, Log_Version, apppppp, info, Game_Name, pppppp, info, Game_Version, pppppp, info, Absolute_Time, M-u|$get UdpServerUplink douplinkT'pppppp, info, Server_Public, 1pppppp, info, Server_Public, 0pppppp, info, utglenabled, T-M/a0 YYa/!,-N'106--Npppppp, game, insta, T-NIa 2IIa Y@Q 6r6$* 6)6$Sr* \6&6$E?D6BD_6%VE?6VE]666"6+%DD?6?666"6+Bstat_playeraccuracy6U\stat_playerscore6SD6$stat_playerfrags6S66"stat_playerkills6S6stat_playerdeaths6S6stat_playersuicides6S6"stat_playerteamkills6S6+stat_playerefficiency6UDstat_playertime_on_server6U6Bstat_playerttl6UV % |  translocatorweap_shotcount  6S " weap_hitcount  6S # weap_damagegiven  6S $ weap_accuracy  6U %  D-' OE// ============================================================================= // # # ### ### ### # ### ### // # # # # # # # # # // # # # ### # # # # ### // # # # # # ### # # // ### # ### # # # # ### // Beta 4.2 // ============================================================================= // UTStats Team: // * Azazel (Main PHP Coder) // * Toa (PHP Coder) // * AnthraX (Unrealscript Coder) // UTStats Forum: // * http://www.unrealadmin.org/forums/forumdisplay.php?f=173 // Released under the Unreal Open MOD License (included in zip package) // ============================================================================= class UTStatsSA extends Actor config; var UTStats LocalLog; var UTStatsAH UTSAH; var UTSDamageMut UTSDM; var bool bDisabled; var config string DisabledClasses[8]; // ============================================================================= // PreBeginPlay ~ Call the gamecode fix before the assault class sets it // ============================================================================= function PreBeginPlay() { local int i; for(i=0;i<8;i++) if(DisabledClasses[i]==Level.Game.GameReplicationInfo.GameClass && DisabledClasses[i]!="") { bDisabled=True; } if(!bDisabled){ Super.PreBeginPlay(); if (!Level.Game.IsA('Assault')) return; FixAssaultGameCode(); } } // ============================================================================= // PostBeginPlay ~ Setup UTStats // ============================================================================= function PostBeginPlay() { local Mutator M; if(!bDisabled){ // Spawn the mutator that will handle the accuracy UTSDM = UTSDamageMut(FindMutator("UTSDamageMut")); if (UTSDM == None) { Level.Game.BaseMutator.AddMutator(Level.Spawn(class'UTSDamageMut')); UTSDM = UTSDamageMut(FindMutator("UTSDamageMut")); if (UTSDM == None) { Log("### ERROR: UTStats cannot run without the UTSAccu package!"); return; } } //Log("### UTSAccu package linked!"); UTSDM.bUTStatsRunning = true; // Spawn the statlog class and log standard info LocalLog = spawn(Class'UTStats'); LocalLog.bWorld = False; LocalLog.UTSDM = UTSDM; LocalLog.StartLog(); LocalLog.LogStandardInfo(); LocalLog.LogServerInfo(); LocalLog.LogMapParameters(); for (M = Level.Game.BaseMutator; M != None; M = M.NextMutator) LocalLog.AddMutator(M); LocalLog.LogMutatorList(); Level.Game.LogGameParameters(LocalLog); Level.Game.LocalLog = LocalLog; Level.Game.LocalLogFileName = LocalLog.GetLogFileName(); // Spawn the messaging spectator that will parse assault messages if (!Level.Game.IsA('Assault')) return; UTSAH = Level.Spawn(class'UTStatsAH'); UTSAH.zzLogger = LocalLog; UTSAH.zzAssault = Assault(Level.Game); UTSAH.zzSetup(); LocalLog.UTSAH = UTSAH; } } // ============================================================================= // FindMutator function // ============================================================================= function Mutator FindMutator (string MutName) { local Mutator M; M = Level.Game.BaseMutator; while (M != None) { if (InStr(M.class,MutName) != -1) return M; else M = M.NextMutator; } return M; } // ============================================================================= // FixAssaultGameCode ~ Cratos' fix for some epic fuckup // ============================================================================= function FixAssaultGameCode() { local int i; local int num; if (Assault(Level.Game).GameCode == "") { while (i<8) { Num = Rand(123); if ( ((Num >= 48) && (Num <= 57)) || ((Num >= 65) && (Num <= 91)) || ((Num >= 97) && (Num <= 123)) ) { Assault(Level.Game).GameCode = Assault(Level.Game).GameCode $ Chr(Num); i++; } } } } // ============================================================================= // Defaultproperties // ============================================================================= @`,>13+~,:,,~,:, 6UU31ZԝX   =$:e=$:e=$:e8LNԃ=$:eԔ=$:eԃԃ7̮7̮7̮ԃ'n 6 4Gclass UTStatsHTTPClient extends UBrowserHTTPClient; function string GetIP () { local IPAddr IPAddr; // Added by Cratos GetLocalIP(IpAddr); return IpAddrToString(IPAddr); } TKw@Cpppppppp:::K, J, SI, G X]RHs Apppppp, info, True_Server_IP, H eP/1Pa/!0&.P@&0.0.0.0&&pppppppp, player, IP, SP, & \JQA2a~:::J~:::pp, JJ,pp, 0a/!.%0..pppppp, teamscore, S., SD... _RA~uOR%E, ;6E6R6$R6:%6&6%6%6"%6+%6@6W6B-6( NL8%Gpppp, assault_timelimit, S4\pppppp, assault_gamecode, 4, S4/ a0 L69Le{69Tpppppp, assault_objname, S, 696-L-6C(10S aD3DE)%=), 36)D)) uEB.EFw*-F@F )diGE_FQ Fz ,UTGLJOIN~ , Z  &~ , OJ   &~ , 5 {5cO6Mc5pppppppp, player, GLLogin, SO, 5  gjR4class UTStatsAH extends MessagingSpectator; var UTStats zzLogger; var Assault zzAssault; var bool bEndGame,bFinalObj; var int zzNumForts, zzRemForts; struct FortInfo { var FortStandard zzFS; var bool bTaken; var string zzFortName; }; var FortInfo zzFI[16]; // ============================================================================= // zzSetup ~ Setup the class // ============================================================================= function zzSetup() { local FortStandard zzFS; local string zzFortName; zzNumForts = 0; zzLogger.LogEventString(zzLogger.GetTimeStamp()$Chr(9)$"assault_timelimit"$chr(9)$zzAssault.TimeLimit); zzLogger.LogEventString(zzLogger.GetTimeStamp()$Chr(9)$"assault_gamecode"$chr(9)$zzAssault.GameCode$chr(9)$zzAssault.Part); foreach Level.AllActors(class'FortStandard',zzFS) { zzFI[zzNumForts].zzFortName = GetFortName(zzFS); if (zzFI[zzNumForts].zzFortName != "") zzLogger.LogEventString(zzLogger.GetTimeStamp()$Chr(9)$"assault_objname"$chr(9)$zzNumForts$chr(9)$zzFI[zzNumForts].zzFortName); zzFI[zzNumForts].zzFS = zzFS; zzFI[zzNumForts++].bTaken = false; } zzRemForts = zzNumForts; } // ============================================================================= // GetFortName ~ Added by cratos // ============================================================================= function string GetFortName(FortStandard F) { if ((F.FortName == "Assault Target") || (F.FortName == "") || (F.FortName == " ")) return ""; else return F.FortName; } // ============================================================================= // ClientMessage ~ Parse assault events // ============================================================================= event ClientMessage( coerce string S, optional name Type, optional bool bBeep ) { local int i; local bool bObjFound; if (Type != 'CriticalEvent' || (bEndGame && bFinalObj)) return; bObjFound = true; while (bObjFound) { bObjFound = false; for (i=0;i 1)) // Combo was still going on when player disconnected LogEventString(GetTimeStamp()$chr(9)$"spree"$chr(9)$zzComboCode[Clamp(PI[KillerID].zzCombo-2,0,3)]$chr(9)$PI[KillerID].zzID); else PI[KillerID].zzCombo++; } else { if (PI[KillerID].zzCombo > 1) LogEventString(GetTimeStamp()$chr(9)$"spree"$chr(9)$zzComboCode[Clamp(PI[KillerID].zzCombo-2,0,3)]$chr(9)$PI[KillerID].zzID); PI[KillerID].zzCombo = 1; } PI[KillerID].zzLastKill = zzNow; } // ============================================================================= // LogTeamKill ~ :/ // ============================================================================= function LogTeamKill( int KillerID, int VictimID, string KillerWeaponName, string VictimWeaponName, name DamageType ) { local int zzKillerID, zzVictimID; if (!Level.Game.IsA('TeamGamePlus')) { LogKill(KillerID,VictimID,KillerWeaponName,VictimWeaponName,DamageType); return; } if (!bGameStarted && !GameStarted()) return; zzKillerID = GetID(KillerID); zzVictimID = GetID(VictimID); PI[zzKillerID].zzTeamKills++; PI[zzVictimID].zzDeaths++; super.LogTeamKill(KillerID,VictimID,KillerWeaponName,VictimWeaponName,DamageType); if (PI[zzVictimID].bHasFlag) PI[zzVictimID].bHasFlag = false; } // ============================================================================= // LogSuicide // ============================================================================= function LogSuicide (Pawn Killed, name DamageType, Pawn Instigator) { local int zzKilled; if (!bGameStarted && !GameStarted()) return; zzKilled = GetID(Killed.PlayerReplicationInfo.PlayerID); PI[zzKilled].zzSuicides++; Super.LogSuicide(Killed,DamageType,Instigator); if (PI[zzKilled].bHasFlag) PI[zzKilled].bHasFlag = false; } // ============================================================================= // LogPlayerConnect ~ We don't like spectators // ============================================================================= function LogPlayerConnect(Pawn Player, optional string Checksum) { if (Player.IsA('Spectator')) return; super.LogPlayerConnect(Player,Checksum); } // ============================================================================= // LogPlayerDisconnect ~ Handle sprees/combos, then add to the buffer // ============================================================================= function LogPlayerDisconnect(Pawn Player) { local int i; if (Player.IsA('Spectator')) return; i = GetID(Player.PlayerReplicationInfo.PlayerID); LogEventString(GetTimeStamp()$Chr(9)$"player"$Chr(9)$"Disconnect"$Chr(9)$Player.PlayerReplicationInfo.PlayerID); PI[i].zzEndTime = Level.TimeSeconds; if (!bGameStarted && !GameStarted()) return; LogSpree(33,i); LogCombo(i,,true); AddToBuffer(i); PI[i].zzID = -1; } // ============================================================================= // LogSpecialEvent ~ Any gametype-specific event goes trough this function // Note: we don't log translocation events as it's a lot of spam and it's not // usefull at all // ============================================================================= function LogSpecialEvent(string EventType, optional coerce string Arg1, optional coerce string Arg2, optional coerce string Arg3, optional coerce string Arg4) { local int i; local string event; if ((InStr(EventType,"transloc") != -1) || (InStr(EventType,"dom_") != -1) && (Level.Game.NumPlayers == 0)) { if (EventType=="translocate") { i = GetID(int(Arg1)); PI[i].bHasFlag = false; } } else { super.LogSpecialEvent(EventType,Arg1,Arg2,Arg3,Arg4); } if (!bGameStarted && !GameStarted()) return; if (EventType=="flag_taken" || EventType=="flag_pickedup") { i = GetID(int(Arg1)); PI[i].bHasFlag = true; } else if (EventType=="flag_captured") { i = GetID(int(Arg1)); PI[i].bHasFlag = false; } } // ============================================================================= // We're using the tick function to set IP's // ============================================================================= function Tick (float DeltaTime) { local pawn NewPawn; super.Tick(DeltaTime); if (Level.Game.CurrentID > currentID) { for( NewPawn = Level.PawnList ; NewPawn!=None ; NewPawn = NewPawn.NextPawn ) { if(NewPawn.bIsPlayer && NewPawn.PlayerReplicationInfo.PlayerID == currentID) { SetIP(NewPawn); break; } } ++currentID; } } function SetIP( Pawn Player) { local string zzIP; local int i,j; local bool bReconnected; if (Player.IsA('PlayerPawn')) zzIP = PlayerPawn(Player).GetPlayerNetworkAddress(); else zzIP = "0.0.0.0"; zzIP = IPOnly(zzIP); LogEventString(GetTimeStamp()$Chr(9)$"player"$Chr(9)$"IP"$Chr(9)$Player.PlayerReplicationInfo.PlayerID$Chr(9)$zzIP); } function string IPOnly (string zzIP) { if (InStr(zzIP,":") != -1) zzIP = Left(zzIP,InStr(zzIP,":")); return zzIP; } // ============================================================================= // Game Start/End functions // ============================================================================= function LogGameStart() { LogEventString(GetTimeStamp()$Chr(9)$"game_start"); } function LogGameEnd( string Reason ) { local int i; zzEndTime = Level.TimeSeconds; if ((UTSAH != None) && (Reason == "Assault succeeded!")) { UTSAH.bEndGame = true; UTSAH.ClientMessage("",'CriticalEvent'); } Super.LogGameEnd(Reason); for (i=0;i<32;++i) { if (PI[i].zzID != -1) // Player is still on the server { LogSpree(33,i); LogCombo(i,true); AddToBuffer(i); PI[i].zzID = -1; } } ProcessBuffer(); } // ============================================================================= // Some lame code here. We want UTStats to log all playerstats at the end of the // game, not during the game. That's why we'll use a buffer. // ============================================================================= function AddToBuffer ( int zzPlayerID ) { local float zzAccuracy,zzEfficiency,zzTTL,zzTimeOnServer; local UTSReplicationInfo zzRI; local int i; if (PI[zzPlayerID].zzPawn == none) return; zzRI = UTSDM.GetRI(PI[zzPlayerID].zzPawn.PlayerReplicationInfo); if (zzRI == None) return; zzAccuracy = UTSDM.GetAccuracy(PI[zzPlayerID].zzPawn.PlayerReplicationInfo); zzTimeOnServer = Min(Level.TimeSeconds-PI[zzPlayerID].zzJoinTime,Level.TimeSeconds-zzWarmupTime); if (PI[zzPlayerID].zzDeaths != 0) zzTTL = zzTimeOnServer/(PI[zzPlayerID].zzDeaths) ; else zzTTL = zzTimeOnServer; if ((PI[zzPlayerID].zzKills+PI[zzPlayerID].zzDeaths+PI[zzPlayerID].zzSuicides+PI[zzPlayerID].zzTeamKills) == 0) zzEfficiency = 0.0; else zzEfficiency = float(PI[zzPlayerID].zzKills)/float(PI[zzPlayerID].zzKills+PI[zzPlayerID].zzDeaths+PI[zzPlayerID].zzSuicides+PI[zzPlayerID].zzTeamKills)*100.0; BufferLog("stat_player","accuracy",PI[zzPlayerID].zzID,string(zzAccuracy)); BufferLog("stat_player","score",PI[zzPlayerID].zzID,string(int(PI[zzPlayerID].zzPawn.PlayerReplicationInfo.Score))); BufferLog("stat_player","frags",PI[zzPlayerID].zzID,string(PI[zzPlayerID].zzKills - PI[zzPlayerID].zzSuicides)); BufferLog("stat_player","kills",PI[zzPlayerID].zzID,string(PI[zzPlayerID].zzKills)); BufferLog("stat_player","deaths",PI[zzPlayerID].zzID,string(PI[zzPlayerID].zzDeaths)); BufferLog("stat_player","suicides",PI[zzPlayerID].zzID,string(PI[zzPlayerID].zzSuicides)); BufferLog("stat_player","teamkills",PI[zzPlayerID].zzID,string(PI[zzPlayerID].zzTeamKills)); BufferLog("stat_player","efficiency",PI[zzPlayerID].zzID,string(zzEfficiency)); BufferLog("stat_player","time_on_server",PI[zzPlayerID].zzID,string(Level.TimeSeconds-PI[zzPlayerID].zzJoinTime)); BufferLog("stat_player","ttl",PI[zzPlayerID].zzID,string(zzTTL)); for (i=0;i 0) return false; else { if (!bGameStarted) { zzWarmupTime = Level.TimeSeconds; LogEventString(GetTimeStamp()$Chr(9)$"game"$chr(9)$"realstart"); } bGameStarted = true; return true; } } // ============================================================================= // AddMutator ~ Add mutatorclass to our list // ============================================================================= function AddMutator (Mutator M) { zzMutatorList = zzMutatorList$":::"$M.class; } // ============================================================================= // LogMutatorList ~ Log the list // ============================================================================= function LogMutatorList() { local string zzEntry,zzDesc; local int zzNum; zzEntry = "(none)"; while (zzEntry != "") { if ((InStr(CAPS(zzMutatorList),CAPS(zzEntry)) != -1) && zzDesc != "") { if (InStr(zzDesc,",") != -1) zzDesc = Left(zzDesc,InStr(zzDesc,",")); LogEventString(GetTimeStamp()$chr(9)$"game"$chr(9)$"GoodMutator"$chr(9)$zzDesc); } GetNextIntDesc("Engine.Mutator",zzNum++,zzEntry,zzDesc); } } // ============================================================================= // Defaultproperties // ============================================================================= GTIQa  @ /'#/%i/,_z/h{/h-T'/-Ta/!  @M*(:*-T . UTSDamageMutr *a  . UTSDamageMutr *### ERROR: UTStats cannot run without the UTSAccu package!  -'a -(6 >FD*w** ***n K?5a/! (a ((4.(3( O@Oo ql phw*Q~Voe {UC@a/!UA]mn Z-   iU<A6+i6<UA]mn-6<-6<( WP!@'O! -l-Q -;'-;-;( % u-6C &6- a/!.(6- a/!/-6C 'SS%6- --Q'j{69 <-Q6-  -;' G/ QjSz.j,,{,0 ,9,A ,[,a ,{.p.j# @c>1iXz>Assault Targetz>z> g>  } } |\ || |n }L |f |. |^ um |u }X |_ |] ud |^ |/ |x | |[ |` |a |w u^ wp |M |x |Z | |b |0 |q fW || fS |C |l ut |l uh |A uw |_ |c ^' ^A ^P ^@ p| x` |H ^7 }d |E }8 ^5 ^E ^L ^B ^C ^6 ^H ^U ^Q ^S ^ |s ^J fv f] fq ^ ^O }N |@ _C ^9 f w_ ^! w_ |^ ^G uc ur uG um |J |I |Q qp xR |F xU ^( uu xR | |h xf xj xgZr=g @>J M>+k Y>O DJu QJi ^J{kJO yJ@ EKs QKe ]KO jKh vKS CLB PLu ]LO jLX vL-fBMq hQN uQY ARc MRz ZR[ gRL tRM @Sn LSO XSO eSdqSO SO KTA WTI cTa pTk }T] JUU VUO cU[ oUP |Uk IVxVVO dVO pVO |V\ IW1ZUWU oXr|XT JYd VYe cYy pYz |YK HZ~ TZ] `Z} lZDyZb G[Q S[| `[R m[y y[i E\k R\s ^\| k\E w\V D]Z Q]o ]]xj] x]j E^e Q^o ^^t k^o w^v D_~ P_e ]_j j_F w_| D`YQ`W _`l l`h x`f Eae RaG _aF laI yaV Fbt Rbs ^b` kbCwb@Ec} Sc\ _cO kcowcs Edg RdB _d~ ld{ yd[ EeW ReB _eh le\yeW Gf\Tf{ bfW nfB {fg Gg\Tgf bgv ogi {gj Hhk Uhe aht nhr {hV HiD Tio ai[ mig yin Fjm Sj*`jT sj<@kT RkO8_k6uWlULoX a XnP4ZEFk `>le jH v3BB2P4RDPVN fO sT@VTsjA[]@xIxBPAY Qz ]GIjK sa @cMP4]4[yx9 F]fw CN O[[L4vE;jPZeJLH;KF@8E5:}qwO hRuY G7S7pJBzo |T Hn U2)aY JT WP4OdbsQ!Az bo n'LzY F(bRT t eACifY O!\\txY lkx