or even gen-y.Not even chatgpt will help you with using such an outdated piece of software. 0.3.6 is literally as old as most of gen z... stop using old software and expecting support for it.
void Creature::dropCorpse(DeathList deathList) {
Monster* monster = this->getMonster();
if (monster && monster->getMaster()) {
return;
}
Player* player = this->getPlayer();
if (player && player->getSummonCount() > 0) {
return;
}
or even gen-y.Not even chatgpt will help you with using such an outdated piece of software. 0.3.6 is literally as old as most of gen z... stop using old software and expecting support for it.
void Creature::dropCorpse(DeathList deathList) {
Monster* monster = this->getMonster();
if (monster && monster->getMaster()) {
return;
}
Player* player = this->getPlayer();
if (player && player->getSummonCount() > 0) {
return;
}
I did this with the help of chatgpt, the body of the summoned creature disappeared, but there was an error in the district about this "creature" function. and when the creature that has the script tag dies, the body disappears.or even gen-y.
solution:
creature.cpp
under:
C++:void Creature::dropCorpse(DeathList deathList) {
add:
C++:Monster* monster = this->getMonster(); if (monster && monster->getMaster()) { return; }
and for player to prevent dop the corpse if he had summons (?? i think from request)
under our new code
C++:Player* player = this->getPlayer(); if (player && player->getSummonCount() > 0) { return; }
btw @Codinablack is absolutely right, 0.3.6 its very out of date and not beginner friendly, consider change you'r tfs to 1.x, way easier to help, way easier to learn, way easier to write systems/functions/scripts whatever we call it
function onDeath(creature, corpse, killer, mostDamageKiller)
if creature:isSummon() then
if corpse then
corpse:remove() --
end
end
return true
end