• What Are You Working On? May 2015
    1,601 replies, posted
Math bugs best bugs. [video=youtube;JOwf78h7AG0]https://www.youtube.com/watch?v=JOwf78h7AG0[/video] Actual working code: [video=youtube;STRBuqL8DYI]https://www.youtube.com/watch?v=STRBuqL8DYI[/video] As always, code: [url]https://gist.github.com/JohnnyonFlame/9fb77bc9d1f6c75e18bf[/url] (fixed-point arithmetic image fade, requested by a friend)
Slight problem, my 2D game looks better in 3D.. [IMG]http://i.imgur.com/QM2Yml4.png?1[/IMG] Figuring out how to pick and rotate tiles based on terrain took me longer than it should have.
omg i love it
Was bored and making a hovercraft always seemed like fun. Unity. [url]http://a.pomf.se/yklpqo.webm[/url] Quadruple raycast and then uses the collision normal to apply force. You can shift power between the front and rear thrusters to angle the craft as well.
[QUOTE=Go101;47791108]Slight problem, my 2D game looks better in 3D.. [IMG]http://i.imgur.com/QM2Yml4.png?1[/IMG] Figuring out how to pick and rotate tiles based on terrain took me longer than it should have.[/QUOTE] have you thought about using an isometric camera purely top down view like that is really confusing and i can't find any depth in it
[QUOTE=MadPro119;47792035]Was bored and making a hovercraft always seemed like fun. Unity. [url]http://a.pomf.se/yklpqo.webm[/url] Quadruple raycast and then uses the collision normal to apply force. You can shift power between the front and rear thrusters to angle the craft as well.[/QUOTE] I believe the hoverboards for GMod work similarly. It would be fun to have a hoverboard racing game with similar mechanics.
[vid]https://a.pomf.se/fdzqss.webm[/vid] My crappy pong clone in Love2d is coming along nicely, except for one problem. The ball doesn't collide with the paddles. Anybody know how to go about doing it?
[QUOTE=andrewmcwatters;47789793]Hold up, another update, recast your [del]votes[/del] ratings. [img]http://i.imgur.com/CIsWKh3.png[/img] [editline]23rd May 2015[/editline] I'm still trying to get shared to look okay, since it's a gradient it's a bit more difficult. [editline]23rd May 2015[/editline] Here are the new labels for client/server/shared. Yellow, blue, and green. [img]http://i.imgur.com/JvRLVpm.png[/img] [editline]23rd May 2015[/editline] Hope that's more suitable now![/QUOTE] Those "bright(?) red text in a white bubble" elements are hard to look at. I know it's to match the code tags, but that really doesn't work well when there's so much dark grey near it. Maybe it's also broken, considering everything has the same colour... Just a different font maybe and no border would make a lot more sense for these elements, unless they're clickable in which case they should match parts of the style of that interaction type elsewhere. Similarly I think it would make sense to turn types in the table into golden links when they have own pages in your documentation. It would differentiate them in design from system types, but I think in this case that would be a good thing.
[QUOTE=Tamschi;47792207]I believe the hoverboards for GMod work similarly. It would be fun to have a hoverboard racing game with similar mechanics.[/QUOTE] Made a hovercraft in gmod once the same way, used ranger as raycast and thrusters for applyforce. A gyro fed the thrusters when not perfectly upright since ranger can't read collision angle.
[QUOTE=Zelpa;47792354]My crappy pong clone in Love2d is coming along nicely, except for one problem. The ball doesn't collide with the paddles. Anybody know how to go about doing it?[/QUOTE] dong?
[QUOTE=DarKSunrise;47792388]dong?[/QUOTE] lol the fish covers up the bottom of the P.
[QUOTE=Go101;47791108]Slight problem, my 2D game looks better in 3D.. [IMG]http://i.imgur.com/QM2Yml4.png?1[/IMG] Figuring out how to pick and rotate tiles based on terrain took me longer than it should have.[/QUOTE] Maybe you can do what Nintendo did in A Link Between Worlds? [img]http://d1vr6n66ssr06c.cloudfront.net/wp-content/uploads/2013/11/a_link_between_worlds_trick_header.jpg[/img]
[vid]https://a.pomf.se/nvtpqw.webm[/vid] [QUOTE=DarKSunrise;47792388]dong?[/QUOTE] :^) [QUOTE=Trebgarta;47792560]1) Check whether the ball and the paddle overlaps 2)If they do, (-) the speed of the ball on X axis, and randomize the Y speed value Not accurate physics sim, but that's how I did it when I made my pong clone. For Bonus, have the ball's x speed a set value on start (e.g. 10 px) and increment it with each collision with paddles, then set it back to 10 when a score happens. If you can't check for overlaps, maybe check it like: When the ball is in the X of a paddle, check both's Y's if they are colliding (e.g. if the ball is within paddle.Y + paddle.height/2 and paddle.Y - paddle.height/2) Just something I made up now, dunno if it's suitable, I'm just a beginner too.[/QUOTE] that sounds way too simple. i like my code convoluted and horribly inefficient. [t]http://i.imgur.com/HIKv8FQ.png[/t]
So I've always wanted to do this. Our train public trasport system has a pretty bad web interface. It's hard to find the train you want, it doesn't filter bad options and it's generally pretty unusable. So, I wrote a crawler, downloaded all the train info they provide (surprisingly fast), made it into a graph and ran it through Dijkstra's. The result? If you ask their website how to get from Koprivnica to Gunja, it just tells you how to get to Osijek, and then it tells you to look up how to get from Osijek to Gunja (for what ever reason). Fun fact, there are no routs fro Osijek to Gunja. So it actually doesn't give you a route, only points you in a direction. A wrong direction. On the other hand: [code] let res = Cache.loadRoutesFromFile "allRoutes.json" let graph = Graph.graphFromRoutes res let koprivnica = graph.["KOPRIVNICA"] let path = Graph.dijkstra koprivnica "GUNJA"[/code] [img]http://i.imgur.com/5kAOX6x.png[/img]
[QUOTE=Zelpa;47792622] that sounds way too simple. i like my code convoluted and horribly inefficient. [t]http://i.imgur.com/HIKv8FQ.png[/t][/QUOTE] Atleast get rid of the magic numbers.
[vid]https://a.pomf.se/smrguk.webm[/vid] Sorry if I'm posting too much, but this is like the first game I've actually coded so I'm pretty hype. I couldn't find an elegant HSV to RGB for lua so I decided to use a table with like 12 values instead and just cycle through them.
[QUOTE=Zelpa;47792940][vid]https://a.pomf.se/smrguk.webm[/vid] Sorry if I'm posting too much, but this is like the first game I've actually coded so I'm pretty hype. I couldn't find an elegant HSV to RGB for lua so I decided to use a table with like 12 values instead and just cycle through them.[/QUOTE] Make sure to only check for collisions on the paddle if the ball is moving towards it, otherwise it spazzes.
[QUOTE=JohnnyOnFlame;47792961]Make sure to only check for collisions on the paddle if the ball is moving towards it, otherwise it spazzes.[/QUOTE] but it adds character to the game :^) also a center line which I somehow forgot until now. [t]http://i.imgur.com/cIYvjYl.png[/t]
[QUOTE=Zelpa;47792940][vid]https://a.pomf.se/smrguk.webm[/vid] Sorry if I'm posting too much, but this is like the first game I've actually coded so I'm pretty hype. I couldn't find an elegant HSV to RGB for lua so I decided to use a table with like 12 values instead and just cycle through them.[/QUOTE] WAYWO June 2015 v. CONTENT IS NOT SPAM [editline]24th May 2015[/editline] Meanwhile I started working on something interesting last night, related to CS:GO. Basically this: [IMG]http://i.imgur.com/gSIXrmJ.png[/IMG] So far I know when a match is ready, and I got an Android app that works with Google Cloud Messaging (ie. push notifications). Now I just need a server and I got a prototype! [editline]24th May 2015[/editline] If anyone would like to make a Windows/OS X client that'd be cool, since I only use Linux.
[QUOTE=Darkwater124;47793006]a Windows/OS X client[/QUOTE] so.. the game itself? :v: am I missing something
[QUOTE=Perl;47793051]so.. the game itself? :v: am I missing something[/QUOTE] I think he means a client to hook into the game for the app to interact with, since I'm not sure how game to app interaction would work without a middle man.
[QUOTE=Perl;47793051]so.. the game itself? :v: am I missing something[/QUOTE] Something that knows when a game is found, and sends a message to a server that pushes a notification to the Android app.
[QUOTE=Egonny;47792567]Maybe you can do what Nintendo did in A Link Between Worlds? [img]http://d1vr6n66ssr06c.cloudfront.net/wp-content/uploads/2013/11/a_link_between_worlds_trick_header.jpg[/img][/QUOTE] I find it really interesting how when we see Top-down view we find it completely natural, however when you change the perspective and look at it from the side, everything looks completely ridiculous. I was actually wondering how they did it and I'm guessing a simple vertex shader to create the slope is enough, I doubt they would go through the process of making each asset like that :v:
[QUOTE=Egonny;47792567]Maybe you can do what Nintendo did in A Link Between Worlds? [img]http://d1vr6n66ssr06c.cloudfront.net/wp-content/uploads/2013/11/a_link_between_worlds_trick_header.jpg[/img][/QUOTE] I would love to see this in motion.
[QUOTE=Darkwater124;47793269]I would love to see this in motion.[/QUOTE] Probably something to this effect [media]https://www.youtube.com/watch?v=ux2CMNhT9nA[/media]
[QUOTE=Darkwater124;47793006]WAYWO June 2015 v. CONTENT IS NOT SPAM [editline]24th May 2015[/editline] Meanwhile I started working on something interesting last night, related to CS:GO. Basically this: [IMG]http://i.imgur.com/gSIXrmJ.png[/IMG] So far I know when a match is ready, and I got an Android app that works with Google Cloud Messaging (ie. push notifications). Now I just need a server and I got a prototype! [editline]24th May 2015[/editline] If anyone would like to make a Windows/OS X client that'd be cool, since I only use Linux.[/QUOTE] oh man this would be so cool
I've been working on a little backup tool (auto backup options are disabled until the Auto backup button is selected): [thumb]http://i.gyazo.com/5271bf9c20f57dff613d9144b5e8bb64.png[/thumb] I still have to finish up auto backup functionality and fix a bug where an empty file is added to the backup in the folders, then it will be ready for release. [sp]It's also made in Java (I'm sorry).[/sp]
I finally did something serious in c++ and used sfml: [vid]https://dl.dropboxusercontent.com/u/357850863/ShareX/2015/05/2015-05-24_12-32-16.mp4[/vid] [sp]i tried[/sp]
[QUOTE=DarKSunrise;47793402]oh man this would be so cool[/QUOTE] Make it work for Dota too, please?
[url=https://gist.github.com/JohnnyonFlame/2f1133469aa565757d1c]Fade-to-black w/ Dithering![/url] [code] Uint32 mul_a = (Uint16)((sinf(SDL_GetTicks() / 1000.f)+1.f) * 32767.f); Uint32 mul_b = mul_a ^ 0xFFFF; Uint32 r, g, b, err_r=0, err_g=0, err_b=0; Uint16 c; Uint8 *dest = vid->pixels; Uint8 *src = image->pixels; int i, j; for (i=0; i<image->h; i++) { for (j=0; j<image->w; j++) { c = *(Uint16*)src; r = (((c >> 11) & 0b11111 ) * mul_a) + err_r; g = (((c >> 5) & 0b111111) * mul_a) + err_g; b = (((c ) & 0b11111 ) * mul_a) + err_b; err_r = r & 0xFFFF; err_g = g & 0xFFFF; err_b = b & 0xFFFF; r &= 0x1F0000; g &= 0x3F0000; b &= 0x1F0000; *(Uint16*)dest = (r >> 5) | (g >> 11) | (b >> 16); //skip color (2 bytes = 16bit) dest += 2; src += 2; } //skip line (line width - width * color depth) dest += vid->pitch - (image->w * 2); src += image->pitch - (image->w * 2); }[/code] Optmized enough I guess? If you see anything that can be improved, feel free to point it out.
Sorry, you need to Log In to post a reply to this thread.