Re: [Video] Game development in Clojure (with play-clj)

2015-10-18 Thread Zach Oakes
That function was renamed to `key-pressed?`. On Saturday, October 17, 2015 at 7:32:44 PM UTC-4, amirteymuri wrote: > > Dear James, > is-pressed? can not be resolved for me. Is this a version matter? Is there > still a is-pressed? function? > Greetings > > Am Donnerstag, 27. März 2014 18:07:21

Re: [Video] Game development in Clojure (with play-clj)

2015-10-17 Thread amirteymuri
Dear James, is-pressed? can not be resolved for me. Is this a version matter? Is there still a is-pressed? function? Greetings Am Donnerstag, 27. März 2014 18:07:21 UTC+1 schrieb James Trunk: > > Hi everyone, > > I thought some of you might be interested to watch my screencast about game >

Re: [Video] Game development in Clojure (with play-clj)

2015-10-17 Thread William Swaney
Really enjoyed this. I've done a lot of LWJGL games in Java, but I'm going to try something in Clojure now. Thanks, Bill On Thursday, March 27, 2014 at 10:07:21 AM UTC-7, James Trunk wrote: > > Hi everyone, > > I thought some of you might be interested to watch my screencast about game >

Re: [Video] Game development in Clojure (with play-clj)

2014-04-16 Thread kurofune
Jame's tutorial was right on the money and following it I was able to make a comparable version with Skeletor collecting magic gems in a desert. I am interested in leveraging Clojurescript and async for browser-game development, though, and while there is a core.async Dots game tutorial, it

Re: [Video] Game development in Clojure (with play-clj)

2014-04-16 Thread edbond
Nice video, very cool. Some notes: - you can omit comma ',' in maps {:key value :another value} - can omit contains? in filter: user= (filter :apple? [{:apple? true :x 6} {:apple? true :x 4} {:player? true :x 550}]) ({:apple? true, :x 6} {:apple? true, :x 4}) Thanks again, Eduard On

Re: [Video] Game development in Clojure (with play-clj)

2014-04-16 Thread James Trunk
you can omit comma ',' in maps {:key value :another value} In the interest of readability, I usually add commas when I have multiple key-value pairs on the same row. can omit contains? in filter: Cool - thanks for the tip! Also, thanks to everyone else for your comments. :-) Cheers, James

Re: [Video] Game development in Clojure (with play-clj)

