• What are you working on? v16
    5,004 replies, posted
Today's project was a multiplayer line-drawing program. [media]http://tallcorporation.co.cc/projects/ndraw/ndraw.PNG[/media] You can host a server or connect to someone else's on any avaliable UDP port (it uses 12345 by default). If anyone wants to try it, [url=http://tallcorporation.co.cc/projects/ndraw/ndraw_0.7.5.rar]here is a download link[/url].
Started working on a little 3D engine using SDL, just as a test to play around with it. One thing I like about Linux is that it makes developing easy because I can just go into the Software Center and download all the necessary files and headers for 3rd party libraries. No content to show of as it's just subsystem architecture, but I'm sure I'll have something tomorrow.
real hackers drink starbucks and use objective c, ruby on rails and mac os x~
real hackers use a steady hand and a magnetized needle.
[img]http://img560.imageshack.us/img560/6721/handy.png[/img] last post about my C# syntax highlighter.
[QUOTE=ThePuska;28522171][img_thumb]http://img560.imageshack.us/img560/6721/handy.png[/img_thumb] last post about my C# syntax highlighter.[/QUOTE] So I heard you like syntax highlighting [url]http://codebin.codeandnoodles.com/[/url]
[QUOTE=ThePuska;28522171][img_thumb][URL]http://img560.imageshack.us/img560/6721/handy.png[/URL][/img_thumb] last post about my C# syntax highlighter.[/QUOTE] Protip: Putting all your code on one line in an unreadable mess doesn't make it faster.
Nice feature to in-operate it into shell, although I don't see how that will become useful in the long run.
This evening I wrote a 3D RPN-based grapher for fun. It can do polynomials: [img]http://ahb.me/24Zj[/img] Trigonometry: [img]http://ahb.me/24Zl[/img] Some more trigonometry: [img]http://ahb.me/24Zm[/img] It uses GDI+ for rendering and I promise there's no else-ifs. Download here if you want to play with it: [url]http://anyhub.net/file/24Zt-3dgraph.exe[/url]
is that you...?
[QUOTE=efeX;28523025]is that you...?[/QUOTE] Who, what?
[QUOTE=efeX;28523025]is that you...?[/QUOTE] It's turb_.
[QUOTE=Qombat;28523046]It's turb_.[/QUOTE] was thinking it was null because of the theme and grapher :v:
[QUOTE=efeX;28523235]was thinking it was null because of the theme and grapher :v:[/QUOTE] I'm just using that theme because I'm running Windows in a VM. [editline]10th March 2011[/editline] [img]http://ahb.me/251p[/img] :psyboom:
Working on a platformer game that involves music and zombies and ninja's currently I have some basic physics, animations and a particle engine. Demo : [media]http://www.youtube.com/watch?v=Tm9nfWsWfiM[/media] I also have 2 weird bugs that I just can't fix, I added some annotations for the ones interested in helping me. source : [url]http://www.mediafire.com/?rc7ddo09gnr68zd[/url]
[QUOTE=quincy18;28523795]Working on a platformer game that involves music and zombies and ninja's currently I have some basic physics, animations and a particle engine. Demo : [media]http://www.youtube.com/watch?v=Tm9nfWsWfiM[/media] I also have 2 weird bugs that I just can't fix, I added some annotations for the ones interested in helping me. source : [url]http://www.mediafire.com/?rc7ddo09gnr68zd[/url][/QUOTE] Some alpha fading would be nice for the particle aura thing.
It has alpha fading but for some reason if you set the blend mode to multiply the it won't fade at all. you can look at the particles behind the player when runs, they do fade :)
Just out of boredom I made a simple bigint class in C++. It's missing a lot like divisions and multiplication is done without any specialized algorithm. It works with std::bitset so all stuff is done in binary. So far only unsigned integers. To see how fast it is, I calculated factorial of 1000 using it. It took 242 seconds with multiplications and conversion back to decimal combined. I guess it's not really fast. To do the conversion back to decimal I first convert it do BCD and from there to decimal (is there a better way? any algorithm?). The result (just because I can): [code]40238726007709377354370243392300398571937486421071463254379991042993851239862902 05920442084869694048004799886101971960586316668729948085589013238296699445909974 24504087073759918823627727188732519779505950995276120874975462497043601418278094 64649629105639388743788648733711918104582578364784997701247663288983595573543251 31853239584630755574091142624174743493475534286465766116677973966688202912073791 43853719588249808126867838374559731746136085379534524221586593201928090878297308 43139284440328123155861103697680135730421616874760967587134831202547858932076716 91324484262361314125087802080002616831510273418279777047846358681701643650241536 91398281264810213092761244896359928705114964975419909342221566832572080821333186 11681155361583654698404670897560290095053761647584772842188967964624494516076535 34081989013854424879849599533191017233555566021394503997362807501378376153071277 61926849034352625200015888535147331611702103968175921510907788019393178114194545 25722386554146106289218796022383897147608850627686296714667469756291123408243920 81601537808898939645182632436716167621791689097799119037540312746222899880051954 44414282012187361745992642956581746628302955570299024324153181617210465832036786 90611726015878352075151628422554026517048330422614397428693306169089796848259012 54583271682264580665267699586526822728070757813918581788896522081643483448259932 66043367660176999612831860788386150279465955131156552036093988180612138558600301 43569452722420634463179746059468257310379008402443243846565724501440282188525247 09351906209290231364932734975655139587205596542287497740114133469627154228458623 77387538230483865688976461927383814900140767310446640259899490222221765904339901 88601856652648506179970235619389701786004081188972991831102117122984590164192106 88843871218556461249607987229085192968193723886426148396573822911231250241866493 53143970137428531926649875337218940694281434118520158014123344828015051399694290 15348307764456909907315243327828826986460278986432113908350621709500259738986355 42771967428222487575867657523442202075736305694988250879689281627538488633969099 59826280956121450994871701244516461260379029309120889086942028510640182154399457 15680594187274899809425474217358240106367740459574178516082923013535808184009699 63725242305608559037006242712434169090041536901059339838357779394109700277534720 00000000000000000000000000000000000000000000000000000000000000000000000000000000 00000000000000000000000000000000000000000000000000000000000000000000000000000000 00000000000000000000000000000000000000000000000000000000000000000000000000000000 00000000[/code] I used 10000 bit integer in this case, but I can modify the size of the used bitsets.
[QUOTE=quincy18;28523795]Working on a platformer game that involves music and zombies and ninja's currently I have some basic physics, animations and a particle engine. Demo : [media]http://www.youtube.com/watch?v=Tm9nfWsWfiM[/media] I also have 2 weird bugs that I just can't fix, I added some annotations for the ones interested in helping me. source : [url]http://www.mediafire.com/?rc7ddo09gnr68zd[/url][/QUOTE] The bug is due to the order in which you're doing your collision checks. I don't remember exactly how to fix it, but I guess you're storing every tile in one vector and looping through that.
[IMG]http://i.imgur.com/G0fXb.png[/IMG] Well, the framework of the game works, but it eats up my CPU. I'm guessing this is because the main loop has no restrictions, so it's just running itself ragged. When I was playing with SFML I just used an SFML method to restrict the framerate of the game to 60FPS, but then again, other games work fine without doing that, so why can't I? How would you guys recommend I prevent my main loop from overdoing itself? I'm thinking of using a CurTime() kind of system to force the game to wait a fraction of a second before ticking again, but I'm not sure whether thats a good idea or not. I guess the only way to find out is to try :v: [editline]10th March 2011[/editline] Double page king :x
sleep(1)
sched_yield/Sleep(0) might be the way to go. But anyways, what's bad about it? You want the game to run as fast as it can - and it does.
[QUOTE=ZeekyHBomb;28527389]sched_yield/Sleep(0) might be the way to go. But anyways, what's bad about it? You want the game to run as fast as it can - and it does.[/QUOTE] I suppose, but it just doesn't seem very good for a nearly empty project to be taking up 99% of my CPU power.
[QUOTE=Kopimi;28527402]I suppose, but it just doesn't seem very good for a nearly empty project to be taking up 99% of my CPU power.[/QUOTE] You should limit the FPS to some reasonable number, like 60.
[QUOTE=Dlaor-guy;28527825]You should limit the FPS to some reasonable number, like 60.[/QUOTE] If you're going to limit the framerate, use v-sync. If you don't want v-sync then cap it at like 250-300. Thats the best course of action IMO anyway.
[QUOTE=Kopimi;28527402]I suppose, but it just doesn't seem very good for a nearly empty project to be taking up 99% of my CPU power.[/QUOTE] [cpp]int main() { while(true); }[/cpp] That would be a reasonable program to take up all processor time. Useless, but still reasonable. And if you were to replace that ';' with your actual game-code .. well, it'd still be reasonable :) You really have to ask yourself if it is any bad that it takes up all the CPU time. If you don't want that, then a fixed framerate is what you want. If you want it to run as fast as possible, then it's the very definition that it will take all available resources.
[QUOTE=ZeekyHBomb;28527916][cpp]int main() { while(true); }[/cpp] That would be a reasonable program to take up all processor time. Useless, but still reasonable. And if you were to replace that ';' with your actual game-code .. well, it'd still be reasonable :) You really have to ask yourself if it is any bad that it takes up all the CPU time. If you don't want that, then a fixed framerate is what you want. If you want it to run as fast as possible, then it's the very definition that it will take all available resources.[/QUOTE] To expand on that, it depends on what type of game you are making. If you're making a casual 2D rpg game then your users might alt tab, browse a bit, go on msn or whatever. You don't want to sap their CPU's. If you're making the next Crysis I doubt people will start bawwing over your game using up CPU power. They'll be bawwing when it's not making effective use of it.
I can't see why you would want to run your game at 1000fps. Your fps will be pretty much capped to the monitor's update rate (usually around 120hz), but your computer struggles to give you the extra 880 frames anyway.
[QUOTE=DarKSunrise;28528089]I can't see why you would want to run your game at 1000fps. Your fps will be pretty much capped to the monitor's update rate (usually around 120hz), but your computer struggles to give you the extra 880 frames anyway.[/QUOTE] Maybe the game update rate is tied to the screen update rate?
[QUOTE=ZeekyHBomb;28527916][cpp]int main() { while(true); }[/cpp] That would be a reasonable program to take up all processor time. Useless, but still reasonable. And if you were to replace that ';' with your actual game-code .. well, it'd still be reasonable :) You really have to ask yourself if it is any bad that it takes up all the CPU time. If you don't want that, then a fixed framerate is what you want. If you want it to run as fast as possible, then it's the very definition that it will take all available resources.[/QUOTE] That makes sense. I'm without much experience in optimizing things like this mainly because I've never made things like this. I just saw it taking up a ton of CPU and figured that was a bad thing. I would still like to limit the framerate, because like DarKSunrise said, I don't want my FPS to be in the thousands, with the game pushing out 700FPS while my monitor is only getting so many of them. Thanks for the posts though, great advice :buddy:
Sorry, you need to Log In to post a reply to this thread.