IRC channel logs

2016-12-31.log

back to list of logs

<paroneayea>o/ davexunit
<ehiggs>no wingo talks at fosdem Guile devroom this year; or llvm devroom. wingo are you going to fosdem this year?
<paroneayea>ehiggs: I believe wingo isn't from previous conversation
<paroneayea>I think they have other conference or work trip things happening iirc
<ehiggs>ok i think ludo is making up for it with his talks in guile + hpc room
<paroneayea>I think we'll expect some good talks :)
<ehiggs>paroneayea: are you going then?
<paroneayea>ehiggs: yes
<paroneayea>I'll be giving a talk on 8sync and moderating a panel
<paroneayea>the talk on 8sync will use a multiplayer text adventure instead of slides ;)
<davexunit>hey paroneayea
<davexunit>ACTION has game controllers accessible to guile now :)
<wleslie>well done
<davexunit>guile-sdl2 0.2 coming soon ;)
<paroneayea>davexunit: ooooh nice.
<davexunit>paroneayea: yeah it definitely makes game dev more fun when you can use a real controller.
<davexunit>ps3 controllers "just work" with linux-libre, and SDL will even map all the buttons and analog sticks for you.
<paroneayea>wow nice.
<paroneayea>davexunit: so speaking of games
<davexunit>they have a low-level joystick interface that let's you use any USB HID joystick, but then there's a high-level "game controller" interface that automagically recognizes certain common controllers. very nice.
<davexunit>ACTION listens
<paroneayea>I am now at the part in the 8sync tutorial where I want to show users how to write their own actors and learn how to do timed/delayed things
<paroneayea>so I was thinking of this, and I wonder if you think it's a good idea or too complicated
<paroneayea>I've already introduced how to do an IRC bot, but I wonder if doing a little "game" over IRC might be fun... maybe one where two people register over IRC to do a "battle", and they have their proxy warriors do some timed battles, but they switch "stances" which have kind of a rock paper scissors mechanic
<paroneayea>I'm sure it would introduce all the things
<paroneayea>but maybe it's too complicated of an example
<paroneayea>but it would probably be fun
<paroneayea>what do you think? am I going overboard
<paroneayea>maybe I should keep that as an "extended example" section or something, I dunno
<davexunit>if you keep the battle mechanics very simple I think it would work
<paroneayea>yeah I think it could be kept simple, probably :)
<paroneayea>maybe I should write it out and see how simple I can get it.
<davexunit>that sounds like a good plan
<davexunit>you could show it to me after or something
<davexunit>to see if it overwhelms someone who doesn't know your api
<paroneayea>ACTION nods
<Partmedia>Hi there. I'm kind of new to Guile and I'm wondering if there's a good resource on return conventions. For instance, what should a function do when it could return a string or nothing (like Maybe's in Haskell)?
<davexunit>Partmedia: you just return a string in the case that you want to return a string
<Partmedia>Also, when writing code that checks for errors I find myself doing (let ((result (blah)) (if (null? result))... there seems there should be a better way to do this?
<davexunit>null? isn't an error checking mechanism
<davexunit>the guile manual has a section on exceptions and error handling
<Partmedia>well, as an example in point the string-match returns a match object or #f
<Partmedia>and for i/o I'd check eof-object? but it all involves a let/if check and I was wondering if there was a better way to do it
<davexunit>that's the way
<davexunit>there's things like and=> that apply in certain cases
<davexunit>or and-let in SRFI-2
<davexunit>in Scheme it's all what you make of it.
<Partmedia>ACTION attempts to digest and-let...
<Partmedia>But I take it most people check errors by doing let/if?
<davexunit>something like that
<davexunit>that's a no syntax sugar way to do it
<davexunit>it's not really correct to call them errors
<davexunit>error handling is done with 'catch' and co. usually
<Partmedia>thanks, I'll keep that in mind
<davexunit>good luck!
<davexunit>scheme is quite different from haskell, but you'll get the hang of it.
<davexunit>:)
<OrangeShark>Partmedia: you could use lists to be similar to Maybe in haskell. Where '() represents nothing and (x) be something.
<OrangeShark>you can also use the fact any non #f value is considered true
<Partmedia>thanks davexunit, OrangeShark. It takes a while to figure out what the canonical way to do things is. But with guile I imagine there's less of a "canonical" way :p
<dsmith>Hey hey Guilers
<dsmith>sneek: botsnack
<sneek>:)
***random-nickname is now known as random-nick