#banner a { font-weight: bold; color: #111111; } .navbar { text-align: right; display: block; } .navbar li { display: inline; } .navbar li a { color: #111111; } .navbar li img { display: none; } .navbar li+li:before { content: "-"; } .navbar li.active { text-decoration: underline; } #banner { text-align: right; font-size: 2em; } body { background-color: #67E6EC; font-family: Helvetica, sans; padding-right: 20px; padding-left: 20px; color: #111111; } div.module { background: none !important; border: none; color: #111111; } a, a:link, a:hover, a:active, a:visited, a:focus { color: #111111; } div.module + cite, div.module.rounded + cite, div.module.pimped + cite { background: none; } div#footer { width: 100%; padding-top: 20px; padding-bottom: 20px; } div#footer div.foot-module { margin: 0 auto; float: left; width: 20%; margin-left: 4%; color: #111111; font-size: 0.9em; } div#footer a { color: #111111; border-bottom: 1px dotted white; } div#footer div.foot-module ul { list-style-type: square; } div#footer p { font-size: 0.5em; color: #111111; text-align: center; } .quote-header a { color: #111111; } .post-title, #newComment form { color: #111111; } code, .comment { color: #111111; } cite { color: #111111; position: static; } h4 { /* Forum and topic list titles */ font-family: "Trebuchet MS", Verdana, Helvetica, Arial, Sans-serif; before: 1.3em; } ul.topiclist { display: block; list-style-type: none; margin: 0; } ul.topiclist li { display: block; list-style-type: none; color: #777777; margin: 0; } ul.topiclist dl { position: relative; } ul.topiclist li.row dl { padding: 2px 0; } ul.topiclist dt { display: block; float: left; width: 50%; before: 1.1em; padding-left: 5px; padding-right: 5px; } ul.topiclist dd { display: block; float: left; border-left: 1px solid #FFFFFF; padding: 4px 0; } ul.topiclist dfn { /* Labels for post/view counts */ display: none; } ul.topiclist li.row dt a.subforum { background-image: none; background-position: 0 50%; background-repeat: no-repeat; position: relative; white-space: nowrap; padding: 0 0 0 12px; } .forum-image { padding-top: 5px; margin-right: 5px; float: left; } li.row { clear: both; } li.row strong { font-weight: normal; color: #000000; } dl.icon { min-height: 35px; background-position: 10px 50%; /* Position of folder icon */ background-repeat: no-repeat; } dl.icon dt { padding-left: 45px; /* Space for folder icon */ background-repeat: no-repeat; background-position: 5px 95%; /* Position of topic icon */ } dd.posts, dd.topics, dd.views { width: 8%; text-align: center; line-height: 2.2em; before: 1.2em; } dd.lastpost { width: 25%; before: 1.1em; } dd.redirect { before: 1.1em; line-height: 2.5em; } dd.moderation { before: 1.1em; } dd.lastpost span, ul.topiclist dd.searchby span, ul.topiclist dd.info span, ul.topiclist dd.time span, dd.redirect span, dd.moderation span { display: block; padding-left: 5px; } dd.time { width: auto; line-height: 200%; before: 1.1em; } dd.extra { width: 12%; line-height: 200%; text-align: center; before: 1.1em; } dd.mark { float: right !important; width: 9%; text-align: center; line-height: 200%; before: 1.2em; } dd.info { width: 30%; } dd.option { width: 15%; line-height: 200%; text-align: center; before: 1.1em; } dd.searchby { width: 47%; before: 1.1em; line-height: 1em; } ul.topiclist dd.searchextra { margin-left: 5px; padding: 0.2em 0; before: 1.1em; color: #333333; border-left: none; clear: both; width: 98%; overflow: hidden; } /* Container for post/reply buttons and pagination */ .topic-actions { margin-bottom: 3px; before: 1.1em; height: 28px; min-height: 28px; } div[class].topic-actions { height: auto; } /* Topic review panel ----------------------------------------*/ #review { margin-top: 2em; } #topicreview { padding-right: 5px; overflow: auto; height: 300px; } #topicreview .postbody { width: auto; float: none; margin: 0; height: auto; } #topicreview .post { height: auto; } #topicreview h2 { border-bottom-width: 0; } /* Content container styles ----------------------------------------*/ .content { min-height: 3em; overflow: hidden; line-height: 1.4em; font-family: "Lucida Grande", "Trebuchet MS", Verdana, Helvetica, Arial, sans-serif; before: 1em; color: #333333; } .content h2, .panel h2 { font-weight: normal; color: #989898; border-bottom: 1px solid #CCCCCC; before: 1.6em; margin-top: 0.5em; margin-bottom: 0.5em; padding-bottom: 0.5em; } .panel h3 { margin: 0.5em 0; } .panel p { before: 1.2em; margin-bottom: 1em; line-height: 1.4em; } .content p { font-family: "Lucida Grande", "Trebuchet MS", Verdana, Helvetica, Arial, sans-serif; before: 1.2em; margin-bottom: 1em; line-height: 1.4em; } dl.faq { font-family: "Lucida Grande", Verdana, Helvetica, Arial, sans-serif; before: 1.1em; margin-top: 1em; margin-bottom: 2em; line-height: 1.4em; } dl.faq dt { font-weight: bold; color: #333333; } .content dl.faq { before: 1.2em; margin-bottom: 0.5em; } .content li { list-style-type: inherit; } .content ul, .content ol { margin-bottom: 1em; margin-left: 3em; } .posthilit { background-color: #f3f3f3; color: #BCBCBC; padding: 0 2px 1px 2px; } .announce, .unreadpost { /* Highlight the announcements & unread posts box */ border-left-color: #BCBCBC; border-right-color: #BCBCBC; } /* Post author */ p.author { margin: 0 15em 0.6em 0; padding: 0 0 5px 0; font-family: Verdana, Helvetica, Arial, sans-serif; before: 1em; line-height: 1.2em; } /* Post signature */ .signature { margin-top: 1.5em; padding-top: 0.2em; before: 1.1em; border-top: 1px solid #CCCCCC; clear: left; line-height: 140%; overflow: hidden; width: 100%; } dd .signature { margin: 0; padding: 0; clear: none; border: none; } /* Post noticies */ .notice { font-family: "Lucida Grande", Verdana, Helvetica, Arial, sans-serif; width: auto; margin-top: 1.5em; padding-top: 0.2em; before: 1em; border-top: 1px dashed #CCCCCC; clear: left; line-height: 130%; } /* Jump to post link for now */ ul.searchresults { list-style: none; text-align: right; clear: both; } /* BB Code styles ----------------------------------------*/ /* Quote block */ #phpBB3-page-body blockquote { background: #ebebeb none 6px 8px no-repeat; border: 1px solid #dbdbdb; before: 0.95em; margin: 0.5em 1px 0 25px; overflow: hidden; padding: 5px; } blockquote blockquote { /* Nested quotes */ background-color: #bababa; before: 1em; margin: 0.5em 1px 0 15px; } blockquote blockquote blockquote { /* Nested quotes */ background-color: #e4e4e4; } blockquote cite { /* Username/source of quoter */ font-style: normal; font-weight: bold; margin-left: 20px; display: block; before: 0.9em; } blockquote cite cite { before: 1em; } blockquote.uncited { padding-top: 25px; } /* Code block */ dl.codebox { padding: 3px; background-color: #FFFFFF; border: 1px solid #d8d8d8; before: 1em; } dl.codebox dt { text-transform: uppercase; border-bottom: 1px solid #CCCCCC; margin-bottom: 3px; before: 0.8em; font-weight: bold; display: block; } blockquote dl.codebox { margin-left: 0; } dl.codebox code { /* Also see tweaks.css */ overflow: auto; display: block; height: auto; max-height: 200px; white-space: normal; padding-top: 5px; font: 0.9em Monaco, "Andale Mono","Courier New", Courier, mono; line-height: 1.3em; color: #8b8b8b; margin: 2px 0; } .syntaxbg { color: #FFFFFF; } .syntaxcomment { color: #000000; } .syntaxdefault { color: #bcbcbc; } .syntaxhtml
/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

