Пример #1
0
            public DamageTimer( ControlPanel panel, Mobile to )
                : base(TimeSpan.FromSeconds( 5.0 ), TimeSpan.FromSeconds( 5.0 ))
            {
                m_Panel = panel;
                m_To = to;
                m_Step = 0;

                Priority = TimerPriority.TwoFiftyMS;
            }
Пример #2
0
            public GameGump( ControlPanel panel, Mobile from, int step, bool hint )
                : base(5, 30)
            {
                m_Panel = panel;
                m_From = from;
                m_Step = step;

                int sideLength = panel.SideLength;

                AddBackground( 50, 0, 530, 410, 0xA28 );

                AddImage( 0, 0, 0x28C8 );
                AddImage( 547, 0, 0x28C9 );

                AddBackground( 95, 20, 442, 90, 0xA28 );

                AddHtml( 229, 35, 300, 45, "GENERATOR CONTROL PANEL", false, false );

                AddHtml( 223, 60, 300, 70, "Use the Directional Controls to", false, false );
                AddHtml( 253, 75, 300, 85, "Close the Grid Circuit", false, false );

                AddImage( 140, 40, 0x28D3 );
                AddImage( 420, 40, 0x28D3 );

                AddBackground( 365, 120, 178, 210, 0x1400 );

                AddImage( 365, 115, 0x28D4 );
                AddImage( 365, 288, 0x28D4 );

                AddImage( 414, 189, 0x589 );
                AddImage( 435, 210, 0xA52 );

                AddButton( 408, 222, 0x29EA, 0x29EC, 1, GumpButtonType.Reply, 0 ); // Left
                AddButton( 448, 185, 0x29CC, 0x29CE, 2, GumpButtonType.Reply, 0 ); // Up
                AddButton( 473, 222, 0x29D6, 0x29D8, 3, GumpButtonType.Reply, 0 ); // Right
                AddButton( 448, 243, 0x29E0, 0x29E2, 4, GumpButtonType.Reply, 0 ); // Down

                AddBackground( 90, 115, 30 + 40 * sideLength, 30 + 40 * sideLength, 0xA28 );
                AddBackground( 100, 125, 10 + 40 * sideLength, 10 + 40 * sideLength, 0x1400 );

                for ( int i = 0; i < sideLength; i++ )
                {
                    for ( int j = 0; j < sideLength - 1; j++ )
                    {
                        AddImage( 120 + 40 * i, 162 + 40 * j, 0x13F9 );
                    }
                }

                for ( int i = 0; i < sideLength - 1; i++ )
                {
                    for ( int j = 0; j < sideLength; j++ )
                    {
                        AddImage( 138 + 40 * i, 147 + 40 * j, 0x13FD );
                    }
                }

                Node[] path = panel.Path;

                NodeHue[,] hues = new NodeHue[sideLength, sideLength];

                for ( int i = 0; i <= step; i++ )
                {
                    Node n = path[i];
                    hues[n.X, n.Y] = NodeHue.Blue;
                }

                Node lastNode = path[path.Length - 1];
                hues[lastNode.X, lastNode.Y] = NodeHue.Red;

                for ( int i = 0; i < sideLength; i++ )
                {
                    for ( int j = 0; j < sideLength; j++ )
                    {
                        AddNode( 110 + 40 * i, 135 + 40 * j, hues[i, j] );
                    }
                }

                Node curNode = path[step];
                AddImage( 118 + 40 * curNode.X, 143 + 40 * curNode.Y, 0x13A8 );

                if ( hint )
                {
                    Node nextNode = path[step + 1];
                    AddImage( 119 + 40 * nextNode.X, 143 + 40 * nextNode.Y, 0x939 );
                }

                if ( from.Skills.Lockpicking.Value >= 65.0 )
                {
                    AddButton( 365, 350, 0xFA6, 0xFA7, 5, GumpButtonType.Reply, 0 );
                    AddHtml( 405, 345, 140, 40, "Attempt to Decipher the Circuit Path", false, false );
                }
            }
Пример #3
0
 public DamageTimer( ControlPanel panel, Mobile to )
     : base(TimeSpan.FromSeconds( 5.0 ), TimeSpan.FromSeconds( 5.0 ))
 {
     m_Panel = panel;
     m_To = to;
     m_Step = 0;
 }