SHARE
TWEET

Untitled

a guest Jun 17th, 2019 87 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. @echo off
  2. cls
  3. color 4E
  4. cd %~dp0..\System
  5.  
  6. set gamemode=
  7. set mapname=
  8. :gamemode
  9. cls
  10. echo.
  11. echo.
  12. echo  UT2004 Dedicated Server launcher
  13. echo  ================================
  14. echo.
  15. echo  1) Instagib DM
  16. echo  2) Normal DeathMatch
  17. echo  3) Team DeathMatch
  18. echo  4) Capture The Flag
  19. echo  5) Double Domination
  20. echo  6) Bombing Run
  21. echo  7) Vehicle CTF
  22. echo  8) Mutant
  23. echo  9) Last Man Standing
  24. echo  a) Invasion
  25. echo  b) Assault
  26. echo  c) Onslaught
  27. echo.
  28. echo You can start the Web-admin application when the server is running.
  29. echo.
  30. echo.
  31. set menuchoice=
  32. set /p menuchoice= (Q to quit):
  33.  
  34. set menuchoice=%menuchoice:~0,1%
  35.  
  36. :: -- To lower
  37. SETLOCAL ENABLEDELAYEDEXPANSION
  38. CALL :LoCase menuchoice
  39.  
  40. if '%menuchoice%'=='q' goto quit
  41. if '%menuchoice%'=='1' set gamemode=XGame.xDeathMatch & set mapname=DM-Rankin & set mutators=?mutator=XGame.MutInstaGib & goto StartServer
  42. if '%menuchoice%'=='2' set gamemode=XGame.xDeathMatch & set mapname=DM-Rankin & goto Mutators
  43. if '%menuchoice%'=='3' set gamemode=XGame.xTeamGame & set mapname=DM-Rankin & goto Mutators
  44. if '%menuchoice%'=='4' set gamemode=XGame.xCTFGame & set mapname=CTF-Colossus & goto Mutators
  45. if '%menuchoice%'=='5' set gamemode=XGame.xDoubleDom & set mapname=DOM-Atlantis & goto Mutators
  46. if '%menuchoice%'=='6' set gamemode=XGame.xBombingRun & set mapname=BR-Canyon & goto Mutators
  47. if '%menuchoice%'=='7' set gamemode=XGame.xVehicleCTFGame & set mapname=CTF-Colossus & goto Mutators
  48. if '%menuchoice%'=='8' set gamemode=BonusPack.xMutantGame & set mapname=DM-Rankin & goto Mutators
  49. if '%menuchoice%'=='9' set gamemode=BonusPack.xLastManStandingGame & set mapname=DM-Rankin & goto Mutators
  50. if '%menuchoice%'=='a' set gamemode=SkaarjPack.Invasion & set mapname=DM-Rankin & goto Mutators
  51. if '%menuchoice%'=='b' set gamemode=UT2K4Assault.ASGameInfo & set mapname=AS-Convoy & goto Mutators
  52. if '%menuchoice%'=='c' set gamemode=Onslaught.ONSOnslaughtGame & set mapname=ONS-Torlan & goto Mutators
  53.  
  54. :: -- We NEED a gamemode
  55. if '%gamemode%'=='' goto gamemode
  56. if '%gamemode%'==' ' goto gamemode
  57.  
  58. :Mutators
  59. cls
  60. echo.
  61. echo Select mutators:
  62. echo.
  63. echo a) Bonus Combos
  64. echo b) BigHead
  65. echo c) Lightweight Vehicles (Onslaught)
  66. echo d) Onslaught Weapons (Onslaught)
  67. echo e) Stunt Vehicles (Onslaught)
  68. echo f) Vehicle Arena (Onslaught)
  69. echo g) UT Classic
  70. echo h) Lightning Guns (UTClassic)
  71. echo i) InstaGib
  72. echo j) UTV2004S
  73. echo k) Super Berserk
  74. echo l) BigWheels (Onslaught)
  75. echo m) Game Speed
  76. echo n) LowGrav
  77. echo o) Air Control
  78. echo p) UT2003 Style
  79. echo q) QuadJump
  80. echo r) No Adrenaline
  81. echo s) Sniper Rifles (UTClassic)
  82. echo t) Regeneration
  83. echo u) Slow Motion Corpses
  84. echo v) Species Statistics
  85. echo w) UDamage Reward
  86. echo x) Vampire
  87. echo y) Zoom InstaGib
  88. echo z) Arena
  89. echo 0) No SuperWeapons
  90. echo.
  91. echo.
  92. echo You can select multiple mutators!
  93. set menuchoice=
  94. set /p menuchoice= Mutators:
  95.  
  96. if 'menuchoice'=='' goto start_server
  97. if 'menuchoice'==' ' goto start_server
  98.  
  99. rem Initialize mutator variable
  100. rem ---------------------------
  101. set mutators=?mutator=
  102.  
  103. :loop
  104.  
  105. rem -- Get first character
  106. set mut_choice=%menuchoice:~0,1%
  107.  
  108. rem -- Replace spaces
  109. set mut_choice=%mut_choice: =%
  110. set mutators=%mutators: =%
  111.  
  112. if '%mut_choice%'=='a' set mutators=%mutators%BonusPack.MutCrateCombo
  113. if '%mut_choice%'=='b' set mutators=%mutators%UnrealGame.MutBigHead
  114. if '%mut_choice%'=='c' set mutators=%mutators%Onslaught.MutLightweightVehicles
  115. if '%mut_choice%'=='d' set mutators=%mutators%Onslaught.MutOnslaughtWeapons
  116. if '%mut_choice%'=='e' set mutators=%mutators%Onslaught.MutWheeledVehicleStunts
  117. if '%mut_choice%'=='f' set mutators=%mutators%OnslaughtFull.MutVehicleArena
  118. if '%mut_choice%'=='g' set mutators=%mutators%UTClassic.MutUTClassic
  119. if '%mut_choice%'=='h' set mutators=%mutators%UTClassic.MutUseLightning
  120. if '%mut_choice%'=='i' set mutators=%mutators%UTClassic.MutInstaGib
  121. if '%mut_choice%'=='j' set mutators=%mutators%UTV2004s.utvMutator
  122. if '%mut_choice%'=='k' set mutators=%mutators%UnrealGame.MutBerserk
  123. if '%mut_choice%'=='l' set mutators=%mutators%Onslaught.MutBigWheels
  124. if '%mut_choice%'=='m' set mutators=%mutators%UnrealGame.MutGameSpeed
  125. if '%mut_choice%'=='n' set mutators=%mutators%UnrealGame.MutLowGrav
  126. if '%mut_choice%'=='o' set mutators=%mutators%UnrealGame.MutMovementModifier
  127. if '%mut_choice%'=='p' set mutators=%mutators%XGame.MutFastWeapSwitch
  128. if '%mut_choice%'=='q' set mutators=%mutators%XGame.MutQuadJump
  129. if '%mut_choice%'=='r' set mutators=%mutators%XGame.MutNoAdrenaline
  130. if '%mut_choice%'=='s' set mutators=%mutators%XGame.MutUseSniper
  131. if '%mut_choice%'=='t' set mutators=%mutators%XGame.MutRegen
  132. if '%mut_choice%'=='u' set mutators=%mutators%XGame.MutSlomoDeath
  133. if '%mut_choice%'=='v' set mutators=%mutators%XGame.MutSpeciesStats
  134. if '%mut_choice%'=='w' set mutators=%mutators%XGame.MutUDamageReward
  135. if '%mut_choice%'=='x' set mutators=%mutators%XGame.MutVampire
  136. if '%mut_choice%'=='y' set mutators=%mutators%XGame.MutZoomInstagib
  137. if '%mut_choice%'=='z' set mutators=%mutators%XWeapons.MutArena
  138. if '%mut_choice%'=='0' set mutators=%mutators%XWeapons.MutNoSuperWeapon
  139.  
  140. rem -- Extract first character to process the next
  141. set menuchoice=%menuchoice:~1%
  142.  
  143. rem -- Is there something left?
  144. if not '%menuchoice%'=='' set mutators=%mutators%, & goto loop
  145.  
  146.  
  147. :StartServer
  148. rem -- Remove spaces
  149. set gamemode=%gamemode: =%
  150. set mapname=%mapname: =%
  151. set mutators=%mutators: =%
  152. set port=7777
  153. cls
  154. echo.
  155. echo.
  156. echo Login details for the web interface are:
  157. echo.
  158. echo Username: admin
  159. echo Password: lan
  160. echo.
  161. echo The web interface will be started simultaniously. You might need
  162. echo to hit refresh in your browser when the server is fully started.
  163. echo.
  164. echo.
  165. set /p port= Enter port or use default (7777) by pressing ENTER:
  166.  
  167. start http://localhost/ServerAdmin/
  168. echo.
  169. echo Port    : [%port%]
  170. echo Gamemode: [%gamemode%]
  171. echo Mutators: [%mutators%]
  172. echo Map     : [%mapname%]
  173. echo.
  174. echo Starting server...
  175. echo.
  176. ucc server %mapname%?game=%gamemode%%mutators% port=%port% ini=UT2004.ini ServerName=Gerbens log=server.log -lanplay
  177. echo.
  178. echo Server shut down!
  179. pause>nul
  180. goto :gamemode
  181.  
  182. :LoCase
  183. :: Subroutine to convert a variable VALUE to all lower case.
  184. :: The argument for this subroutine is the variable NAME.
  185. SET %~1=!%1:A=a!
  186. SET %~1=!%1:B=b!
  187. SET %~1=!%1:C=c!
  188. SET %~1=!%1:D=d!
  189. SET %~1=!%1:E=e!
  190. SET %~1=!%1:F=f!
  191. SET %~1=!%1:G=g!
  192. SET %~1=!%1:H=h!
  193. SET %~1=!%1:I=i!
  194. SET %~1=!%1:J=j!
  195. SET %~1=!%1:K=k!
  196. SET %~1=!%1:L=l!
  197. SET %~1=!%1:M=m!
  198. SET %~1=!%1:N=n!
  199. SET %~1=!%1:O=o!
  200. SET %~1=!%1:P=p!
  201. SET %~1=!%1:Q=q!
  202. SET %~1=!%1:R=r!
  203. SET %~1=!%1:S=s!
  204. SET %~1=!%1:T=t!
  205. SET %~1=!%1:U=u!
  206. SET %~1=!%1:V=v!
  207. SET %~1=!%1:W=w!
  208. SET %~1=!%1:X=x!
  209. SET %~1=!%1:Y=y!
  210. SET %~1=!%1:Z=z!
  211. GOTO:EOF
  212.  
  213. :UpCase
  214. :: Subroutine to convert a variable VALUE to all upper case.
  215. :: The argument for this subroutine is the variable NAME.
  216. SET %~1=!%1:a=A!
  217. SET %~1=!%1:b=B!
  218. SET %~1=!%1:c=C!
  219. SET %~1=!%1:d=D!
  220. SET %~1=!%1:e=E!
  221. SET %~1=!%1:f=F!
  222. SET %~1=!%1:g=G!
  223. SET %~1=!%1:h=H!
  224. SET %~1=!%1:i=I!
  225. SET %~1=!%1:j=J!
  226. SET %~1=!%1:k=K!
  227. SET %~1=!%1:l=L!
  228. SET %~1=!%1:m=M!
  229. SET %~1=!%1:n=N!
  230. SET %~1=!%1:o=O!
  231. SET %~1=!%1:p=P!
  232. SET %~1=!%1:q=Q!
  233. SET %~1=!%1:r=R!
  234. SET %~1=!%1:s=S!
  235. SET %~1=!%1:t=T!
  236. SET %~1=!%1:u=U!
  237. SET %~1=!%1:v=V!
  238. SET %~1=!%1:w=W!
  239. SET %~1=!%1:x=X!
  240. SET %~1=!%1:y=Y!
  241. SET %~1=!%1:z=Z!
  242. GOTO:EOF
  243.  
  244. :quit
  245. set menuchoice=
  246. set mut_choice=
  247. set mutators=
  248. set mapname=
  249. set gamemode=
  250. set port=
  251.  
  252. color 08
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
Not a member of Pastebin yet?
Sign Up, it unlocks many cool features!
 
Top