Core.Object | +--Engine.Actor | +--Engine.Info | +--SarkBall.SarkBallManager
vkickconsole
string
Votekicktext1,Hudtext
int
Vtimercount
Bool
bAllowKick,bAdvancedThrowing
bAllowStatue
bBalanceTeamsWithBots
bVoteinprogress
Float
fGameJumpZ
Int
iDesiredPlayerCount,iDesiredTeamCount,iDeadBallStartCount,iStartGameStartCount,iStartRoundStartCount
iMaxGroundSpeed,iPlayerWithBallSpeed
sRedTeamName,sGreenTeamName,sSarkBallType,sRefPassword
sStartWeapon0,sStartWeapon1,sStartWeapon2,sStartWeapon3,sStartWeapon4,sStartWeapon5,sStartActiveWeapon,sStartShield
void
Spawned()
simulated
createroot()
//creates and kicks of the Root window, still not sure its neccesary
readyplayer(PlayerPawn player)
//Telling the server that the player should be made ready to play
replicatedata(bool bVoteinprogressI, String Votekicktext1I, string hudtextI, int VtimercountI)
//called by the mainmutator to make sure that the data is up to date //And can be replicated to the client
00001 //----------------------------------------------------------- 00002 // 00003 //----------------------------------------------------------- 00004 class SarkBallManager expands Info config(SarkBall); 00005 00006 Var windowconsole vkickconsole ; 00007 00008 00009 //Vars that should be replicated 00010 Var Bool bVoteinprogress; 00011 Var string Votekicktext1,Hudtext; 00012 Var int Vtimercount; 00013 00014 Var Globalconfig string sStartWeapon0,sStartWeapon1,sStartWeapon2,sStartWeapon3,sStartWeapon4,sStartWeapon5,sStartActiveWeapon,sStartShield; 00015 Var GlobalConfig Bool bAllowStatue; 00016 Var GlobalConfig Bool bAllowKick,bAdvancedThrowing; 00017 Var GlobalConfig Bool bBalanceTeamsWithBots; 00018 var GlobalConfig Float fGameJumpZ; 00019 Var GlobalConfig Int iDesiredPlayerCount,iDesiredTeamCount,iDeadBallStartCount,iStartGameStartCount,iStartRoundStartCount; 00020 Var GlobalConfig int iMaxGroundSpeed,iPlayerWithBallSpeed; 00021 Var Globalconfig string sRedTeamName,sGreenTeamName,sSarkBallType,sRefPassword; 00022 00023 Replication 00024 { 00025 //functions the server calls on the client 00026 reliable if( Role==ROLE_Authority ) 00027 createwindows; 00028 //variables the server replicates on the client 00029 reliable if( Role==ROLE_Authority ) 00030 fGameJumpZ,bBalanceTeamsWithBots,iDesiredPlayerCount,iDesiredTeamCount, 00031 iDeadBallStartCount,iStartGameStartCount,iStartRoundStartCount, 00032 sStartWeapon0,sStartWeapon1,sStartWeapon2,sStartWeapon3,sRefPassword, 00033 sStartWeapon4,sStartWeapon5,sStartActiveWeapon,sStartShield, 00034 sRedTeamName,sGreenTeamName,bAdvancedThrowing,sSarkBallType; 00035 //Functions the client calls on the server 00036 //reliable if( Role<ROLE_Authority ) 00037 //playervoted,VoteEffect,readyplayer; 00038 } 00039 00040 00041 function Spawned () 00042 { 00043 //Sets a pointer for the mainmutator 00044 00045 } 00046 00047 //creates and kicks of the Root window, still not sure its neccesary 00048 simulated Function createroot() 00049 { 00050 VkickConsole = WindowConsole(playerpawn(owner).Player.Console); 00051 if (VkickConsole.Root == None) 00052 { 00053 VkickConsole.Rootwindow = "RARCV1.votekickMenuRootWindow"; 00054 VkickConsole.CreateRootWindow(None); 00055 } 00056 VkickConsole.bQuickKeyEnable = true; 00057 VkickConsole.LaunchUWindow(); 00058 } 00059 00060 Simulated Function CreateWindows (class<uwindowwindow> Menuc) 00061 { 00062 local uwindowwindow menushow; 00063 00064 If (playerpawn(owner)!=none) 00065 { 00066 Createroot(); 00067 menushow = UWindowFramedWindow(VkickConsole.root.CreateWindow(menuc,100, 20, 100, 100)); 00068 menushow.showwindow(); 00069 } 00070 } 00071 00072 00073 00074 00075 //called by the mainmutator to make sure that the data is up to date 00076 //And can be replicated to the client 00077 Function replicatedata (bool bVoteinprogressI, String Votekicktext1I, string hudtextI,int VtimercountI) 00078 { 00079 Votekicktext1=Votekicktext1I; 00080 bVoteinprogress=bVoteinprogressI; 00081 Votekicktext1=Votekicktext1I; 00082 Hudtext=hudtextI; 00083 Vtimercount=VtimercountI; 00084 00085 } 00086 00087 //Telling the server that the player should be made ready to play 00088 Function readyplayer (playerpawn player) 00089 { 00090 //votekickmutator.readyplayer(player) ; 00091 player.gotostate('playerwalking'); 00092 player.style=player.default.style; ; 00093 player.ScaleGlow=player.default.ScaleGlow; 00094 } 00095 00096 defaultproperties 00097 { 00098 sStartWeapon0="SarkBall.SarkBallHandAxe" 00099 sStartWeapon1="RuneI.GoblinAxe" 00100 sStartWeapon2="RuneI.DwarfWorkSword" 00101 sStartWeapon3="RuneI.DwarfWorkHammer" 00102 sStartActiveWeapon="SarkBall.SarkBallBroadSword" 00103 sStartShield="SarkBall.SarkBallShield" 00104 bAdvancedThrowing=True 00105 bBalanceTeamsWithBots=True 00106 fGameJumpZ=500.00 00107 iDesiredPlayerCount=6 00108 iDesiredTeamCount=1 00109 iDeadBallStartCount=20 00110 iStartGameStartCount=5 00111 iStartRoundStartCount=3 00112 iMaxGroundSpeed=350 00113 iPlayerWithBallSpeed=300 00114 sRedTeamName="Reddish Rogues" 00115 sGreenTeamName="Verde Vandels" 00116 sSarkBallType="RuneLogo" 00117 sRefPassword="1234" 00118 }