Randomized maps, even foor noobs.


(Erik-Ftn) #1

I surely wouldn’t mind maps with some small random details in it. Eg different litter/ cover/ crates in a battlefield/ trenches/ corridor area so that you actually have to look and not dash blindly to your favourite cover.

I checked out the script in password2 and I guess creating some func_statics and then run a script with a random section and lighting a selection of those func_statics is pretty trivial.

Now, if you’re a mapper who have not yet covered scripting, here is a prefab random generator I created only out of enteties. (It’s a working devmap.)

It randomly lights one out of four func_statics (25% prob.), takes up to 22 sec to stabilize after the map starts and works great when I run it.

Of course there is no limit on how many func_statics you can link each endpoint to. To use it you should prob make my 4 statics to triggers and then link that one to your statics, just for clarity.

cheers

Erik

// entity 0
{
"angle" "-1"
"classname" "worldspawn"
"mapcoordsmins" "-1280 1280"
"mapcoordsmaxs" "1352 -1352"
"type" "2"
// brush 0
{
( 56 504 0 ) ( 48 504 0 ) ( 48 496 0 ) tobruk_wall_sd/tobruk_wall_base7_phong 16 224 0 0.500000 0.500000 0 0 0
( -16 496 568 ) ( -16 504 568 ) ( -8 504 568 ) tobruk_wall_sd/tobruk_wall_base7_phong 16 224 0 0.500000 0.500000 0 0 0
( 1136 496 144 ) ( 1144 496 144 ) ( 1144 496 0 ) tobruk_wall_sd/tobruk_wall_base7_phong 16 0 0 0.500000 0.500000 0 0 0
( 1144 496 400 ) ( 1144 504 400 ) ( 1144 504 256 ) tobruk_wall_sd/tobruk_wall_base7_phong -224 0 0 0.500000 0.500000 0 0 0
( 56 504 144 ) ( 48 504 144 ) ( 48 504 0 ) tobruk_wall_sd/tobruk_wall_base7_phong 16 0 0 0.500000 0.500000 0 0 0
( -1096 496 400 ) ( -1096 488 400 ) ( -1096 488 256 ) tobruk_wall_sd/tobruk_wall_base7_phong -224 0 0 0.500000 0.500000 0 0 0
}
// brush 1
{
( 56 -528 0 ) ( 48 -528 0 ) ( 48 -536 0 ) tobruk_wall_sd/tobruk_wall_base7_phong 16 224 0 0.500000 0.500000 0 0 0
( -16 -536 568 ) ( -16 -528 568 ) ( -8 -528 568 ) tobruk_wall_sd/tobruk_wall_base7_phong 16 224 0 0.500000 0.500000 0 0 0
( 48 -536 144 ) ( 56 -536 144 ) ( 56 -536 0 ) tobruk_wall_sd/tobruk_wall_base7_phong 16 0 0 0.500000 0.500000 0 0 0
( 1144 -536 400 ) ( 1144 -528 400 ) ( 1144 -528 256 ) tobruk_wall_sd/tobruk_wall_base7_phong -224 0 0 0.500000 0.500000 0 0 0
( 1144 -528 144 ) ( 1136 -528 144 ) ( 1136 -528 0 ) tobruk_wall_sd/tobruk_wall_base7_phong 16 0 0 0.500000 0.500000 0 0 0
( -1096 -536 400 ) ( -1096 -544 400 ) ( -1096 -544 256 ) tobruk_wall_sd/tobruk_wall_base7_phong -224 0 0 0.500000 0.500000 0 0 0
}
// brush 2
{
( -1096 -24 576 ) ( -1096 -400 576 ) ( -1096 -400 568 ) skies/sd_wurzburgsky -96 0 0 0.500000 0.500000 0 0 0
( 632 496 576 ) ( -8 496 576 ) ( -8 496 568 ) skies/sd_wurzburgsky 16 0 0 0.500000 0.500000 0 0 0
( 1144 -400 576 ) ( 1144 -24 576 ) ( 1144 -24 568 ) skies/sd_wurzburgsky -96 0 0 0.500000 0.500000 0 0 0
( -8 -528 576 ) ( 632 -528 576 ) ( 632 -528 568 ) skies/sd_wurzburgsky 16 0 0 0.500000 0.500000 0 0 0
( -1096 112 576 ) ( -1096 488 576 ) ( -456 488 576 ) skies/sd_wurzburgsky 16 96 0 0.500000 0.500000 0 0 0
( -456 488 568 ) ( -1096 488 568 ) ( -1096 112 568 ) skies/sd_wurzburgsky 16 96 0 0.500000 0.500000 0 0 0
}
// brush 3
{
( -1104 496 88 ) ( -1104 -16 88 ) ( -1104 -16 0 ) tobruk_wall_sd/tobruk_wall_base7_phong -224 0 0 0.500000 0.500000 0 0 0
( -1096 496 88 ) ( -1104 496 88 ) ( -1104 496 0 ) tobruk_wall_sd/tobruk_wall_base7_phong 16 0 0 0.500000 0.500000 0 0 0
( -1096 -528 344 ) ( -1096 -16 344 ) ( -1096 -16 256 ) tobruk_wall_sd/tobruk_wall_base7_phong -224 0 0 0.500000 0.500000 0 0 0
( -1104 -528 88 ) ( -1096 -528 88 ) ( -1096 -528 0 ) tobruk_wall_sd/tobruk_wall_base7_phong 16 0 0 0.500000 0.500000 0 0 0
( -1096 -16 568 ) ( -1096 496 568 ) ( -1088 496 568 ) tobruk_wall_sd/tobruk_wall_base7_phong 16 224 0 0.500000 0.500000 0 0 0
( -1096 496 0 ) ( -1104 496 0 ) ( -1104 -16 0 ) tobruk_wall_sd/tobruk_wall_base7_phong 16 224 0 0.500000 0.500000 0 0 0
}
// brush 4
{
( 1152 496 0 ) ( 1144 496 0 ) ( 1144 -16 0 ) tobruk_wall_sd/tobruk_wall_base7_phong 144 224 0 0.500000 0.500000 0 0 0
( 1152 -16 568 ) ( 1152 496 568 ) ( 1160 496 568 ) tobruk_wall_sd/tobruk_wall_base7_phong 144 224 0 0.500000 0.500000 0 0 0
( 1144 -528 88 ) ( 1152 -528 88 ) ( 1152 -528 0 ) tobruk_wall_sd/tobruk_wall_base7_phong 144 0 0 0.500000 0.500000 0 0 0
( 1152 -16 88 ) ( 1152 496 88 ) ( 1152 496 0 ) tobruk_wall_sd/tobruk_wall_base7_phong -224 0 0 0.500000 0.500000 0 0 0
( 1152 496 88 ) ( 1144 496 88 ) ( 1144 496 0 ) tobruk_wall_sd/tobruk_wall_base7_phong 144 0 0 0.500000 0.500000 0 0 0
( 1144 -16 344 ) ( 1144 -528 344 ) ( 1144 -528 256 ) tobruk_wall_sd/tobruk_wall_base7_phong -224 0 0 0.500000 0.500000 0 0 0
}
// brush 5
{
( -456 488 -8 ) ( -1096 488 -8 ) ( -1096 112 -8 ) fueldump/snow_floor 16 224 0 0.500000 0.500000 0 0 0
( -1096 112 0 ) ( -1096 488 0 ) ( -456 488 0 ) fueldump/snow_floor 16 224 0 0.500000 0.500000 0 0 0
( -8 -528 0 ) ( 632 -528 0 ) ( 632 -528 -8 ) fueldump/snow_floor 16 0 0 0.500000 0.500000 0 0 0
( 1144 -400 0 ) ( 1144 -24 0 ) ( 1144 -24 -8 ) fueldump/snow_floor -224 0 0 0.500000 0.500000 0 0 0
( 632 496 0 ) ( -8 496 0 ) ( -8 496 -8 ) fueldump/snow_floor 16 0 0 0.500000 0.500000 0 0 0
( -1096 -24 0 ) ( -1096 -400 0 ) ( -1096 -400 -8 ) fueldump/snow_floor -224 0 0 0.500000 0.500000 0 0 0
}
// brush 6
{
( 0 -320 56 ) ( 0 -328 56 ) ( 0 -328 48 ) egypt_walls_sd/stucco01_phong 0 0 0 0.500000 0.500000 0 0 0
( 64 -320 56 ) ( 0 -320 56 ) ( 0 -320 48 ) egypt_walls_sd/stucco01_phong 0 0 0 0.500000 0.500000 0 0 0
( 64 -328 56 ) ( 64 -320 56 ) ( 64 -320 48 ) egypt_walls_sd/stucco01_phong 0 0 0 0.500000 0.500000 0 0 0
( 0 -328 56 ) ( 64 -328 56 ) ( 64 -328 48 ) egypt_walls_sd/stucco01_phong 0 0 0 0.500000 0.500000 0 0 0
( 0 -328 96 ) ( 0 -320 96 ) ( 64 -320 96 ) egypt_walls_sd/stucco01_phong 0 0 0 0.500000 0.500000 0 0 0
( 64 -320 48 ) ( 0 -320 48 ) ( 0 -328 48 ) egypt_walls_sd/stucco01_phong 0 0 0 0.500000 0.500000 0 0 0
}
// brush 7
{
( 92 -320 0 ) ( 28 -320 0 ) ( 28 -328 0 ) xlab_wall/xmetal_c03_phong 0 0 0 0.500000 0.500000 0 0 0
( 28 -328 48 ) ( 28 -320 48 ) ( 92 -320 48 ) xlab_wall/xmetal_c03_phong 0 0 0 0.500000 0.500000 0 0 0
( 28 -328 8 ) ( 92 -328 8 ) ( 92 -328 0 ) xlab_wall/xmetal_c03_phong 0 0 0 0.500000 0.500000 0 0 0
( 36 -336 8 ) ( 36 -328 8 ) ( 36 -328 0 ) xlab_wall/xmetal_c03_phong 0 0 0 0.500000 0.500000 0 0 0
( 92 -320 8 ) ( 28 -320 8 ) ( 28 -320 0 ) xlab_wall/xmetal_c03_phong 0 0 0 0.500000 0.500000 0 0 0
( 28 -320 8 ) ( 28 -328 8 ) ( 28 -328 0 ) xlab_wall/xmetal_c03_phong 0 0 0 0.500000 0.500000 0 0 0
}
}
// entity 1
{
"origin" "104 -104 112"
"classname" "team_CTF_bluespawn"
}
// entity 2
{
"origin" "320 32 80"
"classname" "team_CTF_redspawn"
}
// entity 3
{
"origin" "328 -144 176"
"classname" "info_player_deathmatch"
}
// entity 4
{
"target" "t2"
"targetname" "t5"
"random" "4"
"wait" "8"
"origin" "-360 288 232"
"classname" "target_delay"
}
// entity 5
{
"spawnflags" "1"
"target" "t2"
"wait" "4"
"origin" "-328 192 232"
"classname" "func_timer"
}
// entity 6
{
"target" "t3"
"targetname" "t2"
"delay" "3"
"classname" "target_delay"
"origin" "-360 192 232"
}
// entity 7
{
"target" "t11"
"targetname" "t3"
"delay" "5"
"origin" "-424 192 232"
"classname" "target_delay"
}
// entity 8
{
"target" "t13"
"targetname" "t11"
"classname" "trigger_once"
// brush 0
{
( -552 296 240 ) ( -584 296 240 ) ( -584 296 224 ) common/trigger 32 47 0 0.500000 0.500000 0 7 0
( -552 264 240 ) ( -552 296 240 ) ( -552 296 224 ) common/trigger -48 47 -180 0.500000 -0.500000 0 7 0
( -584 264 240 ) ( -552 264 240 ) ( -552 264 224 ) common/trigger 32 47 0 0.500000 0.500000 0 7 0
( -584 296 240 ) ( -584 264 240 ) ( -584 264 224 ) common/trigger -48 47 -180 0.500000 -0.500000 0 7 0
( -584 296 240 ) ( -552 296 240 ) ( -552 264 240 ) common/trigger 15 -31 -90 0.500000 0.500000 0 7 0
( -552 264 224 ) ( -552 296 224 ) ( -584 296 224 ) common/trigger 15 -31 -90 0.500000 0.500000 0 7 0
}
}
// entity 9
{
"target" "t14"
"targetname" "t11"
"classname" "trigger_once"
// brush 0
{
( -552 200 224 ) ( -552 232 224 ) ( -584 232 224 ) common/trigger 15 -31 -90 0.500000 0.500000 0 7 0
( -584 232 240 ) ( -552 232 240 ) ( -552 200 240 ) common/trigger 15 -31 -90 0.500000 0.500000 0 7 0
( -584 232 240 ) ( -584 200 240 ) ( -584 200 224 ) common/trigger -48 47 -180 0.500000 -0.500000 0 7 0
( -584 200 240 ) ( -552 200 240 ) ( -552 200 224 ) common/trigger 32 47 0 0.500000 0.500000 0 7 0
( -552 200 240 ) ( -552 232 240 ) ( -552 232 224 ) common/trigger -48 47 -180 0.500000 -0.500000 0 7 0
( -552 232 240 ) ( -584 232 240 ) ( -584 232 224 ) common/trigger 32 47 0 0.500000 0.500000 0 7 0
}
}
// entity 10
{
"target" "t16"
"targetname" "t12"
"classname" "trigger_once"
// brush 0
{
( -560 -312 240 ) ( -592 -312 240 ) ( -592 -312 224 ) common/trigger 32 47 0 0.500000 0.500000 0 7 0
( -560 -344 240 ) ( -560 -312 240 ) ( -560 -312 224 ) common/trigger -48 47 -180 0.500000 -0.500000 0 7 0
( -592 -344 240 ) ( -560 -344 240 ) ( -560 -344 224 ) common/trigger 32 47 0 0.500000 0.500000 0 7 0
( -592 -312 240 ) ( -592 -344 240 ) ( -592 -344 224 ) common/trigger -48 47 -180 0.500000 -0.500000 0 7 0
( -592 -312 240 ) ( -560 -312 240 ) ( -560 -344 240 ) common/trigger 15 -31 -90 0.500000 0.500000 0 7 0
( -560 -344 224 ) ( -560 -312 224 ) ( -592 -312 224 ) common/trigger 15 -31 -90 0.500000 0.500000 0 7 0
}
}
// entity 11
{
"target" "t13"
"targetname" "t12"
"classname" "trigger_once"
// brush 0
{
( -560 -280 224 ) ( -560 -248 224 ) ( -592 -248 224 ) common/trigger 15 -31 -90 0.500000 0.500000 0 7 0
( -592 -248 240 ) ( -560 -248 240 ) ( -560 -280 240 ) common/trigger 15 -31 -90 0.500000 0.500000 0 7 0
( -592 -248 240 ) ( -592 -280 240 ) ( -592 -280 224 ) common/trigger -48 47 -180 0.500000 -0.500000 0 7 0
( -592 -280 240 ) ( -560 -280 240 ) ( -560 -280 224 ) common/trigger 32 47 0 0.500000 0.500000 0 7 0
( -560 -280 240 ) ( -560 -248 240 ) ( -560 -248 224 ) common/trigger -48 47 -180 0.500000 -0.500000 0 7 0
( -560 -248 240 ) ( -592 -248 240 ) ( -592 -248 224 ) common/trigger 32 47 0 0.500000 0.500000 0 7 0
}
}
// entity 12
{
"target" "t13"
"targetname" "t15"
"classname" "trigger_once"
// brush 0
{
( -744 96 240 ) ( -776 96 240 ) ( -776 96 224 ) common/trigger 32 47 0 0.500000 0.500000 0 7 0
( -744 64 240 ) ( -744 96 240 ) ( -744 96 224 ) common/trigger -48 47 -180 0.500000 -0.500000 0 7 0
( -776 64 240 ) ( -744 64 240 ) ( -744 64 224 ) common/trigger 32 47 0 0.500000 0.500000 0 7 0
( -776 96 240 ) ( -776 64 240 ) ( -776 64 224 ) common/trigger -48 47 -180 0.500000 -0.500000 0 7 0
( -776 96 240 ) ( -744 96 240 ) ( -744 64 240 ) common/trigger 15 -31 -90 0.500000 0.500000 0 7 0
( -744 64 224 ) ( -744 96 224 ) ( -776 96 224 ) common/trigger 15 -31 -90 0.500000 0.500000 0 7 0
}
}
// entity 13
{
"target" "t14"
"targetname" "t15"
"classname" "trigger_once"
// brush 0
{
( -744 -8 224 ) ( -744 24 224 ) ( -776 24 224 ) common/trigger 15 -31 -90 0.500000 0.500000 0 7 0
( -776 24 240 ) ( -744 24 240 ) ( -744 -8 240 ) common/trigger 15 -31 -90 0.500000 0.500000 0 7 0
( -776 24 240 ) ( -776 -8 240 ) ( -776 -8 224 ) common/trigger -48 47 -180 0.500000 -0.500000 0 7 0
( -776 -8 240 ) ( -744 -8 240 ) ( -744 -8 224 ) common/trigger 32 47 0 0.500000 0.500000 0 7 0
( -744 -8 240 ) ( -744 24 240 ) ( -744 24 224 ) common/trigger -48 47 -180 0.500000 -0.500000 0 7 0
( -744 24 240 ) ( -776 24 240 ) ( -776 24 224 ) common/trigger 32 47 0 0.500000 0.500000 0 7 0
}
}
// entity 14
{
"target" "t16"
"targetname" "t15"
"classname" "trigger_once"
// brush 0
{
( -744 -40 240 ) ( -776 -40 240 ) ( -776 -40 224 ) common/trigger 32 47 0 0.500000 0.500000 0 7 0
( -744 -72 240 ) ( -744 -40 240 ) ( -744 -40 224 ) common/trigger -48 47 -180 0.500000 -0.500000 0 7 0
( -776 -72 240 ) ( -744 -72 240 ) ( -744 -72 224 ) common/trigger 32 47 0 0.500000 0.500000 0 7 0
( -776 -40 240 ) ( -776 -72 240 ) ( -776 -72 224 ) common/trigger -48 47 -180 0.500000 -0.500000 0 7 0
( -776 -40 240 ) ( -744 -40 240 ) ( -744 -72 240 ) common/trigger 15 -31 -90 0.500000 0.500000 0 7 0
( -744 -72 224 ) ( -744 -40 224 ) ( -776 -40 224 ) common/trigger 15 -31 -90 0.500000 0.500000 0 7 0
}
}
// entity 15
{
"target" "t17"
"targetname" "t15"
"classname" "trigger_once"
// brush 0
{
( -744 -128 224 ) ( -744 -96 224 ) ( -776 -96 224 ) common/trigger 15 -31 -90 0.500000 0.500000 0 7 0
( -776 -96 240 ) ( -744 -96 240 ) ( -744 -128 240 ) common/trigger 15 -31 -90 0.500000 0.500000 0 7 0
( -776 -96 240 ) ( -776 -128 240 ) ( -776 -128 224 ) common/trigger -48 47 -180 0.500000 -0.500000 0 7 0
( -776 -128 240 ) ( -744 -128 240 ) ( -744 -128 224 ) common/trigger 32 47 0 0.500000 0.500000 0 7 0
( -744 -128 240 ) ( -744 -96 240 ) ( -744 -96 224 ) common/trigger -48 47 -180 0.500000 -0.500000 0 7 0
( -744 -96 240 ) ( -776 -96 240 ) ( -776 -96 224 ) common/trigger 32 47 0 0.500000 0.500000 0 7 0
}
}
// entity 16
{
"target" "t8"
"targetname" "t7"
"classname" "trigger_multiple"
// brush 0
{
( -432 32 224 ) ( -432 56 224 ) ( -464 56 224 ) common/trigger 15 -31 -90 0.500000 0.500000 0 7 0
( -464 56 240 ) ( -432 56 240 ) ( -432 32 240 ) common/trigger 15 -31 -90 0.500000 0.500000 0 7 0
( -464 56 240 ) ( -464 32 240 ) ( -464 32 224 ) common/trigger -48 47 -180 0.500000 -0.500000 0 7 0
( -464 24 240 ) ( -432 24 240 ) ( -432 24 224 ) common/trigger 32 47 0 0.500000 0.500000 0 7 0
( -432 32 240 ) ( -432 56 240 ) ( -432 56 224 ) common/trigger -48 47 -180 0.500000 -0.500000 0 7 0
( -432 56 240 ) ( -464 56 240 ) ( -464 56 224 ) common/trigger 32 47 0 0.500000 0.500000 0 7 0
}
}
// entity 17
{
"target" "t9"
"targetname" "t7"
"classname" "trigger_multiple"
// brush 0
{
( -432 -72 240 ) ( -464 -72 240 ) ( -464 -72 224 ) common/trigger 32 47 0 0.500000 0.500000 0 7 0
( -432 -96 240 ) ( -432 -72 240 ) ( -432 -72 224 ) common/trigger -48 47 -180 0.500000 -0.500000 0 7 0
( -464 -104 240 ) ( -432 -104 240 ) ( -432 -104 224 ) common/trigger 32 47 0 0.500000 0.500000 0 7 0
( -464 -72 240 ) ( -464 -96 240 ) ( -464 -96 224 ) common/trigger -48 47 -180 0.500000 -0.500000 0 7 0
( -464 -72 240 ) ( -432 -72 240 ) ( -432 -96 240 ) common/trigger 15 -31 -90 0.500000 0.500000 0 7 0
( -432 -96 224 ) ( -432 -72 224 ) ( -464 -72 224 ) common/trigger 15 -31 -90 0.500000 0.500000 0 7 0
}
}
// entity 18
{
"targetname" "t13"
"classname" "func_static"
// brush 0
{
( -936 176 8 ) ( -936 224 8 ) ( -976 224 8 ) xlab_wall/xmetal_c03_phong -47 -160 -90 0.500000 0.500000 0 0 0
( -976 224 128 ) ( -936 224 128 ) ( -936 176 128 ) xlab_wall/xmetal_c03_phong -47 -160 -90 0.500000 0.500000 0 0 0
( -976 224 24 ) ( -976 176 24 ) ( -976 176 8 ) xlab_wall/xmetal_c03_phong -48 255 -180 0.500000 -0.500000 0 0 0
( -976 176 24 ) ( -936 176 24 ) ( -936 176 8 ) xlab_wall/xmetal_c03_phong 160 255 0 0.500000 0.500000 0 0 0
( -936 176 24 ) ( -936 224 24 ) ( -936 224 8 ) xlab_wall/xmetal_c03_phong -48 255 -180 0.500000 -0.500000 0 0 0
( -936 224 24 ) ( -976 224 24 ) ( -976 224 8 ) xlab_wall/xmetal_c03_phong 160 255 0 0.500000 0.500000 0 0 0
}
}
// entity 19
{
"spawnflags" "1"
"targetname" "t14"
"classname" "func_static"
// brush 0
{
( -936 104 128 ) ( -976 104 128 ) ( -976 104 112 ) tobruk_wall_sd/tobruk_wall_base7_phong 0 0 0 0.500000 0.500000 0 0 0
( -936 56 24 ) ( -936 104 24 ) ( -936 104 8 ) tobruk_wall_sd/tobruk_wall_base7_phong 0 0 0 0.500000 0.500000 0 0 0
( -976 56 24 ) ( -936 56 24 ) ( -936 56 8 ) tobruk_wall_sd/tobruk_wall_base7_phong 0 0 0 0.500000 0.500000 0 0 0
( -976 104 24 ) ( -976 56 24 ) ( -976 56 8 ) tobruk_wall_sd/tobruk_wall_base7_phong 0 0 0 0.500000 0.500000 0 0 0
( -976 104 128 ) ( -936 104 128 ) ( -936 56 128 ) tobruk_wall_sd/tobruk_wall_base7_phong 0 0 0 0.500000 0.500000 0 0 0
( -936 56 8 ) ( -936 104 8 ) ( -976 104 8 ) tobruk_wall_sd/tobruk_wall_base7_phong 0 0 0 0.500000 0.500000 0 0 0
}
}
// entity 20
{
"spawnflags" "1"
"targetname" "t16"
"classname" "func_static"
// brush 0
{
( -936 -96 8 ) ( -936 -48 8 ) ( -976 -48 8 ) fueldump/snow_floor -47 -160 -90 0.500000 0.500000 0 0 0
( -976 -48 128 ) ( -936 -48 128 ) ( -936 -96 128 ) fueldump/snow_floor -47 -160 -90 0.500000 0.500000 0 0 0
( -976 -48 24 ) ( -976 -96 24 ) ( -976 -96 8 ) fueldump/snow_floor -48 255 -180 0.500000 -0.500000 0 0 0
( -976 -96 24 ) ( -936 -96 24 ) ( -936 -96 8 ) fueldump/snow_floor 160 255 0 0.500000 0.500000 0 0 0
( -936 -96 24 ) ( -936 -48 24 ) ( -936 -48 8 ) fueldump/snow_floor -48 255 -180 0.500000 -0.500000 0 0 0
( -936 -48 128 ) ( -976 -48 128 ) ( -976 -48 112 ) fueldump/snow_floor 160 255 0 0.500000 0.500000 0 0 0
}
}
// entity 21
{
"spawnflags" "1"
"targetname" "t17"
"classname" "func_static"
// brush 0
{
( -936 -152 128 ) ( -976 -152 128 ) ( -976 -152 112 ) egypt_walls_sd/stucco01_phong 160 255 0 0.500000 0.500000 0 0 0
( -936 -200 24 ) ( -936 -152 24 ) ( -936 -152 8 ) egypt_walls_sd/stucco01_phong -48 255 -180 0.500000 -0.500000 0 0 0
( -976 -200 24 ) ( -936 -200 24 ) ( -936 -200 8 ) egypt_walls_sd/stucco01_phong 160 255 0 0.500000 0.500000 0 0 0
( -976 -152 24 ) ( -976 -200 24 ) ( -976 -200 8 ) egypt_walls_sd/stucco01_phong -48 255 -180 0.500000 -0.500000 0 0 0
( -976 -152 128 ) ( -936 -152 128 ) ( -936 -200 128 ) egypt_walls_sd/stucco01_phong -47 -160 -90 0.500000 0.500000 0 0 0
( -936 -200 8 ) ( -936 -152 8 ) ( -976 -152 8 ) egypt_walls_sd/stucco01_phong -47 -160 -90 0.500000 0.500000 0 0 0
}
}
// entity 22
{
"target" "t4"
"targetname" "t5"
"classname" "target_delay"
"origin" "-360 -336 232"
"wait" "8"
"random" "4"
}
// entity 23
{
"spawnflags" "1"
"target" "t4"
"classname" "func_timer"
"origin" "-328 -240 232"
"wait" "4"
}
// entity 24
{
"target" "t6"
"targetname" "t4"
"origin" "-360 -240 232"
"classname" "target_delay"
"delay" "3"
}
// entity 25
{
"target" "t12"
"targetname" "t6"
"classname" "target_delay"
"origin" "-424 -240 232"
"delay" "5"
}
// entity 26
{
"spawnflags" "1"
"target" "t7"
"wait" "4"
"origin" "-400 -24 232"
"classname" "func_timer"
}
// entity 27
{
"target" "t10"
"targetname" "t8"
"origin" "-520 40 232"
"classname" "target_delay"
"delay" "3"
}
// entity 28
{
"target" "t15"
"targetname" "t10"
"classname" "target_delay"
"origin" "-576 -24 232"
"delay" "5"
}
// entity 29
{
"target" "t10"
"targetname" "t9"
"delay" "3"
"classname" "target_delay"
"origin" "-520 -88 232"
}
// entity 30
{
"target" "t8"
"targetname" "t11"
"classname" "func_timer"
"origin" "-568 144 232"
"wait" "1"
}
// entity 31
{
"target" "t9"
"targetname" "t12"
"wait" "1"
"origin" "-576 -200 232"
"classname" "func_timer"
}
// entity 32
{
"classname" "trigger_always"
"origin" "-176 -24 248"
"target" "t5"
}
// entity 33
{
"track" "a random system. If you use this system in your maps include at least this in your documentation: Random system by Erik-Ftn, thanks. "
"classname" "trigger_objective_info"
// brush 0
{
( 21 -296 64 ) ( 29 -296 64 ) ( 29 -296 89 ) radiant/notex 37 28 -180 0.500000 0.500000 0 0 0
( 29 -303 90 ) ( 29 -303 65 ) ( 21 -303 65 ) radiant/notex 37 28 -180 0.500000 0.500000 0 0 0
( 29 -302 90 ) ( 21 -302 90 ) ( 21 -294 90 ) radiant/notex 36 -41 -180 0.500000 0.500000 0 0 0
( 21 -302 90 ) ( 21 -302 65 ) ( 21 -294 65 ) radiant/notex -27 -40 -90 0.500000 -0.500000 0 0 0
( 21 -294 54 ) ( 29 -294 54 ) ( 29 -286 54 ) radiant/notex 36 -41 -180 0.500000 0.500000 0 0 0
( 45 -302 65 ) ( 45 -302 90 ) ( 45 -294 90 ) radiant/notex -27 -40 -90 0.500000 -0.500000 0 0 0
}
}

