• What are you working on? v16
    5,004 replies, posted
[QUOTE=likesoursugar;28592907]What's the best way to know if any triangle is behind another triangle(hidden) before actually drawing?[/QUOTE] Here's one way: Project their vertices onto your view frustum's near plane. Create bounding boxes for the projected triangles and check if the bounding boxes intersect. If they don't, the triangles can't intersect on the screen (and can't hide each other), and you can stop checking. If they do, the triangles [i]possibly[/i] intersect on the screen and one possibly hides the other. Calculate somehow which of the triangles is closer (closest distance vertex?). Check each of the farther (projected) triangle's vertices; if any of the triangle's vertices are on the outside of the closer (projected) triangle, it's at least partly visible and you can stop checking. If none are, it's obscured. It's going to be bugged for triangles which actually intersect each other, since you can't determine which one of them is closer to the surface: both of them are partly. Can easily be extended into any convex polygon.
[QUOTE=geel9;28594641]This looks REALLY good for a week into development.[/QUOTE] It's easy to get awesome results fast when you're a good programmer
Today I added a camera and keyboard/mouse input to my 2D game engine. [img]http://tallcorporation.co.cc/projects/psim/camera7.gif[/img]
[QUOTE=geel9;28592148]Stuff[/QUOTE] What kind of beat detection are you using, if its FFT could you give me a hand with that ?
[QUOTE=quincy18;28596697]What kind of beat detection are you using, if its FFT could you give me a hand with that ?[/QUOTE] It's some hacked together algorithm I made myself.
I tried Löve2d about 2 hours now, never done anything in lua before, and I gotta say, I start to fucking love löve :v: It's so amazingly simple :D (As I'm used to xna where drawing simple tiles isn't exactly that easy)
[QUOTE=geel9;28596989]It's some hacked together algorithm I made myself.[/QUOTE] Did you multiply sample rate by time?
[QUOTE=Tangara;28597568]Did you multiply sample rate by time?[/QUOTE] Yes. And then I got permabanned on a forum.
[QUOTE=Tangara;28596040]It's easy to get awesome results fast when you're a good programmer[/QUOTE] Thanks, I think. :P Also, results are not completely based on the experience of the programmer, while that is key to pretty much everything. It's also based on the dedication of the programmer. At least, that's my opinion.
[QUOTE=xAustechx;28597667]Thanks, I think. :P Also, results are not completely based on the experience of the programmer, while that is key to pretty much everything. It's also based on the dedication of the programmer. At least, that's my opinion.[/QUOTE] He was ragging on me.
[QUOTE=ThePuska;28594851]Here's one way: (...)[/QUOTE] That may work, but I'm not sure it'd scale well. Doing projection and other display-related calculations on the CPU, to decide what the GPU should draw, seems like introducing a bottleneck.
Is it possible to save a C# project (.cs) as an (.exe)? Or as any runnable file at all?
[csharp]class MilkShake { public void Bring ( List<Boy> All ) { foreach ( Boy boy in All ) { Yard.Collection.Add( boy ); } } }[/csharp] My milkshake brings all the boys to the yard.
[QUOTE=jomt1234;28599853]Is it possible to save a C# project (.cs) as an (.exe)? Or as any runnable file at all?[/QUOTE] If you're using Visual C#, press F5. [editline]14th March 2011[/editline] Also, this is the best C# method ever created :v: [cpp]Environment.FailFast(null); //It not only fails, it does it fast![/cpp]
[QUOTE=jomt1234;28599853]Is it possible to save a C# project (.cs) as an (.exe)? Or as any runnable file at all?[/QUOTE] Of course it is. Whenever you compile (run it with F5) it creates an executable. It should be in <projectname>/bin/Debug (or release).
[url]http://www.codinghorror.com/blog/2007/10/the-f5-key-is-not-a-build-process.html[/url]
[QUOTE=jomt1234;28599853]Is it possible to save a C# project (.cs) as an (.exe)? Or as any runnable file at all?[/QUOTE] :colbert:
[QUOTE=DevBug;28600179][url]http://www.codinghorror.com/blog/2007/10/the-f5-key-is-not-a-build-process.html[/url][/QUOTE] Okay, fine. F7. :v: Which is how I do it, in my defense.
[QUOTE=DevBug;28600179][url]http://www.codinghorror.com/blog/2007/10/the-f5-key-is-not-a-build-process.html[/url][/QUOTE] Whatever, it still generates a debug build, which is an EXE.
[img]http://i51.tinypic.com/2133uiu.png[/img] Freakin' tokenizer....
[QUOTE=xAustechx;28593611]I've been working on my game for the game development competition. It's coming along very nicely in my opinion. :D It's a 2D, top down RPG game. [media]http://www.youtube.com/watch?v=oMkpiYAZqvM[/media] [/QUOTE] DUDE that looks awesome. How do you do the butterfly AI? i need to make my zombies in my game move around but i cant manage to do it :( Also I think the heart in the top left should slow down abit and only go that fast when your low on health
[QUOTE=Darwin226;28601951][img_thumb]http://i51.tinypic.com/2133uiu.png[/img_thumb] Freakin' tokenizer....[/QUOTE] Why do you have a file for every single operator?
God damn it why didn't I put them in the same file... Well, too late now.
[QUOTE=geel9;28597796]He was ragging on me.[/QUOTE] I know that, I just wasn't sure if he was calling me a good programmer or not. :P
My [url=https://github.com/SergeB/Cucumber]Hobby OS kernel[/url] now support C++... Damn it feels good to be able to write real OOP code again. Still wondering whether I should port and existing STL or roll my own... But first, PCI device detection. Or maybe ACPI tree parsing...
I wish someone could explain rotation matrices to me. I've been reading up on them all day and even though I feel like I know what they do, I've still not managed to put it into practise.
What are you having trouble with?
[QUOTE=Dr Magnusson;28603780]I wish someone could explain rotation matrices to me. I've been reading up on them all day and even though I feel like I know what they do, I've still not managed to put it into practise.[/QUOTE] It's very, very easy. You probably want to use transformation matrices, amirite? Well, you take vector you want to transform, V, and to get the transformed vector, V', you multiply the matrix M by V. V' = M x V. In order to learn how to construct a matrix that does a specific transformation (rotation, scaling, translation...), consult Wikipedia. That's all there really is to it when it comes to 3D graphics.
I've been thinking about replacing the background music of my game. I think that this song blends in very well. [media]http://www.youtube.com/watch?v=6mokylp63Ic[/media]
I've got distance-based mouse scrolling working now, trying to work out an annoying bug that's making everything flicker when the camera moves. It alternates between this: [img]http://tallcorporation.co.cc/projects/psim/problem1.png[/img] and this: [img]http://tallcorporation.co.cc/projects/psim/problem2.png[/img]
Sorry, you need to Log In to post a reply to this thread.