コード例 #1
0
ファイル: Packets.cs プロジェクト: ramatronics/rsps
 public void newStillGraphics(Location loc, Graphics graphics, byte tilesAway = 0)
 {
     sendCoords(new Location(loc.getX(), loc.getY(), player.getLocation().getZ()));
     connection.SendPacket(new PacketBuilder().setId(17)
         .addByte(tilesAway) //tiles away  (X >> 4 + Y & 7)
         .addUShort(graphics.getId()) // graphic id
         .addByte((byte)graphics.getHeight()) //height of the spell above it's basic place, i think it's written in pixels 100 pixels higher
         .addUShort(graphics.getDelay()).toPacket()); ;//Time before casting the graphic
 }
コード例 #2
0
ファイル: Entity.cs プロジェクト: ramatronics/rsps
 public void setLastGraphics(Graphics lastGraphics)
 {
     this.lastGraphics = lastGraphics;
     if (this is Player)
         ((Player)this).getUpdateFlags().setGraphicsUpdateRequired(true);
     else if (this is Npc)
         ((Npc)this).getUpdateFlags().setGraphicsUpdateRequired(true);
 }