Skip to content
Snippets Groups Projects
test.html 2.98 KiB
Newer Older
<!DOCTYPE html>
<html>
<head>
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
    <link href="ui.css" rel="stylesheet"/>
    <script src="jslib/d3.min.js" type="text/javascript"></script>
    <script src="jslib/priority-queue.min.js" type="text/javascript"></script>
    <script src="jslib/checkLineIntersection.js" type="text/javascript"></script>
    <script src="../../js/api.js" type="text/javascript"></script>
    <script src="js/events.js" type="text/javascript"></script>
    <script src="js/achievements.js" type="text/javascript"></script>
    <script src="js/svgUtils.js" type="text/javascript"></script>
    <script src="js/pathFinder.js" type="text/javascript"></script>
    <script src="js/vector.js" type="text/javascript"></script>
    <script src="js/character.js" type="text/javascript"></script>
    <script src="js/camera.js" type="text/javascript"></script>
    <script src="js/game.js" type="text/javascript"></script>
Tim Repke's avatar
Tim Repke committed
<div id="game-root-container">
    <div id="game-sidebar">
        <div class="sidebar-section">
            <div class="sidebar-section-head">Game log</div>
            <div class="sidebar-log">
                <div>
                    <ul id="game-log">
                        <li>Find the students union room</li>
                        <li>Found the castle entrance</li>
                        <li>Go inside the castle!</li>
                        <li>Find the students union room</li>
                        <li>Found the castle entrance</li>
                        <li>Go inside the castle!</li>
                    </ul>
                </div>
            </div>
        </div>
        <div class="sidebar-section">
            <div class="sidebar-section-head">Achievements</div>
            <div class="status-bar" id="achievement-progress" style="margin-bottom: 0.5em"><span style="width:25%"
                                                                                                 class="status-bar-bar"></span>
Tim Repke's avatar
Tim Repke committed

                <div class="status-bar-text">5/43</div>
            </div>
            <div class="sidebar-log">
                <div>
                    <ul id="achievement-log"></ul>
                </div>
            </div>
        </div>
    </div>

    <div id="game-game">
        <div id="gameCanvas" style="overflow:hidden;position:relative">
            <div id="gameRoot" style="position:relative"></div>
        </div>
    </div>
    g_smallValue = 0.000001; // fun with floats
    var FAPI = new FAPI();
    FAPI.methodBasepath = '';
    var maps = ['map_landing', 'castle_entrance', 'castle_fs', 'dorf'];
    var game = new Game({
        startMap: maps[UrlComponents.getValueOf('map') || 0],
        showEventLayers: UrlComponents.isSet('showEventLayers'),
        pathFindingGridSize: UrlComponents.isSet('verbosePF') ? 5 : 5,
        verbosePathFinder: UrlComponents.isSet('verbosePF'),
        usePathFinding: true,
        size: [800, 600]
    });
    game.run();