Overview | Package | Class | Source | Class tree | Glossary | UnrealScript Documentation |
previous class next class | frames no frames |
00001 00002 00003 00004 00005 00006 00007 00008 00009 00010 00011 00012 00013 00014 00015 00016 00017 00018 00019 00020 00021 00022 00023 00024 00025 00026 00027 00028 00029 00030 00031 00032 00033 00034 00035 00036 00037 00038 00039 00040 00041 00042 00043 00044 00045 00046 00047 00048 00049 00050 00051 00052 00053 00054 00055 00056 00057 00058 00059 00060 00061 00062 00063 00064 00065 00066 00067 00068 00069 00070 00071 00072 00073 00074 00075 00076 00077 00078 00079 00080 00081 00082 00083 00084 00085 00086 00087 00088 00089 00090 00091 00092 00093 00094 00095 00096 00097 00098 00099 00100 00101 00102 00103 00104 00105 00106 00107 00108 00109 00110 00111 00112 00113 00114 00115 00116 00117 00118 00119 00120 00121 00122 00123 00124 00125 00126 00127 00128 00129 00130 00131 00132 00133 00134 00135 00136 00137 00138 00139 00140 00141 00142 00143 00144 00145 00146 00147 00148 00149 00150 00151 00152 00153 00154 00155 00156 00157 00158 00159 00160 00161 00162 00163 00164 00165 00166 00167 00168 00169 00170 00171 00172 00173 00174 00175 00176 00177 00178 00179 00180 00181 00182 00183 00184 |
class HudBDoubleDomination extends HudBTeamDeathMatch; enum EPointState { PS_Neutral, PS_HeldFriendly, PS_HeldEnemy, PS_Disabled, }; struct FPointWidget { var EPointState PointState; var SpriteWidget Widgets[4]; }; var() SpriteWidget SymbolGB[2]; var() FPointWidget Points[2]; var transient xDomPoint DP1; var transient xDomPoint DP2; simulated function PostBeginPlay() { Super.PostBeginPlay(); SetTimer(1.0, True); } // Alpha Pass ================================================================================== simulated function ShowTeamScorePassA(Canvas C) { Super.ShowTeamScorePassA(C); DrawSpriteWidget (C, SymbolGB[0]); DrawSpriteWidget (C, SymbolGB[1]); LTeamHud[0].OffsetX=-100; LTeamHud[1].OffsetX=-100; LTeamHud[2].OffsetX=-100; RTeamHud[0].OffsetX=100; RTeamHud[1].OffsetX=100; RTeamHud[2].OffsetX=100; TeamSymbols[0].TextureScale = 0.09; TeamSymbols[1].TextureScale = 0.09; TeamSymbols[0].OffsetX = -480; TeamSymbols[1].OffsetX = 480; TeamSymbols[0].OffsetY = 90; TeamSymbols[1].OffsetY = 90; Points[0].Widgets[Points[0].PointState].PosY = 0.045*HUDScale; Points[1].Widgets[Points[1].PointState].PosY = 0.045*HUDScale; DrawSpriteWidget (C, Points[0].Widgets[Points[0].PointState]); DrawSpriteWidget (C, Points[1].Widgets[Points[1].PointState]); if ( DP1 != None ) { C.DrawColor = GoldColor; Draw2DLocationDot(C, DP1.Location,0.5 - 0.04*HUDScale, 0.0365*HUDScale, 0.0305*HUDScale, 0.0405*HUDScale); } if ( DP2 != None ) { C.DrawColor = GoldColor; Draw2DLocationDot(C, DP2.Location,0.5 + 0.026*HUDScale, 0.0365*HUDScale, 0.0305*HUDScale, 0.0405*HUDScale); } } simulated function ShowTeamScorePassC(Canvas C) { ScoreTeam[0].OffsetX = -270; ScoreTeam[0].OffsetY = 75; ScoreTeam[1].OffsetY = 75; Super.ShowTeamScorePassC(C); } simulated function TeamScoreOffset() { ScoreTeam[1].OffsetX = 180; if ( ScoreTeam[1].Value < 0 ) ScoreTeam[1].OffsetX += 90; if( abs(ScoreTeam[1].Value) > 9 ) ScoreTeam[1].OffsetX += 90; } simulated function UpdateTeamHud() { local NavigationPoint N; if (DP1 == None || DP2 == None) { for (N = Level.NavigationPointList; N != None; N = N.NextNavigationPoint) { if (!N.IsA('xDomPoint')) continue; if (N.IsA('xDomPointA') && DP1 == None) DP1 = xDomPoint(N); else DP2 = xDomPoint(N); } } // Point A state if (!DP1.bControllable) Points[0].PointState = PS_Disabled; else if (DP1.ControllingTeam == None) Points[0].PointState = PS_Neutral; else if ( PlayerOwner.PlayerReplicationInfo.Team == None ) { if ( DP1.ControllingTeam.TeamIndex == 0 ) Points[0].PointState = PS_HeldFriendly; else Points[0].PointState = PS_HeldEnemy; } else if (DP1.ControllingTeam == PawnOwnerPRI.Team) Points[0].PointState = PS_HeldFriendly; else Points[0].PointState = PS_HeldEnemy; // Point B state if (!DP2.bControllable) Points[1].PointState = PS_Disabled; else if (DP2.ControllingTeam == None) Points[1].PointState = PS_Neutral; else if ( PlayerOwner.PlayerReplicationInfo.Team == None ) { if ( DP2.ControllingTeam.TeamIndex == 0 ) Points[1].PointState = PS_HeldFriendly; else Points[1].PointState = PS_HeldEnemy; } else if (DP2.ControllingTeam == PawnOwnerPRI.Team) Points[1].PointState = PS_HeldFriendly; else Points[1].PointState = PS_HeldEnemy; Super.UpdateTeamHUD(); } function Timer() { local NavigationPoint N; Super.Timer(); if ((PlayerOwner == None) || (PawnOwner == None) || (PawnOwnerPRI == None)) return; if (DP1 == None || DP2 == None) { for (N = Level.NavigationPointList; N != None; N = N.NextNavigationPoint) { if (!N.IsA ('xDomPoint')) continue; if (N.IsA('xDomPointA')) DP1 = xDomPoint(N); else DP2 = xDomPoint(N); } } if (DP1.ControllingTeam == DP2.ControllingTeam) { if (DP1.ControllingTeam != None) { if (PawnOwnerPRI.Team.TeamIndex == DP1.ControllingTeam.TeamIndex) PlayerOwner.ReceiveLocalizedMessage (class'xDomMessage', 0); else PlayerOwner.ReceiveLocalizedMessage (class'xDomMessage', 1); } } } defaultproperties { SymbolGB(0)=(WidgetTexture=Texture'InterfaceContent.HUD.SkinA',RenderStyle=STY_Alpha,TextureCoords=(X1=142,Y1=880,Y2=1023),TextureScale=0.300000,DrawPivot=DP_UpperRight,PosX=0.500000,ScaleMode=SM_Right,Scale=1.000000,Tints[0]=(B=255,G=255,R=255,A=255),Tints[1]=(B=255,G=255,R=255,A=255)) SymbolGB(1)=(WidgetTexture=Texture'InterfaceContent.HUD.SkinA',RenderStyle=STY_Alpha,TextureCoords=(X1=142,Y1=880,Y2=1023),TextureScale=0.300000,PosX=0.500000,ScaleMode=SM_Right,Scale=1.000000,Tints[0]=(B=255,G=255,R=255,A=255),Tints[1]=(B=255,G=255,R=255,A=255)) Points(0)=(Widgets[0]=(WidgetTexture=Texture'InterfaceContent.HUD.SkinA',RenderStyle=STY_Alpha,TextureCoords=(X1=334,Y1=512,X2=391,Y2=567),TextureScale=0.600000,DrawPivot=DP_MiddleMiddle,PosX=0.500000,PosY=0.045000,OffsetX=-34,Scale=1.000000,Tints[0]=(B=195,G=195,R=195,A=255),Tints[1]=(B=195,G=195,R=195,A=255)),Widgets[1]=(WidgetTexture=Texture'InterfaceContent.HUD.SkinA',RenderStyle=STY_Alpha,TextureCoords=(X1=334,Y1=512,X2=391,Y2=567),TextureScale=0.600000,DrawPivot=DP_MiddleMiddle,PosX=0.500000,PosY=0.045000,OffsetX=-34,Scale=1.000000,Tints[0]=(B=60,G=60,R=255,A=255),Tints[1]=(B=255,G=205,R=100,A=255)),Widgets[2]=(WidgetTexture=Texture'InterfaceContent.HUD.SkinA',RenderStyle=STY_Alpha,TextureCoords=(X1=334,Y1=512,X2=391,Y2=567),TextureScale=0.600000,DrawPivot=DP_MiddleMiddle,PosX=0.500000,PosY=0.045000,OffsetX=-34,Scale=1.000000,Tints[0]=(B=255,G=205,R=100,A=255),Tints[1]=(B=60,G=60,R=255,A=255)),Widgets[3]=(WidgetTexture=Texture'InterfaceContent.HUD.SkinA',RenderStyle=STY_Alpha,TextureCoords=(X1=334,Y1=512,X2=391,Y2=567),TextureScale=0.600000,DrawPivot=DP_MiddleMiddle,PosX=0.500000,PosY=0.045000,OffsetX=-34,Scale=1.000000,Tints[0]=(B=195,G=195,R=195,A=55),Tints[1]=(B=255,G=255,R=255))) Points(1)=(Widgets[0]=(WidgetTexture=Texture'InterfaceContent.HUD.SkinA',RenderStyle=STY_Alpha,TextureCoords=(X1=392,Y1=512,X2=449,Y2=567),TextureScale=0.600000,DrawPivot=DP_MiddleMiddle,PosX=0.500000,PosY=0.045000,OffsetX=34,Scale=1.000000,Tints[0]=(B=195,G=195,R=195,A=255),Tints[1]=(B=195,G=195,R=195,A=255)),Widgets[1]=(WidgetTexture=Texture'InterfaceContent.HUD.SkinA',RenderStyle=STY_Alpha,TextureCoords=(X1=392,Y1=512,X2=449,Y2=567),TextureScale=0.600000,DrawPivot=DP_MiddleMiddle,PosX=0.500000,PosY=0.045000,OffsetX=34,Scale=1.000000,Tints[0]=(B=60,G=60,R=255,A=255),Tints[1]=(B=255,G=205,R=100,A=255)),Widgets[2]=(WidgetTexture=Texture'InterfaceContent.HUD.SkinA',RenderStyle=STY_Alpha,TextureCoords=(X1=392,Y1=512,X2=449,Y2=567),TextureScale=0.600000,DrawPivot=DP_MiddleMiddle,PosX=0.500000,PosY=0.045000,OffsetX=34,Scale=1.000000,Tints[0]=(B=255,G=205,R=100,A=255),Tints[1]=(B=60,G=60,R=255,A=255)),Widgets[3]=(WidgetTexture=Texture'InterfaceContent.HUD.SkinA',RenderStyle=STY_Alpha,TextureCoords=(X1=392,Y1=512,X2=449,Y2=567),TextureScale=0.600000,DrawPivot=DP_MiddleMiddle,PosX=0.500000,PosY=0.045000,OffsetX=34,Scale=1.000000,Tints[0]=(B=195,G=195,R=195,A=55),Tints[1]=(B=255,G=255,R=255))) } |
Overview | Package | Class | Source | Class tree | Glossary | UnrealScript Documentation |
previous class next class | frames no frames |