News | Forum | People | FAQ | Links | Search | Register | Log in
Teaching Old Progs.dat New Tricks.
You know about the info_notnull explosion hack. You know about making monsters drop weapons or alternate ammo using the .weapon and .ammo_whatever hacks. You know about making items float in the air by spawning them on a temporary platform. Let's have a thread where we talk about new ways to use existing behavior and get novel gameplay. If you're a "retired" mapper, this is a great time to do some armchair level design and suggest ideas you'll never have a chance to use yourself.
First | Previous | Next | Last
Objects That Selectivly Clip 
We're going to learn a new field we can add to almost any entity to change how it blocks other entities in the game. And that field is

owner n

Where n is the number of the entity that you want to "own" this entity. What does this mean? Well, it's easiest to understand by example. When an monster/player fires a projectile, the owner field of the projectile is set to the firing entity. This means that the two object will no longer clip or touch, they ignore each other for all collision purposes. The purpose is so that your own rockets don't explode on you as soon as you fire. Side effects include that you can't use a vore's own voreballs against it(directly).

So, what can we do with this? Well, you can set it on almost anything(doors being the big exception that already have owner specified in their own code). If you set, say, a monster's owner to 1, then it'll be noclip to the player. Kinda stupid, but cute, especially if you do it to a knight as it leaves them incapable of attacking you. You can't hit them with hitscan weapons, but you can get them with nails. This is because a traceline is in some ways a collision between yourself and the target entity.

So that's neat but not all that useful. A better use would be to have monsterclip that only clips selected monsters, like I suggested in mapping help. But surely you can only set the monsterclip to have one entity as it's owner? Yes, but that's the wrong way round to do it. What you do is make it so that all of the monsters you don't want to clip against it have the monster's owner set to the monsterclip. It's a symmetric relationship, so now all those monsters will disregard that one entity. Of course, they'll still hit all the other monsterclips in the map equally. You'll have to place them so that all the monsterclip they are likely to encounter that you want them to ignore is grouped as one entity.

The owner field might suggest that there's some kind of hierarchy going on here, but it's not the case. If the ogre has the player as an owner, and it's grenades have the ogre as their owner, the grenades still clip against the player. So you're basically limited to one link per object, it can be noclip to one entity of it's choice, and as many entities as you like can be noclip to it. The trick is to use the limited resource as creatively as possible.

What else could you do with this? Well, probably some good(evil) traps, shame this wasn't about for the speedmap pack last week. You could add HL2 style combine force fields that the player can't move through but the monsters can. I'm sure other people can think of things I can't. Maybe you could do something really clever for a coop only map, where player 1 and player 2 (entity 1 and entity 2 on the map) aren't treated symmetrically? It'd be cool to hear people's ideas. 
First | Previous | Next | Last
You must be logged in to post in this thread.
Website copyright © 2002-2024 John Fitzgibbons. All posts are copyright their respective authors.