Creating a rotating portalgun: Difference between revisions
Darthkillyou (talk | contribs) (Quite a bit of cleanup) |
Darthkillyou (talk | contribs) m (removed linebreak) |
||
Line 6: | Line 6: | ||
==Prepare models == | ==Prepare models == | ||
You will need: | You will need:<br> | ||
*prop_dynamic, world model: <code>models/props/pedestal_base_reference.mdl</code>, name: <code>stand_bottom_model</code> Set the "disableshadows" keyvalue to 1.<br><br> | *prop_dynamic, world model: <code>models/props/pedestal_base_reference.mdl</code>, name: <code>stand_bottom_model</code> Set the "disableshadows" keyvalue to 1.<br><br> |
Revision as of 16:14, 16 January 2008
Introduction
So, we are going to create rotating stand with portalgun shooting portals.
An example map is available for download here.
Prepare models
You will need:
- prop_dynamic, world model:
models/props/pedestal_base_reference.mdl
, name:stand_bottom_model
Set the "disableshadows" keyvalue to 1. - prop_dynamic, world model:
models/props/pedestal_center_reference.mdl
, name:stand_top_model
Prepare brushes
Create:
- 32 x 32 block, height 4, using the
tools/nodraw
texture.
- 4 x 32 block, height 55, also using the
nodraw
texture.
Moving
Move stand_bottom_model
where you want to have the stand. The small doors on the bottom of the model need to be just underground.
Now move stand_top_model
above stand_bottom_model
as in the illustration.
Center the first brush that measured 32x32 with stand_top_model
. Set its Z axis (height) to about half of stand_top_model
.
Now move the second brush as it is in the picture.
Brush Entities
Select the 32x32 brush and tie it to a func_rotating
entity.
Property Name Value Name stand_func_rotating Max Rotation Speed 30
Under the Flags tab, uncheck Start ON.
Tie the second brush to a func_door
.
Property Name Value Name stand_func_door Speed 25 Move direction: 90 0 0
PortalGun
Create a new entity, a weapon_portalgun
and name it weapon_portalgun
.
Move it exactly on top of stand_top_model
. The portalgun should face left when you’re looking at stand_top_model
in the direction of the blue display.
Logic
Make entity logic_timer
named timer_stand and set interval to 5 sec. Make sure that initial state is on.
Now go to outputs and write:
Create a new output:
Now, we will make outputs of stand_bottom_model
:
And few outputs for weapon_portalgun
:
Parents and the Hole
Now, just set parent of weapon_portalgun
and stand_top_model
to stand_func_rotating
.
When your done, make hole under stand_bottom_model
s overground part.
End
You may create prop_static with model of models/props/autoportal_frame/autoportal_frame.mdl
for framing autofired portals, just move them to wall and rotate.