It's impossible to destroy Titanium/Uranium Ores by crashing with that objects #635
Labels
Milestone
Comments
|
According to the code, it should be possible, you just have to hit them hard enough: if (pObj->Implements(ObjectInterfaceType::Fragile))
{
// TODO: CFragileObject::GetDestructionForce (I can't do this now because you can't inherit both in COldObject ~krzys_h)
DamageType damageType = DamageType::Collision;
float destructionForce = 50.0f; // Titanium, PowerCell, NuclearCell, default
if (pObj->GetType() == OBJECT_STONE ) { destructionForce = 25.0f; } // TitaniumOre
if (pObj->GetType() == OBJECT_URANIUM ) { destructionForce = 25.0f; } // UraniumOre
if (pObj->GetType() == OBJECT_MOBILEtg) { destructionForce = 10.0f; damageType = DamageType::Explosive; } // TargetBot
if (pObj->GetType() == OBJECT_TNT ) { destructionForce = 10.0f; damageType = DamageType::Explosive; } // TNT
if (pObj->GetType() == OBJECT_BOMB ) { destructionForce = 0.0f; damageType = DamageType::Explosive; } // Mine
if ( force > destructionForce )
{
dynamic_cast<CDamageableObject*>(pObj)->DamageObject(damageType);
}
} |
|
That's strange, in official 0.1.6 builds that doesn't work. |
|
I've just killed a bot, and Titanium was still "alive", even after some hits by Me. How much is bots destructionForce? |
force = fabs(m_linMotion.realSpeed.x);
force *= crashSphere.hardness*2.0f;Note that I'm not saying that it works for me because I'm terrible at aiming at such a small object :P |
|
Also note that on collision the robot gets 1/200th of the force variable applied as damage (assuming damage is in range from 0 to 1/magnifyDamage) |
krzys-h
added a commit
that referenced
this issue
Feb 13, 2016
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
In previous GOLD and official Colobot versions you could destroy that objects by landing on them violently.
I propose that also Titanium, PowerCell, NuclearCell and OrgaMatter should can be destroyed in that way. KeyA..D and BlackBox should stay indestructible. TNT is also good as it is now.
The text was updated successfully, but these errors were encountered: