View build.py
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
import os | |
import platform | |
import argparse | |
from enum import Enum | |
from zipfile import ZipFile | |
from typing import Dict, Callable, List | |
GAME_NAME: str = "NAME" | |
IDENTITY: str = "IDENT" |
View pycodestyle
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
[pycodestyle] | |
max-line-length = 96 | |
ignore = E302,E252,W504,E128,E129,E261,E124 |
View build.sh
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
#!/bin/bash | |
function run() | |
{ | |
echo "Running build.sh" | |
if [ $(uname -r | sed -n 's/.*\( *Microsoft *\).*/\1/ip') ]; then | |
echo "This is Windows WSL!" | |
./build_win.sh run | |
else | |
echo "This is Linux" |
View love2d-AdMob-Android-Instruction
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
Love to Android | |
(This guide is mainly for Windows Users. As for Linux/Mac OS users, this are fairly easy.) | |
Setting Up: | |
### Download the Following, place them in a convenient location like C:\AndroidDevelopment\ | |
You will need the following: | |
Java Development Kit (JDK) Note: Download the one without Netbeans IDE. |
View asset_bundler_love.lua
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
function test1() | |
local imgdata = love.image.newImageData("avatar.png") | |
local format = imgdata:getFormat() | |
local filename = "pack" | |
if love.filesystem.getInfo(filename) then | |
love.filesystem.remove(filename) | |
end | |
local file = love.filesystem.newFile(filename, "w") |
View tokenizer.lua
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
-- these have to be sorted by longest first | |
local keywords = { | |
"function", | |
"then", | |
"end", | |
"if", | |
} | |
local symbols = { |
View FrequencyTable.java
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
package frequencytable; | |
public class FrequencyTable { | |
public static void main(String[] args) { | |
test(); | |
} | |
private static void test() { | |
for (int noteNumber = 0; noteNumber < 128; noteNumber++) { |
View MIDISequenceExtractor.java
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
package midisequenceextractor; | |
import java.io.File; | |
import java.io.IOException; | |
import java.util.ArrayList; | |
import java.util.HashMap; | |
import java.util.List; | |
import java.util.Map; | |
import javax.sound.midi.InvalidMidiDataException; | |
import javax.sound.midi.MidiChannel; |
View shockwave.glsl
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
extern number minRadius = 0.05; | |
extern number maxRadius = 0.1; | |
extern number mul = 0.01; | |
extern vec2 center = vec2(0.5,0.5); | |
number dist(vec2 a, vec2 b){ | |
return sqrt(pow(b.x-a.x,2)+pow(b.y-a.y,2)); | |
} |
View main.lua
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
--[[ | |
example use | |
]] | |
local recolour = require("recolour") | |
--we want to recolour this asset image | |
local to_recolour = love.image.newImageData("path/to/image.png") | |
--using this palette image | |
local palette = love.image.newImageData("path/to/palette.png") |
NewerOlder