gamecreator Posted January 22, 2010 Share Posted January 22, 2010 I know it may be counter-intuitive but one of my thoughts is to use Leadwerks for a 2D game. I'm thinking either a platformer or a game like . The question is, how do you implement a 2D game in Leadwerks? My first thought was to create two massive planes, one on each side of the characters, which prevents them from moving in the Z plane. That, combined with resetting all rotations to face the correct way each frame should solve most problems. But what if some characters are wider than others? Do I put down multiple planes? This seems a bit awkward. The second thought was that maybe Newtown's already thought of this. I didn't see this in the Bodies wiki but perhaps there's a way to set it to ignore Z movement. Or, is there a way to detect Z movement and apply a negative force to counter it? Any thoughts and suggestions are appreciated. This is also my first post on the forums so hello all! Oh, finally: how do you access the two locked tutorials on the wiki? I sent Josh an email a few days ago but I guess he's busy. Thanks! Quote Link to comment Share on other sites More sharing options...
macklebee Posted January 22, 2010 Share Posted January 22, 2010 you might be interested in this post at Newton also to get access to the locked tuts, just enter your SDK registration key as the username and password Quote Win7 64bit / Intel i7-2600 CPU @ 3.9 GHz / 16 GB DDR3 / NVIDIA GeForce GTX 590 LE / 3DWS / BMX / Hexagon macklebee's channel Link to comment Share on other sites More sharing options...
Canardia Posted January 22, 2010 Share Posted January 22, 2010 Modern 2D games have always a little 3D effect in them too, look for example how Little Big Planet was made. It's basically a 2D platformer, but you can sometimes move 1 meter in Z-direction too, for example when climbing a stairway up. That can be done in Leadwerks without any special tricks, you just make your level 2 meter deep. Quote ■ Ryzen 9 ■ RX 6800M ■ 16GB ■ XF8 ■ Windows 11 ■ ■ Ultra ■ LE 2.5 ■ 3DWS 5.6 ■ Reaper ■ C/C++ ■ C# ■ Fortran 2008 ■ Story ■ ■ Homepage: https://canardia.com ■ Link to comment Share on other sites More sharing options...
gamecreator Posted January 22, 2010 Author Share Posted January 22, 2010 Thank you. From macklebee's post, it looks like I'll need to investigate 2d joints, as I'm very likely not a good enough programmer to modify the newton code. Lumooja, believe it or not, I've thought of Little Big Planet before this but that just seems a step more difficult, as in something to implement after one figures out how to do single-plane 2D with a 3D engine. In addition to all this, I've used the wonderful pmask collision library before. It's strictly 2D but I can see the possibility of not using Newton and implementing it instead. It would be some extra work, somehow analyzing the 3D world and creating a 2D collision array from it, but it could be done. Quote Link to comment Share on other sites More sharing options...
Rick Posted January 22, 2010 Share Posted January 22, 2010 You could do everything in textures which would give you 2D. CreateTexture() & DrawImage() would give you everything you need for true 2D. Then for collisions you could just use bounding boxes. Quote Link to comment Share on other sites More sharing options...
AggrorJorn Posted January 22, 2010 Share Posted January 22, 2010 Games like Trine and Shadow complex are also good examples for this. Quote Link to comment Share on other sites More sharing options...
Volker Posted January 22, 2010 Share Posted January 22, 2010 This question was asked in the old forum here. I limited the movement to 2D with the code posted there which works fine. For the rotation I found no similar way, so please let me know if you solve it. To limit the rotation I'm using two big boxes between which my ship moves. I had to adjust the body damping, so that the boxes don't decelerate the ship to much. But what if some characters are wider than others? Do I put down multiple planes? This seems a bit awkward. Yes All my ships will have the same z-size to avoid this trouble. Especially in Multiplayer using multiple planes/boxes. Julio (the newton maker) wrote that he is working on something to limit movement to 2D. But I don't know how far he is. Btw: Which newton version is LE 2.3 using? Quote Core2DuoE6570 / Windows7 64bit / 4 Gb RAM / Geforce GTX 260 896Mb / LE 2.3 Dell Inspiron 1720 / Vista SP2 / C2D 2.4 / 8600 GM Link to comment Share on other sites More sharing options...
Rekindled Phoenix Posted January 27, 2010 Share Posted January 27, 2010 Hey that's my post! That never was resolved... at least for me. The team completely redesigned the project because of this hastle. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.