Is there anything at the level of
if (chicken[x].destroyed) {
do y
};
to check if the object is destroyed.
the Destroy(chicken[Γ]) script occurs on another script.
thx.
Is there anything at the level of
if (chicken[x].destroyed) {
do y
};
to check if the object is destroyed.
the Destroy(chicken[Γ]) script occurs on another script.
thx.
Check if itβs null, ie.
if (chicken[x] != null) {
//do something if the chicken still exists
}
else
{
//mourn chicken.
}
Hope that helps!
And the shortcut is:
if (chicken[x])
Slaughter(chicken[x]);
else
FeelRegret();
Lawl. //mourn chicken.
Thx for the tips!