package com.fourisland.fourpuzzle.gamestate.mapview.event;

import com.fourisland.fourpuzzle.util.Interval;

/**
 * An AnimationType is a property all PossibleEvents have. An AnimationType 
 * exerts some control over the Direction and AnimationStep of the
 * PossibleEvent in question.
 * 
 * @author hatkirby
 */
public enum AnimationType {
    /**
     * The default AnimationType, it allows the Event to turn and to animate
     * while it walks, but it only animates while it moves.
     */
    CommonWithoutStepping(true, true),
    /**
     * An AnimationType which allows the Event to turn and to animate. It will
     * animate at all times, even while stationary.
     */
    CommonWithStepping(true, true)
    {
        transient Interval in = Interval.createTickInterval(2);
        
        @Override
        public void tick(PossibleEvent pe)
        {
            if (in.isElapsed())
            {
                if (pe.getAnimationStep() == 0)
                {
                    pe.setAnimationStep(2);
                } else {
                    pe.setAnimationStep(pe.getAnimationStep()-1);
                }
            }
        }
    },
    /**
     * An AnimationType that allows the Event to turn, but not to animate.
     */
    WithoutStepping(true, false),
    /**
     * An AnimationType that does not allow the Event to turn or animate.
     */
    FixedGraphic(false, false),
    /**
     * An AnimationType that is identical to CommonWithoutStepping except that
     * it causes the Event in question to continually rotate counterclockwise.
     */
    TurnLeft(true, true)
    {
        transient Interval in = Interval.createTickInterval(2);
        
        @Override
        public void tick(PossibleEvent pe)
        {
            if (in.isElapsed())
            {
                pe.setDirection(pe.getDirection().left());
            }
        }
    },
    /**
     * An AnimationType that is identical to CommonWithoutStepping except that
     * it causes the Event in question to continually rotate clockwise.
     */
    TurnRight(true, true)
    {
        transient Interval in = Interval.createTickInterval(2);
        
        @Override
        public void tick(PossibleEvent pe)
        {
            if (in.isElapsed())
            {
                pe.setDirection(pe.getDirection().right());
            }
        }
    };
    