(redfella) #2

hmmm, interesting idea.

although, would it take away from the whole point in learning a map? …eventually though everyone would learn all the variables for each map if they played it enough.

But still, an awesome idea!

you could even have like random spawn points or random wall locations which would in turn provide a different gameplay experience for each session. Or how about random mortar shots… instead of them landing in the same place all the time. Or random objectives? random objective locations? the possibilities are endless.

:slight_smile: n1


(G0-Gerbil) #3

Why does it take up to 22 seconds to stabilise - why would you want that?
:???:


(sock) #4

This is a nice idea but creating it out of entity chains is just madness and confusing to follow. Why not use the power and simplicity of the scripting system. Here is the map and 2 different script examples of randomiz0ring various items around a map.

Now I recommend using script_movers because they are more stable than func_statics. There is a limit on func_statics / script_movers and they do count towards the overall map entity limit. Also these random objects must not cast shadows otherwise the map will look wierd with missing geometry and mysterious shadows.

The first script example randomiz0rs the items via their own script routines. But it does need to be staggered via the spawn times otherwise it does not work correctly. The second script example does not suffer from timing issues but it will need to be split if you are trying to randomize too much at once.

Enjoy
Sock
:moo:

Map:


// entity 0
{
"mapcoordsmaxs" "1344 -832"
"mapcoordsmins" "-384 896"
"classname" "worldspawn"
// brush 0
{
( 320 448 -64 ) ( -128 448 -64 ) ( -128 0 -64 ) common/caulk 0.000000 0.000000 0.000000 0.500000 0.500000 0 4 0
( -128 0 -32 ) ( -128 448 -32 ) ( 320 448 -32 ) fueldump/cave_floor 0.000000 0.000000 0.000000 0.500000 0.500000 0 0 0
( -144 -384 -32 ) ( 304 -384 -32 ) ( 304 -384 -64 ) common/caulk 0.000000 0.000000 0.000000 0.500000 0.500000 0 4 0
( 1152 -8 -32 ) ( 1152 440 -32 ) ( 1152 440 -64 ) common/caulk 0.000000 0.000000 0.000000 0.500000 0.500000 0 4 0
( 320 704 -32 ) ( -128 704 -32 ) ( -128 704 -64 ) common/caulk 0.000000 0.000000 0.000000 0.500000 0.500000 0 4 0
( -192 448 -32 ) ( -192 0 -32 ) ( -192 0 -64 ) common/caulk 0.000000 0.000000 0.000000 0.500000 0.500000 0 4 0
}
// brush 1
{
( 1216 400 384 ) ( 1216 432 384 ) ( 1216 400 416 ) fueldump/fueldumpsky 0.000000 0.000000 0.000000 0.500000 0.500000 0 0 0
( 960 512 128 ) ( 512 512 128 ) ( 512 64 128 ) common/caulk 0.000000 0.000000 0.000000 0.500000 0.500000 0 4 0
( 512 64 512 ) ( 512 512 512 ) ( 960 512 512 ) common/caulk 0.000000 0.000000 0.000000 0.500000 0.500000 0 4 0
( 496 -448 96 ) ( 944 -448 96 ) ( 944 -448 64 ) common/caulk 0.000000 0.000000 0.000000 0.500000 0.500000 0 4 0
( 1280 56 96 ) ( 1280 504 96 ) ( 1280 504 64 ) common/caulk 0.000000 0.000000 0.000000 0.500000 0.500000 0 4 0
( 960 768 96 ) ( 512 768 96 ) ( 512 768 64 ) common/caulk 0.000000 0.000000 0.000000 0.500000 0.500000 0 4 0
}
// brush 2
{
( 1216 -8 -32 ) ( 1216 440 -32 ) ( 1216 440 -64 ) common/caulk 0.000000 0.000000 0.000000 0.500000 0.500000 0 4 0
( 448 0 128 ) ( 448 448 128 ) ( 896 448 128 ) fueldump/cave_dark 0.000000 0.000000 0.000000 0.500000 0.500000 0 0 0
( 896 448 -32 ) ( 448 448 -32 ) ( 448 0 -32 ) common/caulk 0.000000 0.000000 0.000000 0.500000 0.500000 0 4 0
( 1152 336 -64 ) ( 1152 368 -64 ) ( 1152 336 -32 ) fueldump/cave_dark 0.000000 0.000000 0.000000 0.500000 0.500000 0 0 0
( 1216 -448 -64 ) ( 1152 -384 -64 ) ( 1216 -448 64 ) common/caulk 0.000000 0.000000 0.000000 0.500000 0.500000 0 4 0
( 1152 704 -64 ) ( 1216 768 -64 ) ( 1152 704 64 ) common/caulk 0.000000 0.000000 0.000000 0.500000 0.500000 0 4 0
( 1152 512 64 ) ( 1184 512 128 ) ( 1152 -448 64 ) fueldump/cave_dark 0.000000 0.000000 0.000000 0.500000 0.500000 0 0 0
}
// brush 3
{
( 704 -384 64 ) ( 704 -416 128 ) ( -256 -384 64 ) fueldump/cave_dark 0.000000 0.000000 0.000000 0.500000 0.500000 0 0 0
( 1152 -384 -64 ) ( 1216 -448 -64 ) ( 1152 -384 64 ) common/caulk 0.000000 0.000000 0.000000 0.500000 0.500000 0 4 0
( -256 -448 -64 ) ( -192 -384 -64 ) ( -256 -448 64 ) common/caulk 0.000000 0.000000 0.000000 0.500000 0.500000 0 4 0
( 528 -384 -64 ) ( 560 -384 -64 ) ( 528 -384 -32 ) fueldump/cave_dark 0.000000 0.000000 0.000000 0.500000 0.500000 0 0 0
( 640 -128 -32 ) ( 640 320 -32 ) ( 192 320 -32 ) common/caulk 0.000000 0.000000 0.000000 0.500000 0.500000 0 4 0
( 192 320 128 ) ( 640 320 128 ) ( 640 -128 128 ) fueldump/cave_dark 0.000000 0.000000 0.000000 0.500000 0.500000 0 0 0
( 184 -448 -32 ) ( 632 -448 -32 ) ( 632 -448 -64 ) common/caulk 0.000000 0.000000 0.000000 0.500000 0.500000 0 4 0
}
// brush 4
{
( -192 -448 64 ) ( -224 -448 128 ) ( -192 512 64 ) fueldump/cave_dark 0.000000 0.000000 0.000000 0.500000 0.500000 0 0 0
( -192 -384 -64 ) ( -256 -448 -64 ) ( -192 -384 64 ) common/caulk 0.000000 0.000000 0.000000 0.500000 0.500000 0 4 0
( -224 736 -64 ) ( -160 672 -64 ) ( -224 736 64 ) common/caulk 0.000000 0.000000 0.000000 0.500000 0.500000 0 4 0
( -192 -272 -64 ) ( -192 -304 -64 ) ( -192 -272 -32 ) fueldump/cave_dark 0.000000 0.000000 0.000000 0.500000 0.500000 0 0 0
( 64 -384 -32 ) ( 512 -384 -32 ) ( 512 64 -32 ) common/caulk 0.000000 0.000000 0.000000 0.500000 0.500000 0 4 0
( 512 64 128 ) ( 512 -384 128 ) ( 64 -384 128 ) fueldump/cave_dark 0.000000 0.000000 0.000000 0.500000 0.500000 0 0 0
( -256 72 -32 ) ( -256 -376 -32 ) ( -256 -376 -64 ) common/caulk 0.000000 0.000000 0.000000 0.500000 0.500000 0 4 0
}
// brush 5
{
( 264 768 -32 ) ( -184 768 -32 ) ( -184 768 -64 ) common/caulk 0.000000 0.000000 0.000000 0.500000 0.500000 0 4 0
( 256 0 128 ) ( -192 0 128 ) ( -192 448 128 ) fueldump/cave_dark 0.000000 0.000000 0.000000 0.500000 0.500000 0 0 0
( -192 448 -32 ) ( -192 0 -32 ) ( 256 0 -32 ) common/caulk 0.000000 0.000000 0.000000 0.500000 0.500000 0 4 0
( -112 704 -64 ) ( -144 704 -64 ) ( -112 704 -32 ) fueldump/cave_dark 0.000000 0.000000 0.000000 0.500000 0.500000 0 0 0
( 1184 736 -64 ) ( 1120 672 -64 ) ( 1184 736 64 ) common/caulk 0.000000 0.000000 0.000000 0.500000 0.500000 0 4 0
( -192 704 -64 ) ( -256 768 -64 ) ( -192 704 64 ) common/caulk 0.000000 0.000000 0.000000 0.500000 0.500000 0 4 0
( -256 704 64 ) ( -256 736 128 ) ( 704 704 64 ) fueldump/cave_dark 0.000000 0.000000 0.000000 0.500000 0.500000 0 0 0
}
// brush 6
{
( 1216 -224 96 ) ( 1216 224 96 ) ( 1216 224 64 ) common/caulk 0.000000 0.000000 0.000000 0.500000 0.500000 0 4 0
( 248 -512 96 ) ( 696 -512 96 ) ( 696 -512 64 ) common/caulk 0.000000 0.000000 0.000000 0.500000 0.500000 0 4 0
( -256 272 96 ) ( -256 -176 96 ) ( -256 -176 64 ) common/caulk 0.000000 0.000000 0.000000 0.500000 0.500000 0 4 0
( 256 256 512 ) ( 704 256 512 ) ( 704 -192 512 ) common/caulk 0.000000 0.000000 0.000000 0.500000 0.500000 0 4 0
( 704 -192 128 ) ( 704 256 128 ) ( 256 256 128 ) common/caulk 0.000000 0.000000 0.000000 0.500000 0.500000 0 4 0
( 592 -448 384 ) ( 624 -448 384 ) ( 592 -448 416 ) fueldump/fueldumpsky 0.000000 0.000000 0.000000 0.500000 0.500000 0 0 0
}
// brush 7
{
( 0 -448 96 ) ( 448 -448 96 ) ( 448 -448 64 ) common/caulk 0.000000 0.000000 0.000000 0.500000 0.500000 0 4 0
( -320 8 96 ) ( -320 -440 96 ) ( -320 -440 64 ) common/caulk 0.000000 0.000000 0.000000 0.500000 0.500000 0 4 0
( 464 768 96 ) ( 16 768 96 ) ( 16 768 64 ) common/caulk 0.000000 0.000000 0.000000 0.500000 0.500000 0 4 0
( 448 0 512 ) ( 448 -448 512 ) ( 0 -448 512 ) common/caulk 0.000000 0.000000 0.000000 0.500000 0.500000 0 4 0
( 0 -448 128 ) ( 448 -448 128 ) ( 448 0 128 ) common/caulk 0.000000 0.000000 0.000000 0.500000 0.500000 0 4 0
( -256 -336 384 ) ( -256 -368 384 ) ( -256 -336 416 ) fueldump/fueldumpsky 0.000000 0.000000 0.000000 0.500000 0.500000 0 0 0
}
// brush 8
{
( -144 768 384 ) ( -176 768 384 ) ( -144 768 416 ) fueldump/fueldumpsky 0.000000 0.000000 0.000000 0.500000 0.500000 0 0 0
( -256 512 128 ) ( -256 64 128 ) ( 192 64 128 ) common/caulk 0.000000 0.000000 0.000000 0.500000 0.500000 0 4 0
( 192 64 512 ) ( -256 64 512 ) ( -256 512 512 ) common/caulk 0.000000 0.000000 0.000000 0.500000 0.500000 0 4 0
( 1216 16 96 ) ( 1216 464 96 ) ( 1216 464 64 ) common/caulk 0.000000 0.000000 0.000000 0.500000 0.500000 0 4 0
( 200 832 96 ) ( -248 832 96 ) ( -248 832 64 ) common/caulk 0.000000 0.000000 0.000000 0.500000 0.500000 0 4 0
( -256 512 96 ) ( -256 64 96 ) ( -256 64 64 ) common/caulk 0.000000 0.000000 0.000000 0.500000 0.500000 0 4 0
}
// brush 9
{
( -256 384 544 ) ( -256 -64 544 ) ( -256 -64 512 ) common/caulk 0.000000 0.000000 0.000000 0.500000 0.500000 0 4 0
( 256 768 544 ) ( -192 768 544 ) ( -192 768 512 ) common/caulk 0.000000 0.000000 0.000000 0.500000 0.500000 0 4 0
( 1216 -104 544 ) ( 1216 344 544 ) ( 1216 344 512 ) common/caulk 0.000000 0.000000 0.000000 0.500000 0.500000 0 4 0
( -208 -448 544 ) ( 240 -448 544 ) ( 240 -448 512 ) common/caulk 0.000000 0.000000 0.000000 0.500000 0.500000 0 4 0
( -192 -64 576 ) ( -192 384 576 ) ( 256 384 576 ) common/caulk 0.000000 0.000000 0.000000 0.500000 0.500000 0 4 0
( 256 384 512 ) ( -192 384 512 ) ( -192 -64 512 ) fueldump/fueldumpsky 0.000000 0.000000 0.000000 0.500000 0.500000 0 0 0
}
// brush 10
{
( -384 896 -128 ) ( -384 -160 -128 ) ( -384 -160 -192 ) common/caulk 0.000000 0.000000 0.000000 0.500000 0.500000 0 4 0
( 832 896 -128 ) ( -384 896 -128 ) ( -384 896 -192 ) common/caulk 0.000000 0.000000 0.000000 0.500000 0.500000 0 4 0
( 1344 -192 -128 ) ( 1344 864 -128 ) ( 1344 864 -192 ) common/caulk 0.000000 0.000000 0.000000 0.500000 0.500000 0 4 0
( -368 -832 -128 ) ( 848 -832 -128 ) ( 848 -832 -192 ) common/caulk 0.000000 0.000000 0.000000 0.500000 0.500000 0 4 0
( -384 -160 -128 ) ( -384 896 -128 ) ( 832 896 -128 ) common/caulk 0.000000 0.000000 0.000000 0.500000 0.500000 0 4 0
( 832 896 -192 ) ( -384 896 -192 ) ( -384 -160 -192 ) common/caulk 0.000000 0.000000 0.000000 0.500000 0.500000 0 4 0
}
}
// entity 1
{
"angle" "360"
"spawnflags" "3"
"origin" "-128 128 0"
"classname" "team_CTF_bluespawn"
}
// entity 2
{
"angle" "360"
"spawnflags" "3"
"origin" "-128 0 0"
"classname" "team_CTF_redspawn"
}
// entity 3
{
"classname" "script_multiplayer"
"origin" "-128 64 128"
"scriptname" "game_manager"
}
// entity 4
{
"origin" "-192 64 120"
"classname" "info_player_deathmatch"
"angle" "360"
}
// entity 5
{
"classname" "team_WOLF_objective"
"origin" "-128 0 120"
"spawnflags" "1"
}
// entity 6
{
"spawnflags" "2"
"origin" "-128 128 120"
"classname" "team_WOLF_objective"
}
// entity 7
{
"scriptname" "random_block4"
"targetname" "random_block4"
"spawnflags" "2"
"classname" "script_mover"
// brush 0
{
( 760 -136 0 ) ( 696 -136 0 ) ( 696 -168 0 ) seawall_wall/wall03_top 0.000000 0.000000 0.000000 0.500000 0.500000 0 0 0
( 688 -168 128 ) ( 688 -136 128 ) ( 752 -136 128 ) rubble/debri_m01 0.000000 0.000000 0.000000 0.500000 0.500000 0 0 0
( 696 -240 216 ) ( 760 -240 216 ) ( 760 -240 56 ) seawall_wall/wall03_top 0.000000 0.000000 0.000000 0.500000 0.500000 0 0 0
( 1008 -168 216 ) ( 1008 -136 216 ) ( 1008 -136 56 ) seawall_wall/wall03_top 0.000000 0.000000 0.000000 0.500000 0.500000 0 0 0
( 760 -144 216 ) ( 696 -144 216 ) ( 696 -144 56 ) seawall_wall/wall03_top 0.000000 0.000000 0.000000 0.500000 0.500000 0 0 0
( 912 -136 216 ) ( 912 -168 216 ) ( 912 -168 56 ) seawall_wall/wall03_top 0.000000 0.000000 0.000000 0.500000 0.500000 0 0 0
}
// brush 1
{
( 944 -176 32 ) ( 944 -208 32 ) ( 944 -208 0 ) common/origin 0.000000 0.000000 0.000000 0.500000 0.500000 0 15 0
( 976 -176 32 ) ( 944 -176 32 ) ( 944 -176 0 ) common/origin 0.000000 0.000000 0.000000 0.500000 0.500000 0 15 0
( 976 -208 32 ) ( 976 -176 32 ) ( 976 -176 0 ) common/origin 0.000000 0.000000 0.000000 0.500000 0.500000 0 15 0
( 944 -208 32 ) ( 976 -208 32 ) ( 976 -208 0 ) common/origin 0.000000 0.000000 0.000000 0.500000 0.500000 0 15 0
( 944 -208 128 ) ( 944 -176 128 ) ( 976 -176 128 ) common/origin 0.000000 0.000000 0.000000 0.500000 0.500000 0 15 0
( 976 -176 -32 ) ( 944 -176 -32 ) ( 944 -208 -32 ) common/origin 0.000000 0.000000 0.000000 0.500000 0.500000 0 15 0
}
// brush 2
{
( 896 -136 184 ) ( 896 -168 184 ) ( 896 -168 24 ) egypt_floor_sd/block-16sq 0.000000 0.000000 0.000000 0.500000 0.500000 0 0 0
( 760 -128 184 ) ( 696 -128 184 ) ( 696 -128 24 ) egypt_floor_sd/block-16sq 0.000000 0.000000 0.000000 0.500000 0.500000 0 0 0
( 1024 -168 184 ) ( 1024 -136 184 ) ( 1024 -136 24 ) egypt_floor_sd/block-16sq 0.000000 0.000000 0.000000 0.500000 0.500000 0 0 0
( 696 -256 184 ) ( 760 -256 184 ) ( 760 -256 24 ) egypt_floor_sd/block-16sq 0.000000 0.000000 0.000000 0.500000 0.500000 0 0 0
( 688 -168 0 ) ( 688 -136 0 ) ( 752 -136 0 ) egypt_floor_sd/block-16sq 0.000000 0.000000 0.000000 0.500000 0.500000 0 0 0
( 760 -136 -32 ) ( 696 -136 -32 ) ( 696 -168 -32 ) egypt_floor_sd/block-16sq 0.000000 0.000000 0.000000 0.500000 0.500000 0 0 0
}
}
// entity 8
{
"scriptname" "random_block3"
"targetname" "random_block3"
"classname" "script_mover"
"spawnflags" "2"
// brush 0
{
( 912 88 216 ) ( 912 56 216 ) ( 912 56 56 ) seawall_wall/wall03_top -64.000000 0.000000 0.000000 0.500000 0.500000 0 0 0
( 760 80 216 ) ( 696 80 216 ) ( 696 80 56 ) seawall_wall/wall03_top 0.000000 0.000000 0.000000 0.500000 0.500000 0 0 0
( 1008 56 216 ) ( 1008 88 216 ) ( 1008 88 56 ) seawall_wall/wall03_top -64.000000 0.000000 0.000000 0.500000 0.500000 0 0 0
( 696 -16 216 ) ( 760 -16 216 ) ( 760 -16 56 ) seawall_wall/wall03_top 0.000000 0.000000 0.000000 0.500000 0.500000 0 0 0
( 688 56 96 ) ( 688 88 96 ) ( 752 88 96 ) rubble/debri_m01 0.000000 64.000000 0.000000 0.500000 0.500000 0 0 0
( 760 88 0 ) ( 696 88 0 ) ( 696 56 0 ) seawall_wall/wall03_top 0.000000 64.000000 0.000000 0.500000 0.500000 0 0 0
}
// brush 1
{
( 976 48 -32 ) ( 944 48 -32 ) ( 944 16 -32 ) common/origin 0.000000 0.000000 0.000000 0.500000 0.500000 0 15 0
( 944 16 128 ) ( 944 48 128 ) ( 976 48 128 ) common/origin 0.000000 0.000000 0.000000 0.500000 0.500000 0 15 0
( 944 16 32 ) ( 976 16 32 ) ( 976 16 0 ) common/origin 0.000000 0.000000 0.000000 0.500000 0.500000 0 15 0
( 976 16 32 ) ( 976 48 32 ) ( 976 48 0 ) common/origin 0.000000 0.000000 0.000000 0.500000 0.500000 0 15 0
( 976 48 32 ) ( 944 48 32 ) ( 944 48 0 ) common/origin 0.000000 0.000000 0.000000 0.500000 0.500000 0 15 0
( 944 48 32 ) ( 944 16 32 ) ( 944 16 0 ) common/origin 0.000000 0.000000 0.000000 0.500000 0.500000 0 15 0
}
// brush 2
{
( 760 88 -32 ) ( 696 88 -32 ) ( 696 56 -32 ) egypt_floor_sd/block-16sq 0.000000 64.000000 0.000000 0.500000 0.500000 0 0 0
( 688 56 0 ) ( 688 88 0 ) ( 752 88 0 ) egypt_floor_sd/block-16sq 0.000000 64.000000 0.000000 0.500000 0.500000 0 0 0
( 696 -32 184 ) ( 760 -32 184 ) ( 760 -32 24 ) egypt_floor_sd/block-16sq 0.000000 0.000000 0.000000 0.500000 0.500000 0 0 0
( 1024 56 184 ) ( 1024 88 184 ) ( 1024 88 24 ) egypt_floor_sd/block-16sq -64.000000 0.000000 0.000000 0.500000 0.500000 0 0 0
( 760 96 184 ) ( 696 96 184 ) ( 696 96 24 ) egypt_floor_sd/block-16sq 0.000000 0.000000 0.000000 0.500000 0.500000 0 0 0
( 896 88 184 ) ( 896 56 184 ) ( 896 56 24 ) egypt_floor_sd/block-16sq -64.000000 0.000000 0.000000 0.500000 0.500000 0 0 0
}
}
// entity 9
{
"scriptname" "random_block2"
"targetname" "random_block2"
"spawnflags" "2"
"classname" "script_mover"
// brush 0
{
( 760 344 0 ) ( 696 344 0 ) ( 696 312 0 ) seawall_wall/wall03_top 0.000000 64.000000 0.000000 0.500000 0.500000 0 0 0
( 688 312 64 ) ( 688 344 64 ) ( 752 344 64 ) rubble/debri_m01 0.000000 64.000000 0.000000 0.500000 0.500000 0 0 0
( 696 240 216 ) ( 760 240 216 ) ( 760 240 56 ) seawall_wall/wall03_top 0.000000 0.000000 0.000000 0.500000 0.500000 0 0 0
( 1008 312 216 ) ( 1008 344 216 ) ( 1008 344 56 ) seawall_wall/wall03_top -64.000000 0.000000 0.000000 0.500000 0.500000 0 0 0
( 760 336 216 ) ( 696 336 216 ) ( 696 336 56 ) seawall_wall/wall03_top 0.000000 0.000000 0.000000 0.500000 0.500000 0 0 0
( 912 344 216 ) ( 912 312 216 ) ( 912 312 56 ) seawall_wall/wall03_top -64.000000 0.000000 0.000000 0.500000 0.500000 0 0 0
}
// brush 1
{
( 944 304 32 ) ( 944 272 32 ) ( 944 272 0 ) common/origin 0.000000 0.000000 0.000000 0.500000 0.500000 0 15 0
( 976 304 32 ) ( 944 304 32 ) ( 944 304 0 ) common/origin 0.000000 0.000000 0.000000 0.500000 0.500000 0 15 0
( 976 272 32 ) ( 976 304 32 ) ( 976 304 0 ) common/origin 0.000000 0.000000 0.000000 0.500000 0.500000 0 15 0
( 944 272 32 ) ( 976 272 32 ) ( 976 272 0 ) common/origin 0.000000 0.000000 0.000000 0.500000 0.500000 0 15 0
( 944 272 128 ) ( 944 304 128 ) ( 976 304 128 ) common/origin 0.000000 0.000000 0.000000 0.500000 0.500000 0 15 0
( 976 304 -32 ) ( 944 304 -32 ) ( 944 272 -32 ) common/origin 0.000000 0.000000 0.000000 0.500000 0.500000 0 15 0
}
// brush 2
{
( 896 344 184 ) ( 896 312 184 ) ( 896 312 24 ) egypt_floor_sd/block-16sq -64.000000 0.000000 0.000000 0.500000 0.500000 0 0 0
( 760 352 184 ) ( 696 352 184 ) ( 696 352 24 ) egypt_floor_sd/block-16sq 0.000000 0.000000 0.000000 0.500000 0.500000 0 0 0
( 1024 312 184 ) ( 1024 344 184 ) ( 1024 344 24 ) egypt_floor_sd/block-16sq -64.000000 0.000000 0.000000 0.500000 0.500000 0 0 0
( 696 224 184 ) ( 760 224 184 ) ( 760 224 24 ) egypt_floor_sd/block-16sq 0.000000 0.000000 0.000000 0.500000 0.500000 0 0 0
( 688 312 0 ) ( 688 344 0 ) ( 752 344 0 ) egypt_floor_sd/block-16sq 0.000000 64.000000 0.000000 0.500000 0.500000 0 0 0
( 760 344 -32 ) ( 696 344 -32 ) ( 696 312 -32 ) egypt_floor_sd/block-16sq 0.000000 64.000000 0.000000 0.500000 0.500000 0 0 0
}
}
// entity 10
{
"scriptname" "random_block1"
"targetname" "random_block1"
"classname" "script_mover"
"spawnflags" "2"
// brush 0
{
( 912 568 216 ) ( 912 536 216 ) ( 912 536 56 ) seawall_wall/wall03_top 0.000000 0.000000 0.000000 0.500000 0.500000 0 0 0
( 760 560 216 ) ( 696 560 216 ) ( 696 560 56 ) seawall_wall/wall03_top 0.000000 0.000000 0.000000 0.500000 0.500000 0 0 0
( 1008 536 216 ) ( 1008 568 216 ) ( 1008 568 56 ) seawall_wall/wall03_top 0.000000 0.000000 0.000000 0.500000 0.500000 0 0 0
( 696 464 216 ) ( 760 464 216 ) ( 760 464 56 ) seawall_wall/wall03_top 0.000000 0.000000 0.000000 0.500000 0.500000 0 0 0
( 688 536 32 ) ( 688 568 32 ) ( 752 568 32 ) rubble/debri_m01 0.000000 0.000000 0.000000 0.500000 0.500000 0 0 0
( 760 568 0 ) ( 696 568 0 ) ( 696 536 0 ) seawall_wall/wall03_top 0.000000 0.000000 0.000000 0.500000 0.500000 0 0 0
}
// brush 1
{
( 976 528 -32 ) ( 944 528 -32 ) ( 944 496 -32 ) common/origin 0.000000 0.000000 0.000000 0.500000 0.500000 0 15 0
( 944 496 128 ) ( 944 528 128 ) ( 976 528 128 ) common/origin 0.000000 0.000000 0.000000 0.500000 0.500000 0 15 0
( 944 496 32 ) ( 976 496 32 ) ( 976 496 0 ) common/origin 0.000000 0.000000 0.000000 0.500000 0.500000 0 15 0
( 976 496 32 ) ( 976 528 32 ) ( 976 528 0 ) common/origin 0.000000 0.000000 0.000000 0.500000 0.500000 0 15 0
( 976 528 32 ) ( 944 528 32 ) ( 944 528 0 ) common/origin 0.000000 0.000000 0.000000 0.500000 0.500000 0 15 0
( 944 528 32 ) ( 944 496 32 ) ( 944 496 0 ) common/origin 0.000000 0.000000 0.000000 0.500000 0.500000 0 15 0
}
// brush 2
{
( 760 568 -32 ) ( 696 568 -32 ) ( 696 536 -32 ) egypt_floor_sd/block-16sq 0.000000 0.000000 0.000000 0.500000 0.500000 0 0 0
( 688 536 0 ) ( 688 568 0 ) ( 752 568 0 ) egypt_floor_sd/block-16sq 0.000000 0.000000 0.000000 0.500000 0.500000 0 0 0
( 696 448 184 ) ( 760 448 184 ) ( 760 448 24 ) egypt_floor_sd/block-16sq 0.000000 0.000000 0.000000 0.500000 0.500000 0 0 0
( 1024 536 184 ) ( 1024 568 184 ) ( 1024 568 24 ) egypt_floor_sd/block-16sq 0.000000 0.000000 0.000000 0.500000 0.500000 0 0 0
( 760 576 184 ) ( 696 576 184 ) ( 696 576 24 ) egypt_floor_sd/block-16sq 0.000000 0.000000 0.000000 0.500000 0.500000 0 0 0
( 896 568 184 ) ( 896 536 184 ) ( 896 536 24 ) egypt_floor_sd/block-16sq 0.000000 0.000000 0.000000 0.500000 0.500000 0 0 0
}
}

