• Programming - WAYWO - V.37
    1,000 replies, posted
[QUOTE=KmartSqrl;40236948]Human eyes are more sensitive to the color green than any other color as well.[/QUOTE] This is why night vision is green :eng101:
you guys are lying to me edit: stop disagreeing with me
[QUOTE=KmartSqrl;40236948]Human eyes are more sensitive to the color green than any other color as well.[/QUOTE] I thought it was lime-yellow. Source: "Why Lime-Yellow Fire Trucks Are Safer Than Red"
[QUOTE=DarkCybo7;40239042]you guys are lying to me[/QUOTE] [url]http://en.wikipedia.org/wiki/Color_vision[/url] [url=http://en.wikipedia.org/wiki/File:Eyesensitivity.svg][img]http://upload.wikimedia.org/wikipedia/commons/thumb/c/c0/Eyesensitivity.svg/220px-Eyesensitivity.svg.png[/img][/url]
-snip- sorry, posted in the wrong thread
[QUOTE=RoflKawpter;40239589]So! I'm programming in Java, trying to do a "where's waldo"-y kind of thing. I have a small image (say 10x10) and I want to be able to find it in a bigger image in terms of returning coordinates. This image will not be scaled or rotated at all. Is there a pre-made library I can use or would I have to make something myself?[/QUOTE] read them in as BufferedImages, then search through the larger using a for loop and getRGB()...at least that's how I did it
[t]http://i.imgur.com/k0DaVj3.gif[/t] making pong for educational purposes with html5 canvas. Always wanted to try it out. Does the player 2 get the point????? you will never know.
were you the one asking about coding collisions in the other thread?
[QUOTE=Zinayzen;40240132]were you the one asking about coding collisions in the other thread?[/QUOTE] yeah
did my suggestion work? :D
[QUOTE=Zinayzen;40240156]did my suggestion work? :D[/QUOTE] It did actually. pretty easy. I just checked if the player is there when it reached certain x-axis. Thanks :D
yay i wasn't actually sure if it would work but i'm glad it did. i also have no experience with html, so i learned something. i think.
[QUOTE=jung3o;40240065][t]http://i.imgur.com/k0DaVj3.gif[/t] making pong for educational purposes with html5 canvas. Always wanted to try it out. Does the player 2 get the point????? you will never know.[/QUOTE] You should take a look at [url=http://calebevans.me/projects/jcanvas/]jCanvas[/url]. also [url]http://liberumgamers.net/data/pong/[/url]
[QUOTE=Mega1mpact;40240315] [url]http://liberumgamers.net/data/pong/[/url][/QUOTE] I get the feeling this wasn't tested enough. Out of the 8 points I scored, 4 of them were from the AI serving itself and failing to hit it back. Maybe I'm just used to Pong AI being infallible.
[QUOTE=Mega1mpact;40240315]You should take a look at [url=http://calebevans.me/projects/jcanvas/]jCanvas[/url]. also [url]http://liberumgamers.net/data/pong/[/url][/QUOTE] I dont see a point of using jcanvas when there is kineticjs. No need to include any other than kinetic.js and my pong.js
[QUOTE=Neo Kabuto;40240526]I get the feeling this wasn't tested enough. Out of the 8 points I scored, 4 of them were from the AI serving itself and failing to hit it back. Maybe I'm just used to Pong AI being infallible.[/QUOTE] The bot is a bit slower then you so it will miss after a while. [code]// Left bot if(bot_l){ if(ball_y - ball_radius > paddle_l+paddle_height/2+ball_radius && paddle_l < $("canvas").height()-paddle_height) paddle_l += paddle_speed_bot; if(ball_y - ball_radius < paddle_l+paddle_height/2-ball_radius && paddle_l > 0) paddle_l -= paddle_speed_bot; } else { // Player input if(keyPressed(87) && paddle_l > 0)paddle_l -= paddle_speed; // Up if(keyPressed(83) && paddle_l < $("canvas").height()-paddle_height) paddle_l += paddle_speed; // Down*/ }[/code] [editline]11th April 2013[/editline] [code]var paddle_speed = 7; var paddle_speed_bot = 5;[/code] [editline]11th April 2013[/editline] [QUOTE=jung3o;40240540]I dont see a point of using jcanvas when there is kineticjs. No need to include any other than kinetic.js and my pong.js[/QUOTE] kinetic.js looks interesting
[QUOTE=Mega1mpact;40240736]The bot is a bit slower then you so it will miss after a while. [/QUOTE] Actually, I mean literally serving itself (no one hit the ball, it went in the AI's direction) and not being able to hit it because it was at too extreme an angle. I think you need to limit the angles the ball can start at more. The times it hit it back were pretty good, and it definitely was beatable in the way you wanted it to be.
Starting to work on my entry for the competition. Lets see who can guess what it obviously is. [IMG]http://i.imgur.com/T0D8cN3.png[/IMG]
Asteroids fps
[QUOTE=Darkwater124;40242132]Asteroids fps[/QUOTE] Not quite. [url]http://en.wikipedia.org/wiki/Star_Wars_(1983_video_game)[/url]
Writing a save system for Unity because I'm hardcore and don't really trust other people's scripts. It's kind of funny how much stuff Unity takes care of.. but it doesn't take care of this.
[QUOTE=garry;40242433]Writing a save system for Unity because I'm hardcore and don't really trust other people's scripts. It's kind of funny how much stuff Unity takes care of.. but it doesn't take care of this.[/QUOTE] If it did, it would probably be too general to be of any actual use.
[url]https://bitbucket.org/goshawk/gdc/downloads[/url] Now I just need to figure out how to get it working
Oh god, love.filesystem's sandboxing makes my blood boil. Emasculate io and os in your boot code, or don't bother at all.
Decided to enter the contest [img]http://puu.sh/2y0kJ[/img]
[QUOTE=ThePuska;40236560]If you've found that with some lerp factor [B]k[/B] and a fixed timestep [B]t[/B], doing the following each tick gives you good smooth interpolation: LastPos = Vector3.Lerp(LastPos, To, k); then the following is equivalent for a variable timestep [B]dt[/B]: double d = 1.0 - exp(dt * log(k)/t); // log(k)/t is constantLastPos = Vector3.Lerp(LastPos, To, d);[/QUOTE] Couldn't you just move it by some factor of the distance per second? [code] NewPos = Pos + ( Desired - Pos ) * k * dt[/code]
[QUOTE=Averice;40243341]Decided to enter the contest [img]http://puu.sh/2y0kJ[/img][/QUOTE] not enough lens flare or camera shack, and it needs more sope.
Got my unity scene save system working! [img]http://i.imm.io/12zzh.png[/img] You add a member to your class and init it.. [img]http://i.imm.io/12zzl.png[/img] And then add the functions.. [img]http://i.imm.io/12zzp.png[/img] Instead of writing some keyname system I decided to do it in pure ordered binary and add versions. I'm not totally happy with the actual usage of it - so I'm gonna have a fiddle with that to see if I can make it a bit friendlier. I like defining specifically which values to save and load, I just don't like all the initialization bullshit. One downside is that this doesn't save/restore any entities that aren't part of the map. But I don't need it to. (yet anyway).
[QUOTE=Falcqn;40243433]Couldn't you just move it by some factor of the distance per second? [code] NewPos = Pos + ( Desired - Pos ) * k * dt[/code][/QUOTE] Not exactly. You can locally approximate the function [img]http://latex.codecogs.com/gif.latex?f(x)%20=%201%20-%20\exp(-cx)[/img] with some linear function [img]http://latex.codecogs.com/gif.latex?p(x)%20=%20ax%20+%20b[/img], so if the variance in the time variable remains really small, you can get away with it. Expanding the f(x) to a Taylor series centered around zero and taking only the linear and constant terms, you get the linear function that best approximates it around x=0: [img]http://latex.codecogs.com/gif.latex?p(x)%20=%20cx[/img] So the equivalent linear approximation for the code [cpp]double d = 1.0 - exp(dt * log(k)/t); // log(k)/t is constant LastPos = Vector3.Lerp(LastPos, To, d);[/cpp] would then be [cpp]double d = (-log(k)/t) * dt; // (-log(k)/t) is constant LastPos = Vector3.Lerp(LastPos, To, d);[/cpp] But this is a good approximation only for dt very close to zero.
[QUOTE=acpm;40236816]an observer illusion, as those colors are closest to the viewpoint origin[/QUOTE] He said it was an error with his settings, stop trying to tell me that I'm imagining things >:(
Sorry, you need to Log In to post a reply to this thread.