Skip to content

Instantly share code, notes, and snippets.

View eevee's full-sized avatar
🦊

Eevee eevee

🦊
View GitHub Profile
import operator
import weakref
class classproperty(object):
"""Method decorator similar to ``@property``, but called like a
``classmethod``.
.. code-block:: python
@eevee
eevee / CHIPS.BAS
Last active September 27, 2020 00:38
chip's challenge in qbasic β€” compiled for dos at https://c.eev.ee/CHIPS.EXE
DECLARE FUNCTION WaitKey$ ()
' Add support for stepping off of force floors - DONE
' Add support for nonwaiting so monsters and things can move - SORTA DONE
' Add support for blocks moving on ice
' Add support for dying when the player steps in unprotected water, fire,
' or gets hit by a monster - DONE
' Level editor!
DECLARE SUB KillPlayer (S AS STRING, C AS INTEGER)
DECLARE FUNCTION ChipCount! ()
DECLARE SUB SetDir (K AS STRING)
@eevee
eevee / game-gender.md
Last active August 29, 2015 14:13
gender in games: some light analysis
@eevee
eevee / gist:15a92e26088d79a77fca
Last active August 29, 2015 14:19
pokΓ©mon with forms
pokΓ©mon forms how to change impact
pichu regular, gizamimi β€” pokeathlon, disables evolution
unown letters β€” pokeathlon
castform weather set by ability (weather) pokeathlon, type, moves (level-up)
deoxys normal, attack, defense, speed overworld event (meteorite) effort, pokeathlon, stats, moves (level-up, tutor)
burmy grass, sandy, trash set by terrain of last battle pokeathlon
wormadam grass, sandy, trash β€” effort, pokeathlon, stats, type, moves (level-up, machine, tutor)
cherrim overcast, sunny set by weather via ability (in gen 5+; in 4 this was hardcoded to cherrim) pokeathlon
shellos east, west β€” β€”
@eevee
eevee / gist:630aa012a594cbe31fc3
Created April 27, 2015 02:59
(throwaway) loading regions in starbindery
[local]/starbindery= ☘ select * from planet_type__layer where 'slimecaves' = ANY (secondary_regions);
layer_name β”‚ planet_type_name β”‚ primary_regions β”‚ secondary_regions β”‚ secondary_region_period β”‚ secondary_region_size β”‚ dungeons β”‚ dungeon_count_range
──────────────┼──────────────────┼──────────────────────┼───────────────────────────────────┼─────────────────────────┼───────────────────────┼──────────┼─────────────────────
underground2 β”‚ alien β”‚ {midunderground} β”‚ {cellcaves,fleshcaves,slimecaves} β”‚ {800,1200} β”‚ {400,600} β”‚ {} β”‚ {0,0}
underground1 β”‚ alien β”‚ {shallowunderground} β”‚ {cellcaves,fleshcaves,slimecaves} β”‚ {800,1200} β”‚ {400,600} β”‚ {} β”‚ {0,0}
underground6 β”‚ alien β”‚ {deepunderground} β”‚ {cellcaves,fleshcaves,slimecaves} β”‚ {800,1200}
@eevee
eevee / gist:a510dcf6bc8b189a0c1c
Created April 28, 2015 07:24
(throwaway) locating an object in starbindery
[local]/starbindery= ☘ select planet_type.name, layer.name, dungeon.name from brush join dungeon_tile_brush on dungeon_tile_brush.brush_id = brush.id join dungeon_tile on dungeon_tile_brush.dungeon_tile_id = dungeon_tile.id join dungeon on dungeon_tile.dungeon_name = dungeon.name join planet_type__layer on dungeon.name = ANY (planet_type__layer.dungeons) left join planet_type on planet_type.name = planet_type__layer.planet_type_name left join layer on layer.name = planet_type__layer.layer_name where object_name = 'screenplanet';
name β”‚ name β”‚ name
──────────┼─────────┼──────────────
scorched β”‚ surface β”‚ scifidungeon
jungle β”‚ surface β”‚ scifidungeon
volcanic β”‚ surface β”‚ scifidungeon
alien β”‚ surface β”‚ scifidungeon
tundra β”‚ surface β”‚ scifidungeon
(5 rows)
@eevee
eevee / delaygate.lua
Created May 2, 2015 20:40
starbound delay gate
function init(virtual)
if virtual then return end
self.interval = 30
self.queue = {}
for i = 1, self.interval do
self.queue[i] = false
end
self.qpos = 1
end
@eevee
eevee / starbound-brush-parameters.patch
Last active August 29, 2015 14:20
Starbound patches
diff --git a/unpacked-pristine/dungeons/avian/avianairship/avianairship.dungeon b/unpacked/dungeons/avian/avianairship/avianairship.dungeon
index 961add8..229a8f8 100644
--- a/unpacked-pristine/dungeons/avian/avianairship/avianairship.dungeon
+++ b/unpacked/dungeons/avian/avianairship/avianairship.dungeon
@@ -857,7 +857,7 @@
{
"value" : [77, 20, 14, 255],
"comment" : "birdgroundlantern facing left - off state",
- "brush" : [ [ "clear" ], [ "object", "birdgroundlantern", { "direction" : "left" }, { "parameters" : { "defaultLightState" : false } } ] ]
+ "brush" : [ [ "clear" ], [ "object", "birdgroundlantern", { "direction" : "left", "parameters" : { "defaultLightState" : false } } ] ]
freenode, #starbound:
11:30 < ^7heo> Eyes: python -c "import os; os.system('; '.join(('ffmpeg -i %s %s.mp3' % (x, x.replace('mp4','')) for x in os.listdir('.'))))"
...
11:34 < eevee> whoa
11:34 < eevee> don't use os.system
11:35 < eevee> for file in *.mp4; do ffmpeg -i $file ${file%.mp4}.mp3; done
11:35 < eevee> if you're not using zsh i highly recommend jamming some double quotes in there
@eevee
eevee / neonblockmaterial.patch
Created May 12, 2015 00:34
Starbound patches, round two
diff --git a/unpacked-pristine/tiles/materials/blueneonsymbolblock.material b/unpacked/tiles/materials/blueneonsymbolblock.material
index c0d2065..315dceb 100644
--- a/unpacked-pristine/tiles/materials/blueneonsymbolblock.material
+++ b/unpacked/tiles/materials/blueneonsymbolblock.material
@@ -2,7 +2,7 @@
"materialId" : 112,
"materialName" : "blueneonsymbolblock",
"particleColor" : [71, 66, 57, 255],
- "itemDrop" : "blueneonsymbolblock",
+ "itemDrop" : "blueneonsymbol",