Script Option 1:


game_manager
{
	spawn
	{
	}
}

random_block1
{
	spawn
	{
		accum 0 set 0 //randomiser
		wait 50

		accum 0 random 2
		accum 0 abort_if_equal 1
		setstate random_block1 invisible
	}

}

random_block2
{
	spawn
	{
		accum 0 set 0 //randomiser
		wait 100

		accum 0 random 2
		accum 0 abort_if_equal 1
		setstate random_block2 invisible
	}

}

random_block3
{
	spawn
	{
		accum 0 set 0 //randomiser
		wait 150

		accum 0 random 2
		accum 0 abort_if_equal 1
		setstate random_block3 invisible
	}

}

random_block4
{
	spawn
	{
		accum 0 set 0 //randomiser
		wait 200

		accum 0 random 2
		accum 0 abort_if_equal 1
		setstate random_block4 invisible
	}

}

Script Option 2:


game_manager
{
	spawn
	{
		accum 0 set 0 //randomiser
		wait 50

		trigger game_manager randomiz0r
	}

	trigger randomiz0r
	{
		accum 0 random 2
		accum 0 trigger_if_equal 1 random_block1 off
		accum 0 random 2
		accum 0 trigger_if_equal 1 random_block2 off
		accum 0 random 2
		accum 0 trigger_if_equal 1 random_block3 off
		accum 0 random 2
		accum 0 trigger_if_equal 1 random_block4 off

	}
}

