• What are you working on? V5
    2,005 replies, posted
This is a little circular breakout game I wrote in the past 9 hours (from scratch). [img]http://img121.imageshack.us/img121/2217/circlebreakoutboring.jpg[/img] The screenshot is a little boring, but I didn't want to spoil the more interesting parts of the game :v: [url]http://filesmelt.com/downloader/circle_breakout.zip[/url] Details: - written in Java - ~9 hours of work not including various distractions and meals - just run the game.Main class inside /bin/ (should (theoretically) work fine under all platforms due to Java) - on Windows, I made a run.bat inside /bin/ for lazy people like me :v: Comments? Comments on the code would also be appreciated, if you have any.
Nice concept :P. I did notice when hitting the ball though that it would sometimes snap to the middle of the paddle. O apparently I was missing even though I wasn't?
[QUOTE=high;18633510]Nice concept :P. I did notice when hitting the ball though that it would sometimes snap to the middle of the paddle. O apparently I was missing even though I wasn't?[/QUOTE] It was probably right on the edge and it looks like you didn't miss it even though the game thinks you did. Did you play through the whole thing? The later levels get interesting :v:
Ported tooltips from sfml to DirectX [img]https://dl.dropbox.com/u/99765/tooltips002.png[/img] [cpp] tooltipMgr = new ToolTipManager(direct3Ddevice); tooltipMgr->Add("test", ToolTipManager::ICON_ALERT); tooltipMgr->Add("test", ToolTipManager::ICON_INFO); tooltipMgr->Add("test", ToolTipManager::ICON_CROSS); [/cpp] 4:33AM :(
Working/Learning on/about OS dev. from the links windwkr posted, going good and is fun and interesting so far, also frustrating at the same time :banjo:
[QUOTE=efeX;18636437]Working/Learning on/about OS dev. from the links windwkr posted, going good and is fun and interesting so far, also frustrating at the same time :banjo:[/QUOTE] Also using the links windwakr posted, and whipped up this awesome thing. [media]http://www.youtube.com/watch?v=96g-cUhJ2JA[/media] Download: [b][url]http://cloud.anyhub.net/0-turb_demo_os.bin[/url][/b] It's bootable from grub, just stick it in /boot/, then when you boot your PC, go into GRUB's menu, press C for command line and type: [code] kernel /boot/<whatever> boot [/code] [b]Source:[/b] kernel.c - [url]http://pastebin.com/f2de93f4c[/url] loader.asm - [url]http://pastebin.com/f4d481ec1[/url] I'm aware the loader.asm file is copypasta, but I haven't coded a line of assembly in my life, so meh :)
good god man. use a virtual machine fer chrissakes. Also what assembler?
[QUOTE=Chandler;18636603]good god man. use a virtual machine fer chrissakes. Also what assembler?[/QUOTE] Don't jump to conclusions, sometimes it pays to test on the metal (eg. VirtualBox doesn't implement the blink bit in text mode) [img]http://imgkk.com/i/ycwK8k.png[/img] I'm using NASM
So I finally got around to playing around with Java/Android programming. Considering I'm new to all of it, I'm using someone else's engine this first time around. If this turns out successful, and I do work on making a second one, I'll be making my own engine and whatnot. And then I get to deal with the whole fact of making sure that Java [i]does not under any circumstance[/i] allocate memory during gameplay. Watched a Google lecture on it, according to it, when you allocate memory, the GC will halt whatever is happening for 100-300ms. And this is Java, so there is no malloc() sort of stuff. I'm a little rough on this, I've got a long way to go. First thing to learn: Threads. I need to get some for handling various things, like physics/collisions/etc. Although the physics/collision for this first game I have planned out will be relatively nonexistent/extremely simple. Ground is all flat, so there is no reason to set up any advanced collision system, and I just need to make it so you can't walk off of screen bounds. Beyond that, it's AI and such, and making sure it works cleanly and effectively without making a noticable dent in gameplay performance. [editline]01:15AM[/editline] Oh, but on the subject of what I actually did, I've got it drawing a little white square (debug object for the player right now), and you can move it around with arrow keys. Physics thread will just be applying gravity whenever you're not on the ground.
[code] #!/usr/bin/python import subprocess from buildit import * build = Unix('BotSim') build.add_include_directory('include') build.add('src') build.add('src/posix') build.pkg_config('glib-2.0') build.pkg_config('sdl') # Required for lua. (Custom built) build.add_include_directory('/usr/local/include') build.add_library_directory('/usr/local/lib') build.add_library(['lua51', 'GL']) build.C99 build.add_flag(['-pedantic', '-Wall']) def post_build(): # Copy resources to output directory. Not exactly a nice way of doing it but w/e. subprocess.check_call(['cp', '-r', 'res/', build.build_directory]) return 0 build.append_build_step(post_build) try: build.run() except: pass [/code] Yay for Chandler. Bit of polish and this will be an excellent build system.
Thanks blank!
[url]http://www.facepunch.com/showpost.php?p=18533902&postcount=718[/url] [url=http://www.facepunch.com/showthread.php?p=18533902#post18533902]Page 18[/url].
[QUOTE=VoiDeD;18638153][url]http://www.facepunch.com/showpost.php?p=18533902&postcount=718[/url] [url=http://www.facepunch.com/showthread.php?p=18533902#post18533902]Page 18[/url].[/QUOTE] Sweet. thanks :D
Cleaning doesn't seem to work properly though. It's weird. If I use --rebuild I get clean called twice and it works. If I run --clean it gets called once and doesn't remove anything. [code] #!/usr/bin/python import subprocess from buildit import * build = Unix('BotSim') build.add_include_directory('include') build.add('src') build.add('src/posix') build.add_define('GL3') build.pkg_config('glib-2.0') build.pkg_config('sdl') # Required for lua. (Custom built) build.add_include_directory('/usr/local/include') build.add_library_directory('/usr/local/lib') build.add_library(['lua51', 'GL']) build.C99 build.add_flag(['-pedantic', '-Wall']) def post_build(): # Copy resources to output directory. Not exactly a nice way of doing it but w/e. subprocess.check_call(['cp', '-r', 'res/', build.build_directory]) return 0 build.append_build_step(post_build) build.parse_options() try: build.run() except: pass [/code] I also added build_system.add_define.
[QUOTE=blankthemuffin;18638262]Cleaning doesn't seem to work properly though. It's weird. If I use --rebuild I get clean called twice and it works. If I run --clean it gets called once and doesn't remove anything. [code] #!/usr/bin/python import subprocess from buildit import * build = Unix('BotSim') build.add_include_directory('include') build.add('src') build.add('src/posix') build.add_define('GL3') build.pkg_config('glib-2.0') build.pkg_config('sdl') # Required for lua. (Custom built) build.add_include_directory('/usr/local/include') build.add_library_directory('/usr/local/lib') build.add_library(['lua51', 'GL']) build.C99 build.add_flag(['-pedantic', '-Wall']) def post_build(): # Copy resources to output directory. Not exactly a nice way of doing it but w/e. subprocess.check_call(['cp', '-r', 'res/', build.build_directory]) return 0 build.append_build_step(post_build) build.parse_options() try: build.run() except: pass [/code] I also added build_system.add_define.[/QUOTE] Odd add_define that should have already been there as defined in Unix() :/
Oh it is, why isn't it in System? Because it's language specific?
[QUOTE=blankthemuffin;18638361]Oh it is, why isn't it in System? Because it's language specific?[/QUOTE] Yeah :)
[QUOTE=nullsquared;18633438]This is a little circular breakout game I wrote in the past 9 hours (from scratch). The screenshot is a little boring, but I didn't want to spoil the more interesting parts of the game :v: [url]http://filesmelt.com/downloader/circle_breakout.zip[/url] Details: - written in Java - ~9 hours of work not including various distractions and meals - just run the game.Main class inside /bin/ (should (theoretically) work fine under all platforms due to Java) - on Windows, I made a run.bat inside /bin/ for lazy people like me :v: Comments? Comments on the code would also be appreciated, if you have any.[/QUOTE] That's really fun to play, great concept. Why did you use Java after making a whole thread about why it's "utter shit"? About the sourcecode: Why do you set the defaultCloseOperation to DO_NOTHING_ON_CLOSE and add a window listener that exits on close? You could just use EXIT_ON_CLOSE as defaultCloseOperation. Just out of curiosity, why did you extend JPanel instead of Component? You should enable AA, makes it look much better. [cpp] ((Graphics2D) g).setRenderingHint(RenderingHints.KEY_ANTIALIASING, RenderingHints.VALUE_ANTIALIAS_ON);[/cpp] I noticed that the ball jumps slightly up and down when he's moving because the actual coordinates of the ball are floating point, but when drawing you cast it to integers. If you would use Graphics2D instead of Graphics you can draw with double precision and combined with AA it looks perfectly fluid.
[QUOTE=nullsquared;18633438]This is a little circular breakout game I wrote in the past 9 hours (from scratch). [url]http://img121.imageshack.us/img121/2217/circlebreakoutboring.jpg[/url] The screenshot is a little boring, but I didn't want to spoil the more interesting parts of the game :v: [url]http://filesmelt.com/downloader/circle_breakout.zip[/url] Details: - written in Java - ~9 hours of work not including various distractions and meals - just run the game.Main class inside /bin/ (should (theoretically) work fine under all platforms due to Java) - on Windows, I made a run.bat inside /bin/ for lazy people like me :v: Comments? Comments on the code would also be appreciated, if you have any.[/QUOTE] Very awesome concept. Plays damn well on a tablet PC :D
[QUOTE=Robber;18639090]That's really fun to play, great concept. Why did you use Java after making a whole thread about why it's "utter shit"? [/quote] Well, last Tuesday, I believe, we had a speaker from college come and talk to us about how college is with computer science and all of that. One of his college projects that he demonstrated was very similar to what you just saw, except it had less features. He made a [i]huge[/i] deal out of how the collisions took him several days to implement, how amazing the double-paddle effect is (AKA, make a second paddle and add PI radians to it, as my code does it), etc. So, in no more than 9 hours (lunch time till the time I posted), I not only replicated what he had done (in his own language, thus why I used Java), but added tons of extra stuff too :v: [quote]: Why do you set the defaultCloseOperation to DO_NOTHING_ON_CLOSE and add a window listener that exits on close? You could just use EXIT_ON_CLOSE as defaultCloseOperation. [/quote] My teacher gets impressed by incredibly simple things, so I thought maybe he'd see that anonymous class and cry of amazement. [quote] Just out of curiosity, why did you extend JPanel instead of Component? [/quote] Honestly, I'm not sure. I'm pretty new to Swing - should I have extended Component, instead? The reason I did that was so I could override paintComponent() which is double buffered, since last time I overrided paint() I had to implement my own double buffering. [quote] You should enable AA, makes it look much better. [cpp] ((Graphics2D) g).setRenderingHint(RenderingHints.KEY_ANTIALIASING, RenderingHints.VALUE_ANTIALIAS_ON);[/cpp] [/quote] Oh, cool. Thanks :D [quote] I noticed that the ball jumps slightly up and down when he's moving because the actual coordinates of the ball are floating point, but when drawing you cast it to integers. If you would use Graphics2D instead of Graphics you can draw with double precision and combined with AA it looks perfectly fluid.[/QUOTE] Thanks for the info, will do. [editline]08:46AM[/editline] [QUOTE=Deco Da Man;18639299]Very awesome concept. Plays damn well on a tablet PC :D[/QUOTE] Good to hear, thanks :D
[QUOTE=nullsquared;18639700]Honestly, I'm not sure. I'm pretty new to Swing - should I have extended Component, instead? The reason I did that was so I could override paintComponent() which is double buffered, since last time I overrided paint() I had to implement my own double buffering.[/QUOTE] I'm not sure if it does have any disadvantages to extend JPanel, but having to implement double buffering sounds like a good reason not to extend Component instead of JPanel. I never knew that paintComponent is double buffered; you never stop learning :v:
Anybody got a good ANSI/Roguelike renderer? Or a way to load a character to be rendered on a quad?
[QUOTE=Eleventeen;18643273]Anybody got a good ANSI/Roguelike renderer? Or a way to load a character to be rendered on a quad?[/QUOTE] You can render a character on a quad using SFML.
[media]http://slashingedge.co.uk/dump/mousetrack.png[/media] Remember the mouse tracking fad we had at one point? Well, not really a fad, like 3 people did it. I wrote a... thing... that tracks your mouse position every 100ms of mouse movement, on a webpage, and appends it to a text file which you can then download + analyse. It's pretty pointless but it shows you what people move their mice to the most on a webpage - so it's good for usability testing or whatever. It's running on my website (on the sly). Every 10 seconds it posts the recorded movements to the server. It records the time between mouse movements as well. Every time you resize the window it logs it in the data to be sent to the server too, so it keeps on working when you resize. Although the python analyser script I hacked up for it has a massive flaw I've only just thought of; you need to have a screenshot of the page beforehand, and if their window's a different size to yours when you screenshot it then margins + padding etc. could be different so my simple 'scale the dots to match the image res' math doesn't work.
[img]http://4.bp.blogspot.com/_9c1HhVyAaQk/SxLA16K4KUI/AAAAAAAAABE/INKvjxnLhU4/s1600/SHADDERZZ.png[/img] Pixel shaders FUCK YEAH!
[img]http://facepalm.se/img/atmosphere7.png[/img] I wonder if we can find water on that new planet...
?
[QUOTE=garry;18628156]Of course I have a fucking right to complain. It's mine. I created it. I still own the rights to it. No-one wins from re-making it. You can't sell it or anything like that. You're always gonna be in a legal grey area. Where as you could use the same mechanics but don't call it Facewound and don't use the same art - and then you can do whatever you want with it.[/QUOTE] That's kinda what I meant. I wasn't talking about someone coming and blatantly using all your work and your title for their own game with the same mechanics. That would in fact be illegal (depending on what license you use to distribute the game) But if someone wants to make new, open-sourced code that works with your content, you still hold the distribution rights and while they can distribute their code and executable, the content remains yours and they can't provide it. Many open-source projects are like this. Like Marathon: Aleph One, the open-sourced and technically superior release of Bungie's old Marathon 3d engine. Bungie can't really stop something like this, and it's probably not in their best interest to anyways.
[QUOTE=efeX;18650466]?[/QUOTE] Just showing the new atmospheres in my planet renderer. Now I need to make some kind of procedural generator so I can get terrain with more detail.
[QUOTE=dezek;18652001]Just showing the new atmospheres in my planet renderer. Now I need to make some kind of procedural generator so I can get terrain with more detail.[/QUOTE] I can see seams on your planet also. Cool though. What are you using?
Sorry, you need to Log In to post a reply to this thread.