|
|
Xna 2.0
About Truespace Archives
These pages are a copy of the official truespace forums prior to their removal somewhere around 2011.
They are retained here for archive purposes only.
Post by TomG // Feb 29, 2008, 6:58pm
|
TomG
Total Posts: 3397
|
Hi all,
As many of you know, I am rather partial to games and gaming :) So I did some experimenting with the recently released XNA 2.0, which imports X format (it also imports OBJ with some extensions that are freely available, but I've not looked into that yet).
I will probably post a test or two more, but after succesfully porting Stephen May's bus from the course and galleries and my own supply ship over onto my XBox 360, I decided to give it a challenge with Marcel's spaceship (which he sent for me to try out).
It's a fairly poly heavy object, over 100K vertices if I remember, and is not intended to fly around in a game. All the same, I was able to fly it around very smoothly in a default scene with default lighting, which was fun! Video is attached, zipped WMV.
This is recorded on my regular digital camera, not video camera, and then converted from AVI into WMV, so has lots of compression and poor frame rate in its capture (not a videographer, so I have no good video hardware in my collection of electronic whatnots!).
I haven't set up anything in XNA but the basic tutorial for moving a 3D object around, so there's no adjustment to give a sense of mass etc in how it turns, but there could be, wouldn't take much work (and I might do it just for the fun of it!). All the same, I find it rather cool to be able to fly this ship around in real-time on a console! As well as Stephen's bus, and my supply ship :)
There's nothing beta or in development or new here, all this is using software and pacakges that are already released and out there for anyone right now - this is tS7.51 (X format export from the Model side), XNA 2.0 Studio Express (free), and a Creators Club subscription (around $100 per year) in order to send it to my 360. It is all something I'm exploring as the subject interests me personally. I figured other game enthusiasts might be interested to know that tS makes a viable tool for working alongside XNA, to make 3D content to go in there.
Without Creators Club, I could still compile and fly the ship on the game compiled for my PC. That means tS owners could get into making games at zero cost with XNA. In this case though I wanted to go one stage further since the 360 side of things had grabbed my attention with the recent GDC announcements of Dreamspark, and of the community Live that will see peer review of games to get them distributed via XBox Live, which is pretty neat I think for indie games. Already been trying out the time limited demos that came out.
I haven't done tests, but I suspect good results should be possible using earlier versions of tS and their X format export too. Haven't yet moved into exporting animations, etc either, but again I'll likely experiment since I have such a love of games and I like to explore this kind of stuff!
I remember back when I used to look at photos of dev kits for consoles, which cost thousands or tens of thousands, and thought it would be fun to be able to run stuff on a console. How times have changed!
Thanks Marcel for letting me borrow the ship, I'll get it back to you in one piece (though there is that tutorial that says you can blow up any object into little pieces... hmm....)
Tom |
Post by jamesmc // Feb 29, 2008, 7:40pm
|
jamesmc
Total Posts: 2566
|
Coolness
Amazing it handled that many polys |
Post by noko // Feb 29, 2008, 7:43pm
|
noko
Total Posts: 684
|
Awesome I have to say. Need to check out the full path here. Now how did you do that again? I mean exporting so that 360 can play it? |
Post by Liger ZERO // Feb 29, 2008, 7:47pm
|
Liger ZERO
Total Posts: 124
|
Cool stuff Tom. It's funny I was looking into Xna 2.0 myself. It looks vary streamlined and easy for programing. I have done some 2D games with Direct X from scratch but xna looks easy compared to it. |
Post by W!ZARD // Feb 29, 2008, 10:46pm
|
W!ZARD
Total Posts: 2603
|
Hi all,
... after succesfully porting Stephen May's bus from the course
Tom
Hey that's pretty damn cool!! I hope you didn't find it too hard to drive with steering wheel on the "wrong" side! :D:D |
Post by TomG // Mar 1, 2008, 12:41am
|
TomG
Total Posts: 3397
|
The path is pretty simple
From tS, save to X format from the Model side. In XNA 2.0, load that model as part of the content for that solution, and get some code in there to display it, move it around etc. Run XNA Game Launcher on your 360 (you need to be in the Creators Club for that). Hit Debug in XNA on your computer, and it all gets sent over to the 360 via a regular network.
And that's it, it's done. Now that its been sent to the 360, you can play that "game" at any time (this one isnt really a game, just basic display and move the model) from the 360.
Its very painless. Took me about 10 minutes to move my first model - Stephen May's bus - over to the 360 (no move controls, just automatic rotation of the model so you can view it) and I didnt really have any hitches - needed to scale the model up when loaded into XNA but that was all.
Marcel's ship is textured with workspace real-time shaders, so I had to repaint it in the Model side (and it doesnt look quite as good as a result!), and that has been the biggest "work" so far. Other than that I have to say that it is pretty easy and painless.
Liger, XNA will be easy compared to coding from scratch, most of the "hard work" is done for you programming wise. Want a 3D model, just load one into the content and say "Draw this" basically. Of course the real hard work comes in making a game out of anything, and you still need to do all that - figure out the game logic, what makes a good game, make it all work together properly, etc. But the lower end items are all managed for you, down to things like having functions that return the state of the 360 controller thumbsticks, triggers, buttons etc - so a few simple function calls can get and set a lot of stuff. Frees you up to concentrate on the game itself.
You can write customer importers for XNA, they use OBJ as an example with full code, so that would give another route from tS to XNA. In theory that means an SCN, COB, RSSCN, or RSOBJ importer could be written too. I've not checked all that out yet though, once I found X format working well, I didnt need to go exploring OBJ :)
HTH!
Tom |
Post by rjeff // Mar 1, 2008, 6:27am
|
rjeff
Total Posts: 1260
|
Tom is that a file that can be shared with other 360 users? As in you can send it to me, size permitting, and then I could "play" it on my 360. I have heard about the Creators Club..many MS is really opening the door wide here. This might hurt the PS3. Very good idea from the MS...and now that they own us..it might get some strealimed tools for us to use. Is it totally possible to build an entire level and imort that in and walk around in it? |
Post by TomG // Mar 1, 2008, 9:20am
|
TomG
Total Posts: 3397
|
No, the file can't be sent to other 360 users directly.
The process for sharing is this. You send in your file for peer review. You have to have it bug tested, and you have to submit descriptions of its violence, sexual content, etc. Then there is a wait while other Creators Club members download it, play it, check it is bug free, and most importantly check that you have described its content accurately.
This peer review process seems to be at the heart of this, and is a good idea to my thinking. Rather than have company execs of one form or another review everything that is submitted, why not have things looked over by actual game authors?
There's a whole description of the peer review process that I suggest reading, it's very informative. The peer review process will even look to see who is a good reviewer, and then reviews from the good reviewer will count for more than those from someone who doesn't review much, or whose reviews have proven wildly inaccurate.
Note that "review" here is in the technical sense, not the journalistic sense :)
Here's the Gamasutra article, not sure if you'll need to be signed in to read it:
http://www.gamasutra.com/view/feature/3545/sponsored_feature_democratizing_.php
Entitlted "Democratizing Game Distribution" its a detailed look at the process.
Naturally I will not be submitting this tiny non-game demo to go through that process :) There's nothing worth sharing or seeing since really there is no game there, its just basic movement of the spaceship model to demo getting tS content through XNA and onto the Xbox 360, a "proof of concept" only.
However if I did write a game at some point, then yes, I would have the means to send it out across XBox Live to any interested XBox owner who wanted to play it!
HTH!
Tom
EDIT - Oops missed your level question. Yes its possible, seems that XNA loads X format (or FBX) to use as levels, doesn't use any special "magic" format. I've not looked into the technical aspects of how its done, you'd need models for the visual part of the level, and models for the collision / bounding box parts, it seemed to me from my very first short glimpse at the "Ship Game" demo. I've yet to fire up and run "Racing Game" demo (and yes, I am tempted to put bus, supply ship and spaceship into that and race those around the track!).
Given that XNA is based on C#, there really is "nothing you can't do" because you just extend it in any way you like (and most likely there is a lot of content from users out there already, just as you can add LightMaster and Backup scripts into tS, you can likely find a collection of libraries to do one thing or another - plus the example games provide a lot of that already too). |
Post by rjeff // Mar 1, 2008, 2:27pm
|
rjeff
Total Posts: 1260
|
well darn I wanted to experiment with this..but right now my programing knowledge is zilch. Wonder if the xna is eaiser to learn than outright c |
Post by Liger ZERO // Mar 1, 2008, 4:14pm
|
Liger ZERO
Total Posts: 124
|
Good to see it's as easy as it looks. The only reason I did not get vary deep into game programing is because of the little stuff you had to program. Being able to focus on just the game part sound much more enjoyable. I don't mind programming the AI, Game play, or even some of the physics.:D |
Post by TomG // Mar 2, 2008, 8:33am
|
TomG
Total Posts: 3397
|
C# is easier than C, but it is still a fully-fledged programming language. Even with most of the low level stuff done, you'll still be doing some pretty serious programming to implement any sort of game. You'll need to know about variable types, scope of declarations, methods and properties, programming logic, and so on.
As a langauge, I like C# a lot (having sampled quite a few in my time), but I can't say anything other than that it is a full programming language and that you would need to learn it to code in XNA. So while you won't need to get into the intricacies of coding a 3D engine as that part is done for you, you will still need to know programming.
Of course there are plenty of examples, right up to "mini games" you can download and pick apart to see how they work, plus plenty of code snippets you can cut and paste, plus forums for folks to share advice and ask questions.
If you want to know more, just download it and try it out on the PC, won't cost anything, and you can take a look and see how easy you find it to learn by writing and compiling and looking at the examples for the Windows. If you get on well with it, you can invest in Creator's Club if you do want to start sending code over to your 360, but at least you'll know for sure before you dive in :)
HTH!
Tom |
Post by clintonman // Mar 2, 2008, 12:34pm
|
clintonman
Total Posts: 304
|
3DBuzz is a good place for learning. They sell video training for XNA programming. I think they have free samples of their XNA second volume.
www.3dbuzz.com |
Post by Greenthunder // Mar 3, 2008, 7:54am
|
Greenthunder
Total Posts: 10
|
Actually, the first version of XNA is what got me interested in C#. I have dabbled in VB6 and was thinking of learning C++ to do some game programming, but when checked out XNA 1.0, I decided to try C#. I took a on-line course on beginning C# from a college in Ontario here, and now I am going through a free tutorial on creating a 2-d game with DirectX. I wanted to learn the C# language, and then delve into the XNA framework after I have a good understanding of C#. And of course I want to use tS for creating my 2-d and 3-d objects :).
Jeff |
Post by Michael Billard // Mar 3, 2008, 8:03am
|
Michael Billard
Total Posts: 125
|
I'm coming from the opposite side: I have used C# since 2002 and dabbled in XNA since 1.0, but getting the artistic side of my brain to switch on has been challenging. I've found XNA to be a pretty good development platform for games, much easier than my attempts to learn DirectX. While it's easier than it used to be, there is still a bunch you have to do to make a good game. I'm sure later releases of XNA will close that gap even further.
If I can ever get the darn thing finished, the YF-19 Saber model I'm working on will go into a game too. That's what it was originally designed for: a near-future Wing Commander-esque shooter. |
Post by brotherx // Mar 4, 2008, 12:22am
|
brotherx
Total Posts: 538
|
I was a C programmer back in the days when K&R C was still used and ansi C was just becoming. I like the language...C++ too but C# is just easier and have been using it for nearly 5 years in my job, as the primary language for the last 4 years. It is as simple or complicated as you want. It has enough in common with C++ to make it powerful but doesn't leave you fighting with pointers.
It's just nice. I still like C++ for the power though - it is massively superior when it comes to serious crunching of data but to be honest, I've not used it seriously in years. |
|