random_block1
{
	trigger off
	{
		setstate random_block1 invisible
	}

}

random_block2
{
	trigger off
	{
		setstate random_block2 invisible
	}

}

random_block3
{
	trigger off
	{
		setstate random_block3 invisible
	}

}

random_block4
{
	trigger off
	{
		setstate random_block4 invisible
	}

}

(Storm) #5

sock saves the day…

This sounds like a good idea, how about random fires caused by shelling!?

Imagine fires that you have to avoid insted of boxes to hide behind.

tricky stuff to line it up to mortor landings…


(Erik-Ftn) #6

It’s an unfortunate limitation of the system.

The 22 secs is the sum of the maximum delay time for the longest signal path through the system.

The only advantage of my system I can think of is that it can be used as a copy-paste prefab. (It’s target and targetnames should first prob. all be given some added unique startchars.) With that comes all its limitations.


For the interested: System explained.


Image: Yellow is delay, purple is timer, grey is trigger, blue is static.

  1. The basic function

Look at the bottom red boxed area labeled p(out)=50%

The timer fires every 4 seconds, the signal is delayed 3 secs and then 5 secs. After 4 secs the final delay recieves a new signal and is reset, thus it never releases its signal.

Timer(4) -> Delay (3) -> Delay (5)

Now, if you disturb the 3 sec delay in the middle, the 5 sec delay will eventually release its signal. For this to work there must be a signal “hanging” at the 5sec delay.

