12-23-2013, 05:25 AM
12-23-2013, 05:55 AM
I don't understand? Can you kinda give me some insight on this? I certainly can't make a script with just "3 rods".
12-23-2013, 06:30 AM
I mean the rod puzzle. The 3 rods must be put in a hole just like from machine room in ATDD.
I need to know this kind of script.
I need to know this kind of script.
12-23-2013, 07:07 AM
Oh. So if the three rods is inserted something happens? I assume that's the case.
//Rods_* are the rods
//TouchArea_* are the script areas. They must be put where the holes are.
void OnStart()
{
for(int = b; b == 3; b++) AddEntityCollideCallback("Rods_*", "TouchArea_*", "RodsInsert", true, 1);
SetLocalVarInt("Rods", 0);
}
void RodsInsert(string &in asParent, string &in asChild, int alState)
{
AddLocalVarInt("Rods", 1);
RodsCheck();
}
void RodsCheck()
{
if(GetLocalVarInt("Rods") == 3)
{
//...Do something...//
}
else if(GetLocalVarInt("Rods") < 3)
{
}
}
Spoiler below!
//Rods_* are the rods
//TouchArea_* are the script areas. They must be put where the holes are.
void OnStart()
{
for(int = b; b == 3; b++) AddEntityCollideCallback("Rods_*", "TouchArea_*", "RodsInsert", true, 1);
SetLocalVarInt("Rods", 0);
}
void RodsInsert(string &in asParent, string &in asChild, int alState)
{
AddLocalVarInt("Rods", 1);
RodsCheck();
}
void RodsCheck()
{
if(GetLocalVarInt("Rods") == 3)
{
//...Do something...//
}
else if(GetLocalVarInt("Rods") < 3)
{
}
}
12-23-2013, 07:59 AM
You right. 3 rods must be put in the case.
My question is did you know how to script on it?
My question is did you know how to script on it?
12-23-2013, 08:49 AM
What JustAnotherPlayer put in the Spoiler is the appropriate script for it. However in the part where it says //...Do something...//, you code what you want to happen, like, a door somewhere else opens, or something turns on, etc.
12-23-2013, 09:02 AM
ok i got your point. So i will try it.