datablock itemData(decollideItem)
{
category = "";
className = "";
shapeFile = "base/data/shapes/empty.dts";
mass = 1;
density = 1;
elasticity = 1;
friction = 1;
emap = true;
uiName = "Decollide";
iconName = "";
doColorShift = true;
colorShiftColor = "1 1 1 1";
canDrop = true;
};
function decollideItem::onPickup(%this)
{
return;
}
function decollideItem::onAdd(%this, %item)
{
Parent::onAdd(%this,%item);
schedule(100,0,decolcheck,%item,0);
}
function decollideItem::onRemove(%this, %item)
{
Parent::onAdd(%this,%item);
schedule(100,0,decolcheck,%item,1);
}
function decolcheck(%item,%on)
{
%item.spawnbrick.setColliding(%on);
}
Why are you setting colliding to "True" as the item is spawned? Wouldn't it work better if it was made not colliding as you spawn a "Decollide"?