Code tweak

This commit is contained in:
Kayne Ruse
2014-12-01 22:59:26 +11:00
parent cc167180f6
commit f50406d69f
5 changed files with 61 additions and 12 deletions
+32
View File
@@ -21,6 +21,10 @@
*/
#include "base_character.hpp"
//-------------------------
//graphics
//-------------------------
void BaseCharacter::CorrectSprite() {
//NOTE: These must correspond to the sprite sheet in use
if (motion.y > 0) {
@@ -45,3 +49,31 @@ void BaseCharacter::CorrectSprite() {
sprite.SetXIndex(0);
}
}
//-------------------------
//metadata
//-------------------------
int BaseCharacter::SetOwner(int i) {
return owner = i;
}
int BaseCharacter::GetOwner() {
return owner;
}
std::string BaseCharacter::SetHandle(std::string s) {
return handle = s;
}
std::string BaseCharacter::GetHandle() const {
return handle;
}
std::string BaseCharacter::SetAvatar(std::string s) {
return avatar = s;
}
std::string BaseCharacter::GetAvatar() const {
return avatar;
}