If you anlyse the chain you will find that an arbitrarily timed second signal to the 3sec delay only creates enough rest to the 5sec delay 50% of the time.

Such an arbitrary signal is created through the
Trigger_always -> Delay (8 +/- 4) ->

  1. The overall logic system

The system is made out of three such timer-> delay chains, all with the same key values as described above and the only difference beeing that the AND-gate in the middle has two delay3 paths. The two path - AND gate system requires both delay3’s to be blocked to release the signal hanging at the delay5. The disturbance signals to the AND gate is also different, consisting of timers (wait0.5) effectively blocking each delay3 with 100% probability if activated.

3 Creating four mutually exlusive outcomes out of two signals.

So I have 2 signals and want 4 different outcomes (ie always lighting only one of the four func_statics at the end).

What signals lights what func_statics?

3.1 No signal at all reaches the end.
Do nothing, first is already lit.

3.2 Only “upper” signal fires
Off the first, light the second

3.3 Only “lower” signal fires
Off the first, light the third

3.4 Both signals fires
All the triggering above have already happend, the system must now correct the result to reach the desired result: only fourth is lit.
Fire at all of them,
no1 recieves a total of 3 signals, and is off
no2 gets 2 signals, is now off
no3 gets 2 signals, is now off
no4 gets on signal and is on.

  1. Discussion

