This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<html> | |
<head> | |
</head> | |
<body onload="Start()"> | |
<!-- | |
<input type="button" onclick="AddBox()" value="Spawn crate"><input type="button" onmousedown="mouseD=true" onmouseup="mouseD=false" value="Spawn crates continuously"><br> | |
--> | |
<div id="screenArea" style="position: relative; background-image: url(loading.gif); width: 640px; height: 480px;"></div> | |
<br> | |
<pre> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# test of cc65's rand.s LCG | |
import math | |
import random | |
seed = 1 | |
def srand(x): | |
global seed | |
seed = x & 0xFFFF |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
nicks=[]; | |
for(var inv=0; inv<2; inv++){ | |
for(var dir=0; dir<2; dir++){ | |
for(var rots=0; rots<6; rots++){ | |
var a="drnick".split(""); | |
if(inv)a.reverse(); | |
for(var r=0; r<rots; r++){ | |
dir?a.unshift(a.pop()):a.push(a.shift()); | |
} | |
if(a.join("")!="drnick"&&nicks.indexOf(a.join(""))<0)nicks.push(a.join("")); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
//MIT License | |
// | |
//Copyright (c) [2016] kdrnic ( website: kdrnic.xyz ) | |
// | |
//Permission is hereby granted, free of charge, to any person obtaining a copy | |
//of this software and associated documentation files (the "Software"), to deal | |
//in the Software without restriction, including without limitation the rights | |
//to use, copy, modify, merge, publish, distribute, sublicense, and/or sell | |
//copies of the Software, and to permit persons to whom the Software is | |
//furnished to do so, subject to the following conditions: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var _map = new Array(); | |
_map[0] = new Array(2, 1, 2, 4, 4, 4, 4, 4, 4, 4, 4, 1); | |
_map[1] = new Array(2, 0, 2, 0, 0, 6, 0, 0, 0, 0, 4, 1); | |
_map[2] = new Array(2, 0, 2, 0, 0, 6, 0, 8, 8, 0, 4, 1); | |
_map[3] = new Array(2, 0, 0, 0, 0, 6, 0, 8, 8, 0, 4, 1); | |
_map[4] = new Array(2, 2, 2, 0, 0, 6, 0, 0, 0, 0, 4, 1); | |
_map[5] = new Array(4, 0, 0, 0, 0, 6, 0, 0, 8, 8, 4, 1); | |
_map[6] = new Array(4, 0, 7, 7, 0, 6, 0, 0, 8, 8, 4, 1); | |
_map[7] = new Array(4, 0, 7, 0, 0, 0, 0, 0, 0, 0, 4, 1); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
float RadToDegree(float rad) | |
{ | |
return (360.0 * rad) / (2.0 * M_PI); | |
} | |
float DegreeToRad(float degree) | |
{ | |
return (degree * 2.0 * M_PI) / 360.0; | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Chest | |
Bombs (dynamite, classic cartoon bomb, grenade) | |
Keys | |
Keycards | |
Potions | |
Heart (life heart, realistic organ) | |
Cash (paper, coins, ...) | |
Treasures (diamond, golden bars, bag with dollar sign, ...) | |
Gems | |
Egg |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
rem MIT License | |
rem | |
rem Copyright (c) 2014 kdrnic ( website: kdrnic.xyz ) | |
rem | |
rem Permission is hereby granted, free of charge, to any person obtaining a copy | |
rem of this software and associated documentation files (the "Software"), to deal | |
rem in the Software without restriction, including without limitation the rights | |
rem to use, copy, modify, merge, publish, distribute, sublicense, and/or sell | |
rem copies of the Software, and to permit persons to whom the Software is | |
rem furnished to do so, subject to the following conditions: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// MIT License | |
// | |
// Copyright (c) 2012 kdrnic ( website: kdrnic.xyz ) | |
// | |
// Permission is hereby granted, free of charge, to any person obtaining a copy | |
// of this software and associated documentation files (the "Software"), to deal | |
// in the Software without restriction, including without limitation the rights | |
// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell | |
// copies of the Software, and to permit persons to whom the Software is | |
// furnished to do so, subject to the following conditions: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#define JS_FUNC(name) static duk_ret_t js_ ## name (duk_context *ctx) | |
JS_FUNC(Key) | |
{ | |
int sc = duk_to_int(ctx, 0); | |
duk_push_number(ctx, key[sc]); | |
return 1; | |
} | |
JS_FUNC(Joystick) |
OlderNewer