Skip to content

Instantly share code, notes, and snippets.

@croxis
croxis / rylaeval2014.py
Created September 16, 2015 00:45
Ocular Ryla Evaluation Scanner and Tabulator for Python 3. Needs imagemagick installed on a system path and the python extension "wand"
# python eval.py test.pdf 'Top Person' 'Top topic' 'Bottom Person' 'Bottom topic'
import argparse
import os
import shlex
import subprocess
import glob
from wand.image import Image
from wand.display import display
from wand.color import Color
|gorilla berserkers||creature||human cleric|&/&^^^^^|{^^^WW}|morph {^^WWWW}|when @ enters the battlefield, if you control a plains, you may pay {^}. if you do, return target creature card from your graveyard to your hand.|
|king thug||sorcery||||{^^^^BBBB}|destroy target land or nonblack.|
|river kalds||enchantment||||{^GG}|{^}: the next time an artifact spell, if there are tished four or more targets a permanent you control.|
|enferbender||creature||human spellshaper|&^^/&^^|{^^UU}|{^^^^^}, T, discard a card: draw a card.|
|hammerheid||creature||plant wall|&/&|{^^GGGG}|@ enters the battlefield with X +&^/+&^ counters on it.|
#version 410
#pragma include "Includes/Configuration.include"
#pragma include "Includes/Structures/VertexOutput.struct"
#extension GL_EXT_shader_image_load_store : enable
// Input from the vertex shader
layout(location=0) in VertexOutput vOutput;
@croxis
croxis / main.py
Created July 2, 2015 17:07
Pyserial + panda3d example
from __future__ import print_function
from direct.showbase.ShowBase import ShowBase
import serial
ser = serial.Serial(1, 38400, timeout=0, parity=serial.PARITY_EVEN, rtscts=1)
buffer = ""
MyProgram(ShowBase):
__init__(self):
ShowBase.__init__(self)
@croxis
croxis / Player.log
Created April 13, 2015 22:11
Robocraft crash
ERROR: ld.so: object '/home/croxis/.local/share/Steam/ubuntu12_32/gameoverlayrenderer.so' from LD_PRELOAD cannot be preloaded (wrong ELF class: ELFCLASS32): ignored.
pid 1999 != 1947, skipping destruction (fork without exec?)
pid 2004 != 1947, skipping destruction (fork without exec?)
pid 2005 != 1947, skipping destruction (fork without exec?)
Setting breakpad minidump AppID = 301520
Steam_SetMinidumpSteamID: Caching Steam ID: 76561197985142402 [API loaded no]
pid 2021 != 1947, skipping destruction (fork without exec?)
pid 2026 != 1947, skipping destruction (fork without exec?)
pid 2027 != 1947, skipping destruction (fork without exec?)
pid 2030 != 1947, skipping destruction (fork without exec?)
@croxis
croxis / gist:6436553c3542ec692c1d
Created March 24, 2015 00:08
Rendering procedural planets.
Based on feedback from ChemicalR I'm cross posting all the things I've bookmarked in reguards to planet rendering here in the code forums.
[url=http://www.gamasutra.com/view/feature/3098/a_realtime_procedural_universe_.php]Sean O'Neil[/url]'s 4 2001 part series is considered a foundation for realistic large scale (planets on up) rendering. Most of these methods are now obsolete and replaced with faster methods and gpu shaders. His [url=http://http.developer.nvidia.com/GPUGems2/gpugems2_chapter16.html]atmospheric scattering[/url]method is still used often due to its relative simplicity, but it only produces earth atmospheres.
[url=http://acko.net/blog/making-worlds-1-of-spheres-and-cubes/]Steven Wittens[/url] 2009 multipart series is frequently linked to as I've searched for best practices in creating planets using modern methods. It is based on a cube with mesh texture and normalizes the vertex points into a sphere. The advantage to this method is that conventional terrain LOD methods, often used in first
@croxis
croxis / gist:f08d1ce071072b8efbc0
Created March 24, 2015 00:04
Trillek Single Solar System Arguments
In irc there was talk about FTL and the assorted gameplay issues with each method. Then I started thinking about other design and story issues trillek is having. Then I started thinking about my space game I haven't touched in a while.
A few years ago I saw a video similar to this one http://vimeo.com/40234826 and I was really struck by saturn's moons. Saturn has over 70 moons. That is a lot of surface area to explore and with assorted orbits around each moon, and saturn itself, that is a lot of gamespace. I also saw this picture http://misc.oranse.net/misc/wallpaper/earth.jpg taken from low Earth orbit and how amazing our planet looked from low orbit. I started designing a game with the setting of just our solar system that takes place during humanity's expansion into our solar system.
What if we used that setting, or a similar one, instead? What if trillek takes place in one solar system?
Using our solar system as a model: There are 4 terrestial planets. 4 gas giants. At least 4 dwarf planets and a numbe
"""This is blank. Review python packages in the python manual for understanding."""
@croxis
croxis / basic.py
Last active February 4, 2021 15:41
CEFPython for Panda3D
from cefpython3 import cefpython
import os
import sys
from panda3d.core import loadPrcFileData
loadPrcFileData("", "Panda3D example")
loadPrcFileData("", "fullscreen 0")
loadPrcFileData("", "win-size 1024 768")
#version 130
uniform sampler2D colorTexture;
uniform sampler2D nightTesture;
uniform sampler2D glossTexture;
in vec2 texCoords;
//varying vec3 N;
//varying vec3 v;