LAZR.PW
Stuff I'm working on.

Thursday, 9 July 2015

pySFML Mouse Single Click

See as there isn't much decent documentation for pySFML that I can find, I'll put this here as a reference snippet for using the input events.

for event in self.window.events:
 if type(event) is sf.CloseEvent:
  self.window.close()

 if type(event) is sf.KeyEvent and event.code is sf.Keyboard.ESCAPE:
  self.window.close()
    
 if type(event) is sf.window.MouseButtonEvent and event.button is sf.Mouse.LEFT and event.pressed:
  self.mousePos = sf.Mouse.get_position(self.window)

Sunday, 14 September 2014

Dartboard Texture


These were created in GIMP 2.8, and the normalmap is made with the normalmap plugin for GIMP available here: https://code.google.com/p/gimp-normalmap/

With a radius of 1.0 the proportion of the rings are as follows.

Bull = 0.028
Outer Bull = 0.028 - 0.071
Inner Section = 0.071 - 0.439
Treble = 0.439 - 0.475
Outer Section = 0.475 - 0.718
Double = 0.718 - 0.754
Void = 0.754 - 1.0

Monday, 28 July 2014

Well This Is Annoying

After working on the hotseat mode for a while now, I've only just had the realization that PvP battles will have to be auto played if it's on a single device. This may seem obvious to you, but I blame sleep deprivation for it taking me so long to see. So, I'm either going to make the PvP battles automated, or just scrap the whole idea.

Bad times :\