The system does work, but takes up to 22 secs to be still. Thats a long time. Players reaching the affected areas might see a blinking gameplay-area :(. As said in this thread, apperently there might be also be some shadow issues with it. Of course the logic part of the system has be placed outside gamplay areas not to be touched by players or it might trigger som blinking again. (lol - that would be something, an ingame randomly blinking WW2 battlefield. :frowning: )

I made this to learn how enteties work. Scripting seems cool though. Hmm… I still wonder if/ how you can script multiple simultaneous condition triggers though. I have built such a system also, and its much simpler. :slight_smile:

  1. Conlusion

Have fun - learn scripting, eventually. :slight_smile:

Erik


(G0-Gerbil) #7

Why not just have a target_relay with random flag set?
Start all your entities hidden, then a second or so into the level with a func_timer target a non-random relay that targets the random one (which in turn targets the random bits of scenery) and also targets the func_timer to turn it off?

Again, I’d recommend the scripting way, it’s a doddle, but using entities you could do it a lot simpler, unless I’ve misunderstood what you want the end result to be?


(Erik-Ftn) #8

Well, at: http://www.splashdamage.com/forums/viewtopic.php?t=4730

So, now after including the target_relay definition in my et_entities.def file, this system does the exact same thing in 1 sec.

trigger_always -> Delay (1) -> target_relay -> 4 st func_statics

thanks

That is really great. :clap: :drink:

Erik


(G0-Gerbil) #9

Heh not your fault they missed that entity - I’d forgotten about that meself :slight_smile:
Anyway you did the hard work - although I think you could probably have learnt scripting in the time it probably took you to come up with your first entity method!

Anyway, now there are plenty of easy ways, either scripting or entity - so everyone is better off as a result :clap: