Frictional Games Forum (read-only)

Full Version: Armour helmet
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Is it possible to remove the helmet on an armour via a script? Like there is an armour in the room, then I pick up a key and the helmet disappears?
Code:
void OnStart()
{
    SetEntityCallbackFunc("KEYNAME", "HelmetDissapear");
}

void HelmetDissapear(string &in asEntity, string &in type)
{
        SetEntityActive("HELMETNAME", false);
}
Change KEYNAME to whatever your key name is and HELMETNAME to whatever your helmet's name on the armor.
NOTE: THE HELMET AND THE ARMOR HAS TO BE A SEPERATE ENTITY!
(03-25-2013, 01:55 PM)JustAnotherPlayer Wrote: [ -> ]
Code:
void OnStart()
{
    SetEntityCallbackFunc("KEYNAME", "HelmetDissapear");
}

void HelmetDissapear(string &in asEntity, string &in type)
{
        SetEntityActive("HELMETNAME", false);
}
Change KEYNAME to whatever your key name is and HELMETNAME to whatever your helmet's name on the armor.
NOTE: THE HELMET AND THE ARMOR HAS TO BE A SEPERATE ENTITY!

But the helmet and armour are the same entity. There is no complete armour without a helmet in the editor.
(03-25-2013, 02:07 PM)Storfigge Wrote: [ -> ]
(03-25-2013, 01:55 PM)JustAnotherPlayer Wrote: [ -> ]
Code:
void OnStart()
{
    SetEntityCallbackFunc("KEYNAME", "HelmetDissapear");
}

void HelmetDissapear(string &in asEntity, string &in type)
{
        SetEntityActive("HELMETNAME", false);
}
Change KEYNAME to whatever your key name is and HELMETNAME to whatever your helmet's name on the armor.
NOTE: THE HELMET AND THE ARMOR HAS TO BE A SEPERATE ENTITY!

But the helmet and armour are the same entity. There is no complete armour without a helmet in the editor.
Yeah but, there are parts for it. There's the breast plate, the glove, boot and the head. Just arrange them. Check the Static Physics box at all parts except the head. This keeps it from falling.

Hey, dude. So i made an armor out of the pieces and....
[Image: z4i6e.jpg]

NOT BAD.