Skip to content

Instantly share code, notes, and snippets.

@emhoracek
emhoracek / mariko.cnf
Created February 18, 2015 14:40
My first script
; ** FKiSS stuff **
;
;@EventHandler()
;
;@initialize()
;@ unmap("bubble1.cel")
;@ unmap("bubble2.cel")
;@ unmap("bubble3.cel")
;@ unmap("bubble4.cel")
;@ unmap("eye2.cel")
@emhoracek
emhoracek / gist:a35b4937f6ade4146eb3
Last active August 29, 2015 14:10
Now I can't figure out math
import Keyboard
import Window
import Text
import Random
import Debug
-- INPUTS
type Input = { space: Bool, delta: Time, randBalls: [Ball] }
# Doesn't work
sub label {
my ( $class, $u ) = @_;
return $_[0]->ml( 'setting.display.journaliconstyle.label.comm')
if $u && $u->is_community;
return $_[0]->ml( 'setting.display.journaliconstyle.label' );
}
# works
@emhoracek
emhoracek / main.elm
Last active August 29, 2015 14:05
makerspace site
import Window
import String (concat, contains, toLower, any)
import Graphics.Input (Input, input, dropDown, customButton)
import Graphics.Input.Field as Field
import List (filter, map, take, intersperse, any)
main = lift4 scene Window.dimensions yrIdeas.signal yrEmail.signal click.signal
-- MODEL
@emhoracek
emhoracek / Adventure.hs
Last active August 29, 2015 14:04
Text exploration game
{-# LANGUAGE OverloadedStrings #-}
-- Oh boy did I make a mess of this. Tried to add a way to import an external file of places
-- using JSON (thanks to Zach from Hacker School!!!) but the nested objects make it kind
-- of difficult. Right now the exits are just a string but I would like it to be a nested
-- JSON object. But I really don't understand how that works, so it's a string of JSON,
-- which is super ugly. But it compiles!!
module Main where
@emhoracek
emhoracek / TicTacToe.elm
Last active August 29, 2015 14:04
Tic-Tac-Toe
import Array as A
import Window
import Graphics.Input as I
main = lift2 scene Window.dimensions gameState
--------------------------------------------------------
-- INPUT