Problem - script_mover must have a model -? it is a lift!


(DeAtHmAsTeR) #1

EDIT : read my problem at the bottom please (other reply) ! help me!


hey is it possible to create an elevator in et? i know it was possible in rtcw - can someone help me? basically - all i need is a trigger button which raises a platform.

can anyone help me with the scripting too please???


Sky High Radar map - which i am creating right now - is going under a huge change in the main building area - it is being converted to a cargo site so that i can create a campaign :). I am creating new textures and also have learnt a lot of new stuff :wink:

Beta test in 7 days - pm me to apply.


(Mlehliw) #2

In et I think your gonna have to use script movers instead of a func_button unless of course someone has got that to work. It’s no big deal though I have a couple script movers in my map and its not too hard to implement. On the other hand this might be kind of long and complicated so bear with.

First lets make your button with a script mover and an origin brush, call this something like elevator_btn or something like that. Then make two path corners where you want the button to go. Surround that with a func_inv_user trigger brush and target that at a target_script_trigger. In the target_script_trigger make a key/value of target/main, This is what function will be called in the script.

Then make your elevator a script mover with an origin brush. Put a couple path corners in for where you want the elevator to go.

For some good scripting examples please see the battery script. There are plenty of doors there which are activated by remote buttons. They function exactly the same as an elevator would.

Here is just some script I adopted from battery for my map.

garagedoor2_trigger  //this is the target_script_trigger entity
{
	spawn
	{
		accum 6 set 1
		wait 500
		trigger garagedoor2_trigger main
	}
	trigger main  //every time you activate the switch this function is called so make sure everything you want to happen is based off of whats going on here.
	{
		globalaccum 1 abort_if_not_equal 0
		trigger garagedoor2_trigger up
		trigger garagedoor2_trigger down

	}
	trigger up
	{
			accum 6 abort_if_not_equal 1
			resetscript

			trigger garagedoor2_lever up
			accum 6 set 0
	}
	trigger down
	{
			accum 6 abort_if_not_equal 0
			resetscript

			trigger garagedoor2_lever down
			accum 6 set 1
	}
}

garagedoor2_lever  //this is the script mover button that you made
{
	spawn
	{
	}
	trigger down
	{
		gotomarker garagedoor2_lever_down 16
		playsound sound/movers/switches/switch.wav
		trigger garagedoor2 close
		
	}
	trigger up
	{
		gotomarker garagedoor2_lever_up 16
		playsound sound/movers/switches/switch.wav
		trigger garagedoor2 open
		
	}
}

garagedoor2 //this would be your elevator entity
{
	spawn
	{
	}

	trigger open
	{
		wait 500
		playsound sound/movers/misc/garage_door_start_01.wav volume 127
		wait 350
		enablespeaker garagedoor2_sound
		gotomarker garagedoor2_pc1 17 wait
		disablespeaker garagedoor2_sound
		playsound sound/movers/misc/garage_door_end_01.wav volume 127
	}

	trigger close
	{
		wait 500
		playsound sound/movers/misc/garage_door_start_01.wav volume 127
		wait 350
		enablespeaker garagedoor2_sound
		gotomarker garagedoor2_pc2 17 wait
		disablespeaker garagedoor2_sound
		playsound sound/movers/misc/garage_door_end_01.wav volume 127
	}
}

Not really sure about what everything means in the script but it works for me so I’m happy. Hopefully it will help you out.


(bsimser) #3

See this link:
http://www.planetquake.com/simland/pages/wolftut/tut02_lift1.htm

Map works for ET. Just some of the entities and textures don’t exist but the principal is the same. I’ve compiled it in ET and it works.


(DeAtHmAsTeR) #4

i tried making an elevator, but it says

script_mover must have a “model”

and it wont let me load game

i am posting my script and entities

liftbutton //this is the scriptname of the target_script_trigger
{
	spawn
	{
	}
	trigger liftbutton_depot //this is the target of the target_script_trigger
	{
		trigger button move_in //calls the function button to move it
		trigger lift_depot move_back
		trigger lift_depot move_forward //the_mover is the scriptname of the mover
	}
}

button //scriptname of the button
{
	trigger move_in
	{
		gotomarker button_in 16 wait //16 is default speed, wait means wait until the button has stopped moving to continue with the script
	}
	trigger move_out
	{
		gotomarker button_out 16 wait
	}
}