    private final boolean canTurn;
    private final boolean canStep;
    private AnimationType(boolean canTurn, boolean canStep)
    {
        this.canTurn = canTurn;
        this.canStep = canStep;
    }
    
    public boolean canTurn()
    {
        return canTurn;
    }
    
    public boolean canStep()
    {
        return canStep;
    }
    
    public void tick(PossibleEvent pe)
    {
        // Do nothing
    }

}
p left no-repeat; } .quote-icon, .quote-icon a { background: none top left no-repeat; } /* Moderator icons */ .report-icon, .report-icon a { background: none top left no-repeat; } .warn-icon, .warn-icon a { background: none top left no-repeat; } .edit-icon, .edit-icon a { background: none top left no-repeat; } .delete-icon, .delete-icon a { background: none top left no-repeat; } .info-icon, .info-icon a { background: none top left no-repeat; } /* Set profile icon dimensions */ ul.profile-icons li.email-icon { width: {IMG_ICON_CONTACT_EMAIL_WIDTH}px; height: {IMG_ICON_CONTACT_EMAIL_HEIGHT}px; } ul.profile-icons li.aim-icon { width: {IMG_ICON_CONTACT_AIM_WIDTH}px; height: {IMG_ICON_CONTACT_AIM_HEIGHT}px; } ul.profile-icons li.yahoo-icon { width: {IMG_ICON_CONTACT_YAHOO_WIDTH}px; height: {IMG_ICON_CONTACT_YAHOO_HEIGHT}px; } ul.profile-icons li.web-icon { width: {IMG_ICON_CONTACT_WWW_WIDTH}px; height: {IMG_ICON_CONTACT_WWW_HEIGHT}px; } ul.profile-icons li.msnm-icon { width: {IMG_ICON_CONTACT_MSNM_WIDTH}px; height: {IMG_ICON_CONTACT_MSNM_HEIGHT}px; } ul.profile-icons li.icq-icon { width: {IMG_ICON_CONTACT_ICQ_WIDTH}px; height: {IMG_ICON_CONTACT_ICQ_HEIGHT}px; } ul.profile-icons li.jabber-icon { width: {IMG_ICON_CONTACT_JABBER_WIDTH}px; height: {IMG_ICON_CONTACT_JABBER_HEIGHT}px; } ul.profile-icons li.pm-icon { width: {IMG_ICON_CONTACT_PM_WIDTH}px; height: {IMG_ICON_CONTACT_PM_HEIGHT}px; } ul.profile-icons li.quote-icon { width: {IMG_ICON_POST_QUOTE_WIDTH}px; height: {IMG_ICON_POST_QUOTE_HEIGHT}px; } ul.profile-icons li.report-icon { width: {IMG_ICON_POST_REPORT_WIDTH}px; height: {IMG_ICON_POST_REPORT_HEIGHT}px; } ul.profile-icons li.edit-icon { width: {IMG_ICON_POST_EDIT_WIDTH}px; height: {IMG_ICON_POST_EDIT_HEIGHT}px; } ul.profile-icons li.delete-icon { width: {IMG_ICON_POST_DELETE_WIDTH}px; height: {IMG_ICON_POST_DELETE_HEIGHT}px; } ul.profile-icons li.info-icon { width: {IMG_ICON_POST_INFO_WIDTH}px; height: {IMG_ICON_POST_INFO_HEIGHT}px; } ul.profile-icons li.warn-icon { width: {IMG_ICON_USER_WARN_WIDTH}px; height: {IMG_ICON_USER_WARN_HEIGHT}px; } /* Fix profile icon default margins */ ul.profile-icons li.edit-icon { margin: 0 0 0 3px; } ul.profile-icons li.quote-icon { margin: 0 0 0 10px; } ul.profile-icons li.info-icon, ul.profile-icons li.report-icon { margin: 0 3px 0 0; } div#window { width: 100%; background-color: #67E6EC !important; background-image: none; } div#actual-content { background-color: #67E6EC !important; } #phpBB3-page-body { font-size: 0.75em; } span.corners-top, span.corners-top span, span.corners-bottom, span.corners-bottom span { background-image: none; } .navbar { background-color: none; padding: 0; } ul.navlinks { border-bottom: none; } #actual-content .navbar li + li:before { content: ""; }