Onetruepurple
#1055 posted by
Barnak on 2014/08/24 16:17:05
Map69 is the "Castle Of The Bad Die".
And I'm still asking for a map which randomize the map loading from a maps list. This is a Must Have Feature.
Onetruepurple And Nitin
#1056 posted by
Barnak on 2014/08/24 16:24:24
#1057 posted by
Spirit on 2014/08/24 16:51:19
It is so scriptable!
1) Copy a random map to randommap.bsp.
2) Use whatever MacOS offers to monitor file access to see when the engine accesses the map (might need to look for "Open"). Apparently you would want "fswatch".
3) "map randommap"
4) Sleep for some moments
5) Copy another random map to randommap.bsp so if you do "map randommap" again, there already is a new one there.
In Linux
#1058 posted by
Spirit on 2014/08/24 17:01:47
while true; do inotifywait --event open /home/me/games/quake/id1/maps/randommap.bsp && sleep 1 && file="$(ls -1 /home/me/games/quake/id1/maps/*.bsp | sort --random-sort | head -1)" && echo $file && ln --symbolic --force "${file}" /home/me/games/quake/id1/maps/randommap.bsp; done
This uses a symbolic link instead of copying the file every time.
Map Randomizer In Qc For Barnak
#1060 posted by damage_inc on 2014/08/24 17:11:57
Open up your id1/maps folder...
Right click in empty space and choose on of the following: "Arrange icon's by" - size, date, alphabetically etc etc...
Close you eyes, NO peeking, this is important for it to work...
Raise your hand, forefinger pointed out, move it spiraling in towards the monitor...
Until it touches...
BAM, there's your random map generator ;)
You can restart at step one and choose a different option to keep it random too...
All done with "qc", short for quickly conceived!
Realize, eventually all dogs let go of the bone sooner or later.
Meant Random Map Selector
#1061 posted by damage_inc on 2014/08/24 17:14:43
#1062 posted by
Spirit on 2014/08/24 17:18:02
He already specified several times that it needs to work without leaving engine. And playing for my solution for a while I have to say, yeah, it absolutely does.
Spirit, Correct Me If I'm Wrong But...
#1063 posted by damage_inc on 2014/08/24 17:30:19
Both of our methods are initiated before the engine is even started right? None of what you suggested works "in engine"?
#1064 posted by
Spirit on 2014/08/24 17:47:00
With "in engine" I meant that you can get a new map without leaving the engine/game. My script needs to be started before the engine but then it runs as long as you don't kill it.
Gotcha ;)
#1065 posted by damage_inc on 2014/08/24 19:08:00
Can I run this in a terminal, and end by closing the terminal?
#1066 posted by
Spirit on 2014/08/24 19:36:21
exactly that, ctrl-c to stop. making it into a systemd service that launches on login would be easy too. I think the sleep is unnecessary (since the file was already opened and thus the link can be changed) but I am not entirely sure.
Had To Install The "inotify-tools" But Worked Like A Charm Spirit :)
#1067 posted by damage_inc on 2014/08/24 20:32:11
You have to start a new level before the next "new" randommap.bsp symbolic link will work. Dropping to the console and "disconnect"'ing doesn't trigger it.
COOL!
#1068 posted by
Spirit on 2014/08/24 21:10:10
bind m "map randommap" worked fine for me in a some days old QS.
All Of The Above Made Me Slightly More Happy
#1069 posted by
ijed on 2014/08/24 21:27:29
#1070 posted by
Spirit on 2014/08/24 22:15:33
Ah, of course, it needs an initial map. Sorry!
I made it into a script:
https://www.quaddicted.com/forum/viewtopic.php?pid=1169#p1169
It's awesome to go through sm* maps. sm161 had some fantastic ones.