Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

source: orxonox.OLD/orxonox/trunk/core/npc.cc @ 1925

Last change on this file since 1925 was 1904, checked in by patrick, 21 years ago

blitz article

File size: 1.0 KB
Line 
1
2
3/*
4   orxonox - the future of 3D-vertical-scrollers
5
6   Copyright (C) 2004 orx
7
8   This program is free software; you can redistribute it and/or modify
9   it under the terms of the GNU General Public License as published by
10   the Free Software Foundation; either version 2, or (at your option)
11   any later version.
12
13   ### File Specific:
14   main-programmer: Patrick Boenzli
15   co-programmer:
16*/
17
18
19#include "npc.h"
20
21#include <iostream>
22
23
24using namespace std;
25
26
27NPC::NPC () {}
28
29NPC::~NPC () {}
30
31
32void NPC::setPosition(float x, float y, float z)
33{
34  xCor = x; yCor = y; zCor = z;
35}
36
37void NPC::getPosition(float* x, float* y, float* z) 
38{
39  *x = xCor; 
40  *y = yCor; 
41  *z = zCor;
42}
43
44void NPC::setCollisionRadius(float r) 
45{
46  collisionRadius = r;
47}
48
49float NPC::getCollisionRadius() 
50{
51  return collisionRadius;
52}
53
54
55void NPC::addAI(AI* ai)
56{
57
58}
59
60
61void NPC::drawNPC(void) 
62{
63  glPushMatrix();
64  glTranslatef(xCor, yCor, 3.0);
65  //glScalef(1.0, 3.0, 1.0);
66  glutWireSphere(1.0, 10, 10);
67  glPopMatrix();
68  //cout << "Player::drawNPC()" << endl;
69}
Note: See TracBrowser for help on using the repository browser.