02-25-2016, 03:03 AM
Hi.
I wrote this to make the ladder item (the one that u pick up) to interact with an Area (LadderArea) to make appear the static item lader (LadderJoint). But for some reason... i cant make the item interacts with the area... its like the area wasnt there for interact.
(info for the script below; "LladerItem" the pickup ladder / "LadderArea" its an Area where the pickup ladder will interact / and LadderJoint and ClimbArea is the two items that will apear to let me go up.
Dont know whats my mistake.
I make the Area where the ladder interacts TO huge to make it sure to find it yet nothing... or that makes it even worst?
void OnStart()
{
AddEntityCollideCallback ("LadderItem", "LadderArea", "PutLadderToClimb", true, 1);
}
void PutLadderToClimb (string &in asParent, string &in asChild, int alState)
{
PlaySoundAtEntity("", "05_attach_ladder.snt", "LadderArea", 0, false);
RemoveItem("LadderItem");
SetEntityActive("LadderJoint", true);
SetEntityActive("ClimbArea", true);
}
I wrote this to make the ladder item (the one that u pick up) to interact with an Area (LadderArea) to make appear the static item lader (LadderJoint). But for some reason... i cant make the item interacts with the area... its like the area wasnt there for interact.
(info for the script below; "LladerItem" the pickup ladder / "LadderArea" its an Area where the pickup ladder will interact / and LadderJoint and ClimbArea is the two items that will apear to let me go up.
Dont know whats my mistake.
I make the Area where the ladder interacts TO huge to make it sure to find it yet nothing... or that makes it even worst?
void OnStart()
{
AddEntityCollideCallback ("LadderItem", "LadderArea", "PutLadderToClimb", true, 1);
}
void PutLadderToClimb (string &in asParent, string &in asChild, int alState)
{
PlaySoundAtEntity("", "05_attach_ladder.snt", "LadderArea", 0, false);
RemoveItem("LadderItem");
SetEntityActive("LadderJoint", true);
SetEntityActive("ClimbArea", true);
}