RE: 3 Questions: Cave In and Destroying bookshelf
I myself haven't found a good way, but here is 1 that is..acceptable:
place the full armor somewhere, and place a head(a single head) inside the head of the full armor, but in such a way that it looks like 1.
tick Static physics at both the head and the complete.
then, use this:
inside OnStart or where ever you want:
SetEntityPlayerInteractCallback("armour_nice_head_1", "DoSomeRandom", true);
void DoSomeRandom(string &in asEntity)
{
SetPropStaticPhysics("armour_nice_head_1", false);
SetEntityActive("armour_nice_head_1", false);
SetPropStaticPhysics("armour_nice_complete_1", false);
AddPropForce("armour_nice_complete_1", 0, 100, 200, "world");
}
This basically only allows the pick up for the head, which becomes non-static and removed, the armor becomes non-static and you add some small prop force so the head pops out and on the ground(without that pop out effect, it just doesn't look right.)
The stuff to happen will get inside that function, too.
Of course there are other ways:
Another way would be to place 4 script areas around the head of the complete armor, and use a Entity Collide Callback to happen when the complete suit touches any script area. A bit tricky to do, but it might work better than the above example(what ever fits you more).
Maybe there is another way to alter the user variables of the complete armor in the model editor, or altering the armor some other way in the model editor. No idea on that though.
Think, before you speak Google, before you post
|