This file contains hidden or 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
class Block(object): | |
""" | |
Block IDs this class is responsible for. | |
""" | |
slots = tuple() | |
def build(self, factory, player, x, y, z, face): | |
""" | |
Called when a player places a block of this type. |
This file contains hidden or 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
from ampoule import child, util | |
from twisted.protocols import amp | |
class Test(amp.Command): | |
response = [("blocks", amp.String())] | |
class MyChild(child.AMPChild): | |
@Test.responder | |
def test(self): | |
return {"blocks": '\x00'*4073} |
This file contains hidden or 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 math | |
import time | |
from bravo.chunk import Chunk | |
from bravo.plugins.generators import simplex, caves | |
def average(l): | |
return sum(l) / len(l) | |
def stddev(l): |
This file contains hidden or 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
diff --git a/bravo/chunk.py b/bravo/chunk.py | |
index 1b53573..6d6d519 100644 | |
--- a/bravo/chunk.py | |
+++ b/bravo/chunk.py | |
@@ -198,7 +198,8 @@ class Chunk(object): | |
while glow: | |
for coords in spread: | |
- if coords[2] > max_height: | |
+ if lightmap[coords] <= glow: |
This file contains hidden or 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
diff --git a/bravo/packets.py b/bravo/packets.py | |
index 400f09b..43d04e5 100644 | |
--- a/bravo/packets.py | |
+++ b/bravo/packets.py | |
@@ -73,6 +73,9 @@ metadata = Struct("metadata", | |
), | |
Const(UBInt8("terminator"), 0x7f), | |
) | |
+from construct import StringAdapter, RepeatUntil, Field | |
+metadata = StringAdapter(RepeatUntil(lambda obj, ctx: obj == "\x7f", |
This file contains hidden or 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
diff --git a/example/settings.py b/example/settings.py | |
index 5d6f346..da47af2 100644 | |
--- a/example/settings.py | |
+++ b/example/settings.py | |
@@ -98,7 +98,7 @@ TEMPLATE_CONTEXT_PROCESSORS = ( | |
'django.core.context_processors.debug', | |
'django.core.context_processors.i18n', | |
'django.core.context_processors.media', | |
- 'django.core.context_processors.static', | |
+ 'staticfiles.context_processors.static', |
This file contains hidden or 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
diff --git a/horizons/engine/pychan_util.py b/horizons/engine/pychan_util.py | |
index a4d869b..e1ad670 100644 | |
--- a/horizons/engine/pychan_util.py | |
+++ b/horizons/engine/pychan_util.py | |
@@ -21,7 +21,6 @@ | |
# ################################################### | |
import functools | |
-import new | |
This file contains hidden or 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 functools | |
import httplib | |
import json | |
import threading | |
import time | |
import urllib | |
from wsgiref.simple_server import make_server | |
from irc.client import SimpleIRCClient |
This file contains hidden or 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
diff --git a/content/scenarios/tutorial_en.yaml b/content/scenarios/tutorial_en.yaml | |
index 3845ecc..1be531d 100644 | |
--- a/content/scenarios/tutorial_en.yaml | |
+++ b/content/scenarios/tutorial_en.yaml | |
@@ -410,8 +410,7 @@ events: | |
- type: set_var | |
arguments: ["tutorial_progress", 16] | |
conditions: | |
- - type: time_passed | |
- arguments: [0] |
This file contains hidden or 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
[util/log]:74 debug => Logging system initialized | |
[util/log]:74 debug => Logging system initialized | |
[gl/texture]:61 debug => Loaded image data/img/console/left.png with 40x300:4 | |
[gl/texture]:61 debug => Loaded image data/img/console/right.png with 40x300:4 | |
[gl/texture]:61 debug => Loaded image data/img/console/middle.png with 1x300:4 | |
[state/console/console]:220 debug => Loading console state. | |
[state/console/console_renderer]:57 debug => Loading console renderer state | |
[obj/md5/model/model]:125 debug => Parsing model data/models/berserker/berserker.md5mesh | |
[obj/md5/model/model]:136 debug => Model version: 10 | |
[obj/md5/model/model]:144 debug => Model joints: 41 |
OlderNewer