Skip to content

Instantly share code, notes, and snippets.

View branan's full-sized avatar
💩

Branan Riley branan

💩
View GitHub Profile
@branan
branan / shard_todo.txt
Created April 14, 2011 05:20
Things To Do for the GoW Shard
Technical:
* Get KI chat working in DirtSand
* Cleanup Bevin
* Adjust Startup python to link to the cleft
* Generate a new UUID for our builds
* Reset the build ID to match the new UUID
Artistic:
* Adjust cleft to be the starting point again
@branan
branan / tables.sql
Created April 18, 2011 04:27
create table script
CREATE TABLE ages (
ID INTEGER UNSIGNED NOT NULL AUTO_INCREMENT,
agename VARCHAR(16) NOT NULL,
author MEDIUMINT(8) UNSIGNED NOT NULL,
longname VARCHAR(255) NOT NULL,
version INTEGER UNSIGNED NOT NULL,
release DATE NOT NULL,
updated DATE NOT NULL,
seqprefix INTEGER UNSIGNED NULL,
PRIMARY KEY(ID)
/////////////////////////////////////////////////////////////////////////////
//
// Function : SendKIMessageIReply
// PARAMETERS : command - the command type
// : value - extra value as an Int32
//
// PURPOSE : Send message to the KI, to tell it things to do
//
// RETURNS : nothing
//
@branan
branan / gist:958242
Created May 6, 2011 00:28
Make age private in dirtsand
uint32_t dm_auth_set_private(uint32_t nodeid) {
PostgresStrings<4> parms;
parms.set(0, nodeid);
parms.set(1, DS::Vault::e_NodeAgeInfo);
PGresult* result = PQexecParams(s_postgres,
"SELECT \"Uuid_1\" FROM vault.\"Nodes\" WHERE idx=$1 AND \"NodeType\"=$2",
2, 0, parms.m_values, 0, 0, 0);
if (PQresultStatus(result) != PGRES_TUPLES_OK) {
fprintf(stderr, "%s:%d:\n Postgres SELECT error: %s\n",
__FILE__, __LINE__, PQerrorMessage(s_postgres));
@branan
branan / gist:958245
Created May 6, 2011 00:29
Make age private in dirtsand
uint32_t dm_auth_set_private(uint32_t nodeid) {
PostgresStrings<4> parms;
parms.set(0, nodeid);
parms.set(1, DS::Vault::e_NodeAgeInfo);
PGresult* result = PQexecParams(s_postgres,
"SELECT \"Uuid_1\" FROM vault.\"Nodes\" WHERE idx=$1 AND \"NodeType\"=$2",
2, 0, parms.m_values, 0, 0, 0);
if (PQresultStatus(result) != PGRES_TUPLES_OK) {
fprintf(stderr, "%s:%d:\n Postgres SELECT error: %s\n",
__FILE__, __LINE__, PQerrorMessage(s_postgres));
@branan
branan / gist:1003173
Created June 1, 2011 20:04
Response to JWPlatt 01/06/2011
[quote="JWPlatt"]If we are not responsive, it is not because we are disinterested or shunning you. It is because there are matters of livelihood and family more important than Uru.[/quote] I'm going to address this first, because I think it's extremely important. I feel quite strongly that if the people in your team didn't have the time and energy to deal with code maintainership and developer interaction, then you needed to either look for help [b]before[/b] the release so you could have a proper maintainer, or tell Cyan "Thanks, but I don't think we can handle this right now" so that another team in the community who [b]does[/b] have the time and energy could handle it.
[quote="JWPlatt"]Community participation is critical to the sustained success of this long term project. There is an imperative that people should be called upon to get involved and participate. This is not our project. It is yours; everyone's. It can only work with more people getting involved, being committed, and taking positions of re
@branan
branan / gist:1008289
Created June 4, 2011 20:00
GL error handling
static const char* glErrorString(GLenum err) {
switch(err) {
case GL_INVALID_ENUM: return "Invalid Enum";
case GL_INVALID_VALUE: return "Invalid Value";
case GL_INVALID_OPERATION: return "Invalid Operation";
case GL_STACK_OVERFLOW: return "Stack Overflow";
case GL_STACK_UNDERFLOW: return "Stack Underflow";
case GL_OUT_OF_MEMORY: return "Out of Memory";
case GL_TABLE_TOO_LARGE: return "Table too Large";
default: return "Unknown Error";
void Pipeline::platformInit() {
platform = new PipelinePlatform;
try {
Display *dpy = platform->dpy = XOpenDisplay(0);
if(!dpy)
throw std::runtime_error("Could not open X11 display!");
try { // display is open. If we get an error from here down we need to close the display
// Verify our GLX version is the minimum to be doing our fun stuff
int glx_major, glx_minor;
@branan
branan / gist:1008490
Created June 4, 2011 23:30
email to mark
Hey mark,
We've got a huge pile of changes at this point, and some of them are actually applicable to MOULagain and small enough they could be merged in. Will you (or anyone else at cyan) have time to look over patches anytime soon? If so, should we send them to you directly still, or is there a new plan in place at this point?
We've got two simple fixes: one for the ptMatrix44 getter/setter, and another for saving JPEGs to the disk without the size embedded in them. Both are small fixes and should be easy for you to review and merge.
The big one that we'd really like to see merged is the asyncfixes patchset. Hoikas rewrote a bunch of the vault API to be asynchronous, fixing the several-second lags that occur when players do certain things (like sending an age invite, for example). It's nearly a 1000 lines changed across 13 commits, though.
On the python side, we have a number of small patches as well. The really big important one is a performance fix for xSimpleImager. This script refreshes every time it
# This is the CMakeCache file.
# For build in directory: c:/Users/games/engine_tmp/build
# It was generated by CMake: c:/Program Files (x86)/CMake 2.8/bin/cmake.exe
# You can edit this file to change values found and used by cmake.
# If you do not want to change any of the values, simply exit the editor.
# If you do want to change a value, simply edit, save, and exit the editor.
# The syntax for the file is as follows:
# KEY:TYPE=VALUE
# KEY is the name of a variable in the cache.
# TYPE is a hint to GUI's for the type of VALUE, DO NOT EDIT TYPE!.