lift_depot //scriptname of the mover
{
	spawn
	{
		accum 1 set 0 //0 means the mover is in starting positon, 1 means it is in the end position
	}
	trigger move_forward
	{
		accum 1 abort_if_not_equal 0 //only do this if the lift is in the start position
		gotomarker the_mover_forward 32 wait
		trigger button move_out
		accum 1 set 1 //set the mover to end position
	}
	trigger move_back
	{
		accum 1 abort_if_not_equal 1
		gotomarker the_mover_back 32 wait
		trigger button move_out
		accum 1 set 0 //set the mover to start position
	}
}

entities

// entity 421
{
"scriptname" "lift_depot"
"spawnflags" "2"
"classname" "script_mover"
// brush 0
{
( 968 3416 336 ) ( 936 3416 336 ) ( 936 3384 336 ) common/origin -16 0 0 0.500000 0.500000 0 15 0
( 936 3384 360 ) ( 936 3416 360 ) ( 968 3416 360 ) common/origin -16 0 0 0.500000 0.500000 0 15 0
( 936 3392 360 ) ( 968 3392 360 ) ( 968 3392 320 ) common/origin -16 -16 0 0.500000 0.500000 0 15 0
( 952 3384 360 ) ( 952 3416 360 ) ( 952 3416 320 ) common/origin 0 -16 0 0.500000 0.500000 0 15 0
( 968 3416 360 ) ( 936 3416 360 ) ( 936 3416 320 ) common/origin -16 -16 0 0.500000 0.500000 0 15 0
( 928 3416 360 ) ( 928 3384 360 ) ( 928 3384 320 ) common/origin 0 -16 0 0.500000 0.500000 0 15 0
}
}
// entity 422
{
"targetname" "position1"
"origin" "944 3400 344"
"classname" "path_corner"
}
// entity 423
{
"targetname" "position2"
"origin" "944 3400 816"
"classname" "path_corner"
}
// entity 424
{
"scriptname" "lift_depot"
"spawnflags" "2"
"classname" "script_mover"
// brush 0
{
( 946 3458 365 ) ( 946 3346 365 ) ( 946 3346 326 ) deathmasters_textures/metal-red-x-support -8 -10 0 0.500000 0.500000 0 0 0
( 1020 3333 334 ) ( 935 3333 334 ) ( 935 3333 295 ) deathmasters_textures/metal-red-x-support -96 -10 0 0.500000 0.500000 0 0 0
( 950 3316 334 ) ( 950 3428 334 ) ( 950 3428 295 ) deathmasters_textures/metal-red-x-support -8 -10 0 0.500000 0.500000 0 0 0
( 936 3288 334 ) ( 1021 3288 334 ) ( 1021 3288 295 ) deathmasters_textures/metal-red-x-support -96 -10 0 0.500000 0.500000 0 0 0
( 945 3346 334 ) ( 945 3458 334 ) ( 1030 3458 334 ) deathmasters_textures/metal-red-x-support -96 8 0 0.500000 0.500000 0 0 0
( 1030 3458 333 ) ( 945 3458 333 ) ( 945 3346 333 ) deathmasters_textures/metal-red-x-support -96 8 0 0.500000 0.500000 0 0 0
}
// brush 1
{
( 1014 3458 333 ) ( 929 3458 333 ) ( 929 3346 333 ) deathmasters_textures/metal-red-x-support -64 8 0 0.500000 0.500000 0 0 0
( 929 3346 334 ) ( 929 3458 334 ) ( 1014 3458 334 ) deathmasters_textures/metal-red-x-support -64 8 0 0.500000 0.500000 0 0 0
( 920 3288 334 ) ( 1005 3288 334 ) ( 1005 3288 295 ) deathmasters_textures/metal-red-x-support -64 -10 0 0.500000 0.500000 0 0 0
( 934 3316 334 ) ( 934 3428 334 ) ( 934 3428 295 ) deathmasters_textures/metal-red-x-support -8 -10 0 0.500000 0.500000 0 0 0
( 1004 3333 334 ) ( 919 3333 334 ) ( 919 3333 295 ) deathmasters_textures/metal-red-x-support -64 -10 0 0.500000 0.500000 0 0 0
( 930 3458 334 ) ( 930 3346 334 ) ( 930 3346 295 ) deathmasters_textures/metal-red-x-support -8 -10 0 0.500000 0.500000 0 0 0
}
// brush 2
{
( 915 3503 370 ) ( 915 3391 370 ) ( 915 3391 331 ) deathmasters_textures/metal-red-x-support -98 0 0 0.500000 0.500000 0 0 0
( 993 3456 339 ) ( 908 3456 339 ) ( 908 3456 300 ) deathmasters_textures/metal-red-x-support -38 0 0 0.500000 0.500000 0 0 0
( 965 3367 370 ) ( 965 3479 370 ) ( 965 3479 331 ) deathmasters_textures/metal-red-x-support -98 0 0 0.500000 0.500000 0 0 0
( 907 3333 339 ) ( 992 3333 339 ) ( 992 3333 300 ) deathmasters_textures/metal-red-x-support -38 0 0 0.500000 0.500000 0 0 0
( 916 3391 339 ) ( 916 3503 339 ) ( 1001 3503 339 ) deathmasters_textures/metal-red-x-support -38 98 0 0.500000 0.500000 0 0 0
( 1001 3503 338 ) ( 916 3503 338 ) ( 916 3391 338 ) deathmasters_textures/metal-red-x-support -38 98 0 0.500000 0.500000 0 0 0
}
// brush 3
{
( 726 3454 338 ) ( 641 3454 338 ) ( 641 3342 338 ) deathmasters_textures/metal-red-x-support 0 0 0 0.500000 0.500000 0 0 0
( 641 3342 339 ) ( 641 3454 339 ) ( 726 3454 339 ) deathmasters_textures/metal-red-x-support 0 0 0 0.500000 0.500000 0 0 0
( 631 3281 339 ) ( 716 3281 339 ) ( 716 3281 300 ) deathmasters_textures/metal-red-x-support 0 0 0 0.500000 0.500000 0 0 0
( 915 3348 370 ) ( 915 3460 370 ) ( 915 3460 331 ) deathmasters_textures/metal-red-x-support 0 0 0 0.500000 0.500000 0 0 0
( 726 3456 339 ) ( 641 3456 339 ) ( 641 3456 300 ) deathmasters_textures/metal-red-x-support 0 0 0 0.500000 0.500000 0 0 0
( 640 3454 339 ) ( 640 3342 339 ) ( 640 3342 300 ) deathmasters_textures/metal-red-x-support 0 0 0 0.500000 0.500000 0 0 0
}
// brush 4
{
( 1046 3503 338 ) ( 961 3503 338 ) ( 961 3391 338 ) deathmasters_textures/metal-red-x-support -128 98 0 0.500000 0.500000 0 0 0
( 961 3391 339 ) ( 961 3503 339 ) ( 1046 3503 339 ) deathmasters_textures/metal-red-x-support -128 98 0 0.500000 0.500000 0 0 0
( 942 3281 339 ) ( 1027 3281 339 ) ( 1027 3281 300 ) deathmasters_textures/metal-red-x-support -128 0 0 0.500000 0.500000 0 0 0
( 1280 3385 339 ) ( 1280 3497 339 ) ( 1280 3497 300 ) deathmasters_textures/metal-red-x-support -98 0 0 0.500000 0.500000 0 0 0
( 1038 3456 339 ) ( 953 3456 339 ) ( 953 3456 300 ) deathmasters_textures/metal-red-x-support -128 0 0 0.500000 0.500000 0 0 0
( 965 3505 370 ) ( 965 3393 370 ) ( 965 3393 331 ) deathmasters_textures/metal-red-x-support -98 0 0 0.500000 0.500000 0 0 0
}
// brush 5
{
( 1448 3456 342 ) ( 1448 3456 310 ) ( 1456 3456 310 ) deathmasters_textures/metal-red-x-support 0 0 0 0.500000 0.500000 134217728 0 0
( 1329 3329 346 ) ( 1448 3448 346 ) ( 1448 3448 306 ) deathmasters_textures/metal-red-x-support 0 0 0 0.500000 0.500000 134217728 0 0
( 1280 3456 310 ) ( 1280 3456 342 ) ( 1280 3280 342 ) deathmasters_textures/metal-red-x-support 0 0 0 0.500000 0.500000 134217728 0 0
( 1207 3452 339 ) ( 1326 3571 339 ) ( 1448 3448 339 ) deathmasters_textures/metal-red-x-support 0 0 0 0.500000 0.500000 134217728 0 0
( 1448 3448 338 ) ( 1326 3571 338 ) ( 1207 3452 338 ) deathmasters_textures/metal-red-x-support 0 0 0 0.500000 0.500000 134217728 0 0
}
}
// entity 425
{
"spawnflags" "2"
"scriptname" "button"
"classname" "script_mover"
// brush 0
{
( 1333 3292 886 ) ( 1333 3285 886 ) ( 1333 3285 856 ) metal_misc/ametal_m03 8 6 0 0.500000 0.500000 0 0 0
( 1343 3292 886 ) ( 1333 3292 886 ) ( 1333 3292 856 ) lights/light_m1r -22 2 0 -0.312500 0.281250 0 0 0
( 1343 3285 886 ) ( 1343 3292 886 ) ( 1343 3292 856 ) metal_misc/ametal_m03 8 6 0 0.500000 0.500000 0 0 0
( 1333 3285 886 ) ( 1343 3285 886 ) ( 1343 3285 856 ) metal_misc/ametal_m03 80 6 0 0.500000 0.500000 0 0 0
( 1333 3285 865 ) ( 1333 3292 865 ) ( 1343 3292 865 ) metal_misc/ametal_m03 80 -8 0 0.500000 0.500000 0 0 0
( 1343 3292 856 ) ( 1333 3292 856 ) ( 1333 3285 856 ) metal_misc/ametal_m03 80 -8 0 0.500000 0.500000 0 0 0
}
// brush 1
{
( 1325 3293 892 ) ( 1325 3284 892 ) ( 1325 3284 826 ) metal_misc/ametal_m03 8 74 0 0.500000 0.500000 0 0 0
( 1352 3301 892 ) ( 1326 3301 892 ) ( 1326 3301 826 ) xlab_props/xradio_c02 -5 -59 0 -0.203125 0.234375 0 0 0
( 1351 3284 892 ) ( 1351 3293 892 ) ( 1351 3293 826 ) metal_misc/ametal_m03 8 74 0 0.500000 0.500000 0 0 0
( 1325 3284 892 ) ( 1351 3284 892 ) ( 1351 3284 826 ) metal_misc/ametal_m03 80 74 0 0.500000 0.500000 0 0 0
( 1325 3284 856 ) ( 1325 3293 856 ) ( 1351 3293 856 ) metal_misc/ametal_m03 80 -8 0 0.500000 0.500000 0 0 0
( 1351 3293 826 ) ( 1325 3293 826 ) ( 1325 3284 826 ) metal_misc/ametal_m03 80 -8 0 0.500000 0.500000 0 0 0
}
}
// entity 426
{
"cursorhint" "hint_button"
"target" "t777"
"classname" "func_invisible_user"
// brush 0
{
( 1366 3318 816 ) ( 1313 3318 816 ) ( 1313 3280 816 ) common/trigger 0 0 0 0.500000 0.500000 0 7 0
( 1313 3280 865 ) ( 1313 3318 865 ) ( 1366 3318 865 ) common/trigger 0 0 0 0.500000 0.500000 0 7 0
( 1313 3280 865 ) ( 1366 3280 865 ) ( 1366 3280 856 ) common/trigger 0 0 0 0.500000 0.500000 0 7 0
( 1370 3281 865 ) ( 1370 3319 865 ) ( 1370 3319 856 ) common/trigger 0 0 0 0.500000 0.500000 0 7 0
( 1366 3325 865 ) ( 1313 3325 865 ) ( 1313 3325 856 ) common/trigger 0 0 0 0.500000 0.500000 0 7 0
( 1307 3318 865 ) ( 1307 3280 865 ) ( 1307 3280 856 ) common/trigger 0 0 0 0.500000 0.500000 0 7 0
}
}
// entity 427
{
"scriptname" "liftbutton"
"target" "liftbutton_depot"
"targetname" "t777"
"origin" "1334 3358 840"
"classname" "target_script_trigger"
}

PLease help


(kat) #5

All script_movers need an origin brush, based on what you’ve posted only the ‘1st’ one has because that’s all it is. You’ve also got 2 script_movers using the same scriptname (which may be fine depending on what they’re doing) if they’re actually the same objcet you may need to re-group them. Add an origin brush to the script_mover button


(DeAtHmAsTeR) #6

i added an origin brush to the button - i stil cant get it to work.


(BroQ) #7

Try to select both your object that you want to move + your origin brush
then chose script_mover (with both selected) then (still with both selected) press N en change whatever you want to change… then it will work and ET wont give the error message


(DeAtHmAsTeR) #8

I HAVE!!! thats exactly what i did - and it would work

does anyone have any check list thing that i can use to for makin a scriptmover,