2014-04-15 Thread Kris Calabio
James, I have a question. I see this pattern a lot in the sample code and in your code as well, for example: (defn- move-player [entities] (- entities (map (fn [entity] (- entity (update-player-position) (update-hit-box

Re: [Video] Game development in Clojure (with play-clj)

2014-04-15 Thread Zach Oakes
Kris, the entities are automatically converted back into a vector by play-clj after being returned by a given function. Can you elaborate on what problem you believe is occurring when you don't change it back to a vector? On Tuesday, April 15, 2014 5:26:07 PM UTC-4, Kris Calabio wrote:

Re: [Video] Game development in Clojure (with play-clj)

2014-04-15 Thread Kris Calabio
In one of the callback functions in the defscreen I have a pipeline of functions that do something to the entities vector and return the resulting entities. I do something like this: (- entities (process-entities01) (process-entities02) (map (fn [entity] (- entity

Re: [Video] Game development in Clojure (with play-clj)

2014-04-15 Thread Zach Oakes
I see. If your code requires a vector, I think you will have to coerce the list each time as you are doing. Out of curiosity, what are you doing that makes this necessary? Are you using something like get-in? On Tuesday, April 15, 2014 7:11:56 PM UTC-4, Kris Calabio wrote: In one of the

Re: [Video] Game development in Clojure (with play-clj)

2014-04-15 Thread Kris Calabio
I'm not exactly sure, but I think it's the use of 'conj'. My entities get out of order if they are not vectors. All this might not matter though, because I've started rewriting my game from scratch since I'm using way too many mutable atoms than is necessary. James' screencast cleared a lot of

Re: [Video] Game development in Clojure (with play-clj)

2014-04-15 Thread Colin Fleming
Note that you could use mapv, to perform the map but return a vector (filterv was also added at the same time). On 16 April 2014 11:46, Kris Calabio kriscala...@gmail.com wrote: I'm not exactly sure, but I think it's the use of 'conj'. My entities get out of order if they are not vectors.

Re: [Video] Game development in Clojure (with play-clj)

2014-04-15 Thread Kris Calabio
Thanks, Colin! I wasn't aware of mapv. On Tue, Apr 15, 2014 at 6:08 PM, Colin Fleming colin.mailingl...@gmail.comwrote: Note that you could use mapv, to perform the map but return a vector (filterv was also added at the same time). On 16 April 2014 11:46, Kris Calabio kriscala...@gmail.com

Re: [Video] Game development in Clojure (with play-clj)

2014-04-14 Thread halitolali
Great video, thanks! On Monday, April 14, 2014 5:41:45 AM UTC+3, Kashyap CK wrote: +1 nice video On Mon, Apr 14, 2014 at 3:45 AM, Kris Calabio krisc...@gmail.comjavascript: wrote: Oh great! I guess I must have missed that :P On Sun, Apr 13, 2014 at 3:13 PM, James Trunk

Re: [Video] Game development in Clojure (with play-clj)

2014-04-13 Thread James Trunk
Hi Kris, Thanks for your comment, and I'm very glad that you found the video helpful. I started doing screencasts because I realised that I learn a new concept fastest by watching someone else doing/explaining it - and I figured I might not be the only one. Saying that, I know screencasts

Re: [Video] Game development in Clojure (with play-clj)

2014-04-13 Thread Kris Calabio
Actually, I thought it would be even more helpful if you had the source code available (for searching/skimming). Is that somewhere online? -Kris On Sun, Apr 13, 2014 at 2:47 PM, James Trunk james.tr...@gmail.com wrote: Hi Kris, Thanks for your comment, and I'm very glad that you found the

Re: [Video] Game development in Clojure (with play-clj)

2014-04-13 Thread James Trunk
There's a link to a gist of core.cljhttps://gist.github.com/Misophistful/9892203in the video's description. Cheers, James On Monday, April 14, 2014 12:08:16 AM UTC+2, Kris Calabio wrote: Actually, I thought it would be even more helpful if you had the source code available (for

Re: [Video] Game development in Clojure (with play-clj)

2014-04-13 Thread Kris Calabio
Oh great! I guess I must have missed that :P On Sun, Apr 13, 2014 at 3:13 PM, James Trunk james.tr...@gmail.com wrote: There's a link to a gist of core.cljhttps://gist.github.com/Misophistful/9892203in the video's description. Cheers, James On Monday, April 14, 2014 12:08:16 AM

Re: [Video] Game development in Clojure (with play-clj)

2014-04-13 Thread C K Kashyap
+1 nice video On Mon, Apr 14, 2014 at 3:45 AM, Kris Calabio kriscala...@gmail.com wrote: Oh great! I guess I must have missed that :P On Sun, Apr 13, 2014 at 3:13 PM, James Trunk james.tr...@gmail.comwrote: There's a link to a gist of

Re: [Video] Game development in Clojure (with play-clj)

2014-04-12 Thread Kris Calabio
Great video! I've looked through Zach's examples, and even started coding a game myself. But your screencast helped me have a better understanding of some of the concepts and code that I was having trouble understanding just by looking at the example games. Thanks! -Kris On Thursday, March 27,

[Video] Game development in Clojure (with play-clj)

2014-03-27 Thread James Trunk
Hi everyone, I thought some of you might be interested to watch my screencast about game development in Clojure with play-cljhttps://www.youtube.com/watch?v=9ilUe7Re-RA . Cheers, James -- You received this message because you are subscribed to the Google Groups Clojure group. To post to this