1
0
Fork 0
mirror of https://github.com/luanti-org/luanti.git synced 2025-06-27 16:36:03 +00:00

Add support for entities to automatic face movement direction

This commit is contained in:
sapier 2013-07-31 17:29:25 +02:00 committed by PilzAdam
parent d718b0b34e
commit fc571ad46d
7 changed files with 18 additions and 1 deletions

View file

@ -40,7 +40,8 @@ ObjectProperties::ObjectProperties():
is_visible(true),
makes_footstep_sound(false),
automatic_rotate(0),
stepheight(0)
stepheight(0),
automatic_face_movement_dir(false)
{
textures.push_back("unknown_object.png");
colors.push_back(video::SColor(255,255,255,255));
@ -102,6 +103,7 @@ void ObjectProperties::serialize(std::ostream &os) const
}
writeU8(os, collideWithObjects);
writeF1000(os,stepheight);
writeU8(os, automatic_face_movement_dir);
// Add stuff only at the bottom.
// Never remove anything, because we don't want new versions of this
}
@ -136,6 +138,7 @@ void ObjectProperties::deSerialize(std::istream &is)
}
collideWithObjects = readU8(is);
stepheight = readF1000(is);
automatic_face_movement_dir = readU8(is);
}catch(SerializationError &e){}
}
else