Esempio n. 1
0
 // I wish I was smart enough to not need this function :(
 protected static String Command2String(MugicCommand c)
 {
     switch (c)
     {
         case MugicCommand.Rectangle: return "rectangle";
         case MugicCommand.Circle   : return "circle";
         case MugicCommand.Line     : return "line";
         case MugicCommand.Update   : return "update";
         default                    : return "ERROR";
     }
 }
Esempio n. 2
0
 protected void InitPacket(MugicCommand s, MugicPacket p)
 {
     if (!wasCreated)
     {
         objectId = MugicObjectManager.NextId;
         p.Command(s, objectId);
         wasCreated = true;
     }
     else
     {
         p.Command(MugicCommand.Update, objectId);
     }
 }
Esempio n. 3
0
 protected void InitPacket(MugicCommand s, MugicPacket p)
 {
     if (!wasCreated)
     {
         objectId = MugicObjectManager.NextId;
         p.Command(s, objectId);
         wasCreated = true;
     }
     else
     {
         p.Command(MugicCommand.Update, objectId);
     }
 }
Esempio n. 4
0
        // I wish I was smart enough to not need this function :(
        protected static String Command2String(MugicCommand c)
        {
            switch (c)
            {
            case MugicCommand.Rectangle: return("rectangle");

            case MugicCommand.Circle: return("circle");

            case MugicCommand.Line: return("line");

            case MugicCommand.Update: return("update");

            default: return("ERROR");
            }
        }
Esempio n. 5
0
 public void Command(MugicCommand c, int oid)
 {
     command  = c;
     objectId = oid;
 }
Esempio n. 6
0
 public void Command(MugicCommand c, int oid)
 {
     command = c;
     objectId = oid;
 }