Changeset 6e66ffd in network-game for common/WorldMap.h


Ignore:
Timestamp:
May 21, 2013, 10:00:54 PM (12 years ago)
Author:
dportnoy <dmp1488@…>
Branches:
master
Children:
5f868c0
Parents:
cc1c6c1
Message:

Add functions to the WorldMap class to allow the server to notify clients of object creation and movement

File:
1 edited

Legend:

Unmodified
Added
Removed
  • common/WorldMap.h

    rcc1c6c1 r6e66ffd  
    3333   class Object {
    3434   public:
     35      int id;
    3536      ObjectType type;
    3637      POSITION pos;
    3738
    38       Object(ObjectType type, int x, int y);
    39       Object(ObjectType type, POSITION pos);
     39      Object(ObjectType type, int id, int x, int y);
     40      Object(ObjectType type, int id, POSITION pos);
    4041
    4142      ~Object();
     
    5859
    5960   vector<Object> getObjects(int x, int y);
    60    void addObject(int x, int y, ObjectType type);
     61   void addObject(ObjectType type, int x, int y);
     62   void updateObject(int id, WorldMap::ObjectType t, int x, int y);
    6163
    6264   static WorldMap* createDefaultMap();
Note: See TracChangeset for help on using the changeset viewer.