Code: Select all
Enemy.h
#ifndef Enemy_h
#define Enemy_h
class Enemy {
irr::scene::IAnimatedMeshSceneNode Node;
public:
void setNode (irr::scene::IAnimatedMeshSceneNode *node);
irr::scene::IAnimatedMeshSceneNode getNode(void);
};
#endif
Enemy.cpp
#include "Enemy.h"
void Enemy::setNode(irr::scene::IAnimatedMeshSceneNode *node)
{
Node = node;
}
irr::scene::IAnimatedMeshSceneNode Enemy::getNode(void)
{
return Node;
}
Main.cpp
#include <irrlicht.h>
#include <windows.h>
#include <irrKlang.h>
#include <stdlib.h>
#include <time.h>
#include "Enemy.h"
#pragma comment(lib, "irrKlang.lib")
#pragma comment(lib, "Irrlicht.lib")
using namespace irr;
using namespace audio;
And also, should i return *IAnimatedMeshSceneNode or just IAnimatedMeshSceneNode?