IRC channel logs

2015-06-16.log

back to list of logs

<nalaginrut>morning guilers~
<Mikko->good morning
***michel_mno_afk is now known as michel_mno
<civodul>Hello Guilers!
<dsmith-work>Morning Greetings, Guilers
<amz3>héllo gals and guys, I've put together a mini-game using sly game engine
<amz3>the code is https://git.framasoft.org/a-guile-mind/sly/commit/5dbec363e243ae6cc4bea7abb8a195cd8312da21
<amz3>I was going to say, that maybe you would be more willing to try if you had glimpse of it
<amz3>the answer my friends... is I am working on it
<amz3>the sprites are pretty minimalist, I was working on doing animations
<amz3>I means sprites == plain squares
<amz3> https://i.imgur.com/udjBAFb.png
<amz3>it's clone of magical drop, you have to align vertically at least three square of the same color to make them disappear
<amz3>all arrows do something, left right to navigate, and up down to fetch pull squares
<civodul>fun!
<amz3>you can only pull sqaure of the same color (or push everything and pull the new color)
<amz3>it lakes some animations but it playable
<amz3>s/fetch/push
<amz3>thanks :)
<amz3>sly is fun
<amz3>it makes learning guile way of programming easier than hacking randomly
<davexunit>cool stuff amz3
***michel_mno is now known as michel_mno_afk
<ArneBab>amz3: I got “ You need to sign in before continuing. ”
<amz3>ArneBab: it's fixed
<ArneBab>amz3: thanks!
<ArneBab>amz3: wow, that’s pretty long…
<ArneBab>I hadn’t expected such a big use-modules block :)
<amz3>I did not clean those
<amz3>mainly sprite thing must removed
<amz3>I'm using a basic mesh (make-square) instead of an image
<amz3>the idea, is that you only need squaredrop.scm and sly nothing else...
<amz3>but this won't last long, except if I draw the assets programmatically
<davexunit>ArneBab, amz3: on sly master, you can simply import (sly) to get most things
<davexunit>I've made enough example programs to know which modules are required to do anything useful
<davexunit>so the sly module re-exports all of those symbols
<ArneBab>oh, nice!
<ArneBab>amz3: that’s a cool Idea
<davexunit>amz3: I took a look at your code and noticed a problem.
<davexunit>you have a <player> record
<davexunit>that is in a signal
<davexunit>or rather part of the game state
<davexunit>but the <player> record has a timer field that is also a signal
<davexunit>you don't want to do that.
<davexunit>signals are a first-order data type.
<davexunit>none of your game state objects should include a signals
<davexunit>signals sit a layer above them to tie everything together and make the simulation work.
<davexunit>(this should be explained in the manual)
<davexunit>I'll try to remember to add it.
<amz3>then I'm not sure how to animate "push square" because <position> is just a tween lambda which takes (signal-timer)
<amz3>everytime I need to know the position of a square I do (position-tween position (position-timer position))
<davexunit>you animation function is a square -> square function
<davexunit>or should be
<davexunit>or rather square, time -> square
<amz3>yes exact
<amz3>there is both kinds
<davexunit>the way to think about things is: how can I model the state of the game at any given point *without* signals
<davexunit>and then use signals to actually enable the transformation over time so that you have a playable game.
<amz3>I knew in myself I was wrong, I did it nonetheless, that me, a sinner
<amz3>I understand.
<davexunit>;)
<davexunit>it's all good
<davexunit>it's not clearly explained anywhere yet
<davexunit>I did the same thing when I was still wrapping my head around this concept
<amz3>it makes sens, that signals are not part of the state, they "react" to signals it's not part of them
<amz3>part of the states
<amz3>s/them/states
<davexunit>yeah
<stis>heya guilers!
<dsmith-work>stis: hej hej
<amz3>stis: I did not had time to test guile-log, but for sure I'd come to that one day :)
<stis>amz3: take your time.