View Single Post
Old 26th May 2008, 08:56 PM   #12
lightfoot
Member
 
lightfoot's Avatar
 
Registered: Oct 2005
Location: *teleports up front*
Posts: 576
I have not mapped much lately, but I did another version of the launcher.

launcher.bat:
Code:
@echo off

: IMPORTANT This launcher will only work when it is 
: in your UT2004\AlienSwarm\maps\ folder.
: It further assumes that there is a folder called
: 'AlienSwarm\Maps\MenuMaps',
: which contains 5 (yes, the 'number' variable)
: actual menu maps, named '1', '2', '3', '4' and '5'.


: resize our window. title will come as soon as we know it.
mode con: cols=97 lines=38

: the following seems to be needed for randomness
setLocal EnableDelayedExpansion

: we have 'number' menu maps to choose from
: (TODO: the script should rather make a head count of the files
:             in the MenuMaps folder, instead of primitively setting it here!)
set number=5

: so randomly find a target between 1 and number
:
set /a target=!random!%%number+1

: get the respective map description from a 'subroutine'. brr, clumsy.
:
if %target%==1 goto Original 
if %target%==2 goto Sigma 
if %target%==3 goto Telic 
if %target%==4 goto Conrad 
if %target%==5 goto APC

:hell

:rename title bar
title Todays menu flavour will be: %descrip%   - Hit any key to proceed to the game. -

: display the ASCII table, now feat. the targetted Map's description (in the title bar!)

echo.
echo.
echo.
echo.
echo.
echo  NNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNN
echo  NNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNN
echo  NNNNNNNNNNNNNNNNNNNN`     4NNNNN)     NNNNNNN)     N)           NF      'NNNNN) (NNNNNNNNNNNNNN
echo  NNNNNNNNNNNNNNNNNNN)       4NNNN)     NNNNNNN)     N)    (NNNNNNN)       'NNNN) (NNNNNNNNNNNNNN
echo  NNNNNNNNNNNNNNNNNN) ,N     'NNNN)     NNNNNNN)     N)    (NNNNNNN)  L     'NNN) (NNNNNNNNNNNNNN
echo  NNNNNNNNNNNNNNNNNF  JNL     'NNN)     NNNNNNN)     N)          'N)  NL     'NN) (NNNNNNNNNNNNNN
echo  NNNNNNNNNNNNNNNNF  '"""`     NNN)     NNNNNNN)     N)    ,______N)  NN)     4N) (NNNNNNNNNNNNNN
echo  NNNNNNNNNNNNNNNN`            'NN)     NNNNNNN)     N)    (NNNNNNN)  NNN.     4) (NNNNNNNNNNNNNN
echo  NNNNNNNNNNNNNNNF ,NNNNNNL     4N)     """"""N)     N)    '""""""4)  NNNN.     ` (NNNNNNNNNNNNNN
echo  NNNNNNNNNNNNNNF_,NNNNNNNN)_____N)___________N)_____N)___________(L__NNNNN.______(NNNNNNNNNNNNNN
echo  NNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNN
echo  NNNNF""""""""""NF""""4NNNF"""""NNNN""4NNNNN""""""NNNNNNF"""""""""""""NNNN""""""4NNNNN""""""4NNN
echo  NNN`           N)    'NNN)     4NNF  JNNNN`      'NNNNN)              NNN       4NNN)      (NNN
echo  NNN    4NNNNNNNNN     (NF       NN`  NNNN)  .     (NNNN)     (NNN     NNN       'NNF       (NNN
echo  NNN            4N.    'N)       4F  (NNNF  JN      4NNN)     '"""     NNN  (.    (N  ,)    (NNN
echo  NNN             N)     N  ,)    `'  NNNN` (NNL     'NNN)             ,NNN  (L     `  J)    (NNN
echo  NNN_            NN        JN       ,NNN`            'NN)     (L     "NNNN  (N.      (N)    (NNN
echo  NNNNNNNNNN)     NN)      (NN)      JNN)  ______      4N)     (NL     4NNN  (NN      NN)    (NNN
echo  NNN`           JNNN.     JNNL     ,NN)  JNNNNNNL      N)     (NNL     4NN  (NNL    JNN)    (NNN
echo  NNN___________JNNNNL_____NNNN_____JNN__JNNNNNNNN______NL_____JNNNL____JNN__JNNN___JNNNL____JNNN
echo  NNNNNNNNNNNNFNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNF"NNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNN
echo  NNN`(F4) NN`_ '   '4NNNN"4N"NF4N"'"NL   '`4 4"  "N` '"NNNN    "N"N"NF  NNNN'N"N") 4NFNNN)   "NN
echo  NNN.') ) () NL_N ,JNNNN) (F `)() _ 4N) JN"( ( ___N.,  NNNN)'N  ) ) F JF4NNN N N L (F 'N N) JNNN
echo  NNNL ) N (N. 'NN (NNNNF .(`  `( (N. N) NN ' ( `"(N)' ,NNNN`   () ) ) ` _NNN " ) N ()  N N`(NNNN
echo  N) N ` N ("N` (F NNNNN _ ( ,  J NN) N`.NN , ( """4.  'NNNN. N  ` ) L " NNNN _ ) N ( , ",N NNNNN
echo  NN.  ) `,L   _N) NNNNLJNLJ_NN N  " _N JNN.J J.__JNL NL"4NN) " ,)  JNL,(NNNN J.L `,N_NL JN NNNNN
echo  NNNNNNLJNNNNNNNLJNNNNNNNNNNNNNNNNNNNN_NNNNNLNNNNNNNJNNNNNNL__NNNLJNNNNNNNNNNNNNLJNNNNNNNNJNNNNN
echo  NNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNN
echo.
echo.
echo.
echo.


: wait for keypress, before actually doing stuff.
pause >nul

: now do stuff.  ONE: delete old menu map.
del alienswarmstartup.ut2

: do stuff          TWO: copy target into this directory.
copy menumaps\%target%.ut2

: do stuff          THREE: rename target into what the game expects.
ren %target%.ut2 AlienSwarmStartUp.ut2

: clear variables
set number=
set target=
set descrip=

: ...and now, gear up! For "Just another bug hunt"
cd..
AlienSwarm.exe
: (this would be the place to set ?mutator=... or other options)

: also, quit this ingenious piece of code. have fun, and watch your reload!
exit


: the following are subroutines for setting the map description
:
: in case there are more menu maps to include: they could be added
: here, provided that you also add another if-condition up there.
: also, raise 'number' then, of course. 


:Original
set descrip=The original menu map.    
goto hell
:Sigma
set descrip=The Sigma campaign lobby. 
goto hell
:Telic
set descrip=The Telic campaign lobby. 
goto hell
:Conrad
set descrip=The mothership USS Conrad.
goto hell
:APC
set descrip=The APC at a close view.  
goto hell
Does the same, just looks different. A screenshot is here:

Someone up for making a mac or linux version?

Last edited by lightfoot; 27th May 2008 at 01:19 PM.
lightfoot is offline   Reply With Quote