Catch SendFailedException when replying back in Connection::Receive()
[oweals/minetest.git] / src / serverobject.h
index c008bf93eebfa24e5a042518e3f910f5481c26d7..cbb50949cf8a4ff0064098fd03cbed5d98d47245 100644 (file)
@@ -42,6 +42,7 @@ Some planning
 
 class ServerEnvironment;
 class InventoryItem;
+class Player;
 
 class ServerActiveObject : public ActiveObject
 {
@@ -103,8 +104,15 @@ public:
                If the object doesn't return an item, this will be called.
                Return value is tool wear.
        */
-       virtual u16 punch(const std::string &toolname, v3f dir)
+       virtual u16 punch(const std::string &toolname, v3f dir,
+                       const std::string &playername)
        {return 0;}
+
+       /*
+       */
+       virtual void rightClick(Player *player){}
+
+       virtual bool isPeaceful(){return true;}
        
        /*
                Number of players which know about this object. Object won't be