I was looking at the Murk++ codebase and noticed a startup script that worked with windows. I'm thinking about using it just to make development a bit more convenient but I'm not sure how to change things.
setlocal enableextensions
rem Set the port number. set port=4000 if not "%1"=="" set port=%1 if exist shutdown.txt erase shutdown.txt if exist hotboot.$$$ erase hotboot.$$$
:loop set /a index=1000 :loop2 set logfile=%index%.log if not exist %logfile% goto start set /a index = %index% + 1 goto loop2
:start rem Record starting time > %logfile% echo rem %DATE% %TIME%
rem Run mud. echo Starting RaM Fire on port %port% using log %logfile% >> %logfile% ram.exe %port% 2>&1
if not exist hotboot.$$$ goto chkshut erase hotboot.$$$ goto done
:chkshut if not exist shutdown.txt goto sleep erase shutdown.txt goto done
:sleep ping 1.1.1.1 -n 15 -w 1000 >NUL goto loop2
:done endlocal
I want to change the file locations. At the moment it checks the area file for shutdown.txt, I'd rather it ..\system\shutdown.txt but I tried that and it doesn't seem to work.
Also, what language is this?
25 Nov, 2009, jurdendurden wrote in the 2nd comment:
Votes: 0
This is oldschool batch file programming. I wanna say that it's edlin or something to that effect. You might just google .bat files. As far as changing where to look for shutdown.txt, it appears to be assuming that shutdown.txt is in the same folder as the script. If it's anything like Rom 2.4, the startup script is in the area folder, so you might just try moving the startup script to a different folder and see what results you get.
I want to change the file locations. At the moment it checks the area file for shutdown.txt, I'd rather it ..\system\shutdown.txt but I tried that and it doesn't seem to work.
The batch file checks the current directory for shutdown.txt Both the code and script are configured to run from the root directory. If you wish to change that then you need to change the location of files in config.hpp The location of the hotboot files in commands.cpp And the makefile.
Quote
Also, what language is this?
It's the language of the Windows cmd.exe shell, usually dubbed Batch.
I want to change the file locations. At the moment it checks the area file for shutdown.txt, I'd rather it ..\system\shutdown.txt but I tried that and it doesn't seem to work.
Also, what language is this?