Home » MODDING HQ 1.13 » v1.13 General Development Talk » C#-XNA port anyone?
| C#-XNA port anyone?[message #206211]
|
Tue, 13 January 2009 01:52
|
|
KeldorKatarn |
 |
Messages:37
Registered:May 2006 Location: Germany |
|
|
I'm right now working on creating a C#-XNA port of Jagged Alliance 2.
I'm still in the first stages (right now working on the gamescreen and window UI systems (will enable fully movable and resizable windows etc). I'm also planning to make the game resolution indepentent using these systems.
Just wanted to see how interesting such a project is for the community, although I'll probably do it for myself even if not, for fun an educational purposes.
AS already mentioned the new engine will be based on XNA, largely avoiding its content pipeline thought to keep the game modable, and using IrrKlang for sound (enabling ogg and any other sound sources). Cutscenes will probably be played with simple DirectShow filters.
Usage of XNA will of course enable the use of shaders (for those of your unfamiliar with the technical stuff, no this doesn't mean it's using a 3d engine, shaders work in 2d just as well).
Color replacement on characters, postscreen shaders etc are all possible then.
Of course there is still an immense load of work to do, but a final project would be a very nice (even if not platform independent) platform for further development of new features and should bring JA2 into the 21st century.
Any comments, offers of help or whatever else (except MS bashing please, do that in the offtopic) are welcome. =)
Edit: Communication with the C developers would be helpful too of course since I'll base the port on the currect trunc version of 1.13 and any features which are incomplete and still in development might raise some questions about how or why certain stuff has been done. =)
[Updated on: Tue, 13 January 2009 01:57] by Moderator Report message to a moderator
|
Private 1st Class
|
|
|
|
|
|
| Re: C#-XNA port anyone?[message #206277]
|
Wed, 14 January 2009 00:26 
|
|
zilpin |
 |
Messages:63
Registered:October 2007 |
|
|
Or better yet, Java!
*ducks*
Seriously, C# would be a re-write, not a port, and would gain very little since it is not platform independent (whatever MS might tell you). Although Mono is an impressive achievement, you learn quickly that writing .NET code for Windows & Mono is just as cumbersome as writing C++ code for MS Windows & X Window System.
Everything in JA2 is very tightly knit. Changes to UI impact the AI engine, &vv. The original game was 99% hard-coded, and it still shows.
You would find yourself writing 3/4 of the code from scratch, with the old code being useless for any algorithm recycling. The rest would just be useful for reference on plot script and AI behaviour, but still nothing you could copy over.
That said, if you want to do it, do it.
The code is available, and if anybody wants to use it as a reference to re-write JA2 in C#, or VB, or Java, or Ruby, or Haskell, or APL, they can.
Report message to a moderator
|
Corporal
|
|
|
|
|
|
| Re: C#-XNA port anyone?[message #206295]
|
Wed, 14 January 2009 06:36 
|
|
KeldorKatarn |
 |
Messages:37
Registered:May 2006 Location: Germany |
|
|
@RoWa21, the work is still in the early stages. Let me complete the basic UI functions so I can create a few sample screens, then I can make the code available for you to look at. Right now there's just the basic interfaces for sound, input and graphics going on. I just began this project as a sideproject from something else two weeks ago or so. If you're interested in keeping in touch nevertheless, tell me and I'll give you my ICQ number or email address. What's your experience and background in .NET development btw?
To the others.. it's true that XNA is platform dependent as long as nobody ports it (why the mono people stopped the Mono.XNA project I don't know). C# and .NET (or rather CLI) however are everything but platform dependent. CLI and C# are open standards and Mono is by now capable of running any program up to .NET 2.0 and is preinstalled with at least every Ubuntu version.
Also it is still a port. There is a platform port and a language port. I'm doing a language port, while the platform remains Windows for now.
Saying development in C# is just as cumbersome as C++ is a very strange argument. C# and the entire development platform built around it are made for Rapid Development, C++ is very low end and digs very deep into things that are a lot easier to do in C# because of the vast .NET Libraries.
Also, while I am using XNA for now, because it is simply so far the best and easiest Graphics and Input library for Windows in C#, absolutely nobody will stop anyone from rewriting the necessary classes in on more platform independednt basis. I'm using XNA for now because porting to platform independence takes time and I want this thing to get done first before I target any other platforms.
The majority of the code will be totally low-level-engine independent and simply work with the interfaces and use simple C#, mostly even standard .NET 2.0 level, so it will be fully platform independent on that level. Rewriting microsofts Game class and creating a graphics handling like in their application model is easy enough, just takes some time and someone who knows enough about OpenGL to use it with Mono. THe sound library IrrKlang is .NET capable but fully platform independent and runs on any OS, so theres no need whatsoever to port anything there. Porting input is not necessary since a C# port of the platform indepenent OIS-library is already in the works for Axiom and from what I know basically already running and stable. I'm not going to use it because for my purposes right now XNA will do. So all that would need to be ported is graphics and the XNA application framework (which is already done to a large degree by mono and could be completed by anyone who wants to do it).
I myself simply am not targetting anything but Windows, Ja2 is directX only right now as well anyway. What I want now is port the code to a language who's IDEs support rapid development and easy test driven development and bring the entire low-level engine to the next level, support shader use etc. and basically bring the entire code over to the object oriented standard of today.
Also I might add the possibility for plugins which will make the entire game even more modable and easier to expand.
So yes I'm targetting Windows only with XNA, but saying that the decision to use .NET will make it platform dependent is simply wrong. Final changes to make it platform independent should take a dedicated team of 2-3 people not more than a few weeks once the code is complete and one might even get some changes in to make it run on the X-Box in the end if anyone would want that (would require rewrites to use the content pipeline and a rewrite of the sound-engine part. Also not that much work).
And that I'll have to rewrite everything is simply not true. I will rewrite a lot to turn the C-style pseudo object orientation into a real one, but the basic ideas will be usable 1:1, there's no need to change the basic design or the algorithms. Most of the high-level code will probably be reused by me 1:1 unless I immediately find room for improvement, but there is no need to do any major redesign.
Oh and.. if .NET is such a crappy idea.. then what is this
Quote:DeFrog
* converting the C code to VC .NET
doing in the credits?
Report message to a moderator
|
Private 1st Class
|
|
|
|
|
|
| Re: C#-XNA port anyone?[message #206298]
|
Wed, 14 January 2009 06:56 
|
|
KeldorKatarn |
 |
Messages:37
Registered:May 2006 Location: Germany |
|
|
I'm going to use XNA for graphics just as I said. That means full shader use and full Direct3D9 features. This includes of course 32bit graphics with transparency, but also includes the use of post-screen shaders or any shader effects you can think of that work with textured surfaces. (XNA's 2D sprite graphics are nothing but simply 3d surfaces which all have the same depths basically and without 3d camera use, so it is basically Direct3D, no DirectDraw or something, so of course access to the full programmable pipeline is there).
I am working right now on the basic UI system and I will make sure that in the end the system is flexible enough to adjust its contents to different resolutions and it will also allow to move windows like the dialogue window or stuff like that. Even Drag&Drop between two merc's inventories or crap like that will be easily possible with that. Semi-Transparent windows, postscreen bloom (although I don't know how good that would look with the current sprite quality), dynamic color replacement, rain-shader, stuff like that.. no problem basically. Just needs to be written, the capability will be there of course. That's why I'm doing this in the first place. I want code in a language that supports rapid development, I want a clean object oriented design so new coders can enhance and expand the code without digging through ugly macro-filled decade-old C and I want to bring sound and graphics to DirectX9 standards.
Edit: To let the game basically run on any resolution and even change the resolution at runtime is easy and basically already works now. The challenge is to have the content re-arrange itself depending on the resolution in the end. But that is easy enough as long as 800x600 is kept as a minimum resolution (640x480 will go, I'm not even sure Vista and upcoming Windows7 even still support that resolution anymore) to have enough room. And of course widescreen support will be done.
A basic scaling up of the entire UI while showing a larger section of the tactical map on a screen is VERY easy. But I'd like the game to really use the space it has available, like in the sector inventory or something. And I want that to work dynamically.
But in the end that shouldn't be too easy, I just have to write the necessary UI-classes. I hope to achieve a UI that is as easy and flexible to program as Windows.Forms are in a standard windows application.
Imagine your laptop screen with REAL taskbar and REAL movable and minimizable browser windows 
But don't get too enthusiastic, this will require a lot of time to finish. I basically have to write the game again in another language and even though I don't need to redesign most of it, I still need to write and test it And I'm not talking just a few weeks But I think the end result will be worth it nevertheless =)
[Updated on: Wed, 14 January 2009 07:05] by Moderator Report message to a moderator
|
Private 1st Class
|
|
|
|
|
|
|
|
| Re: C#-XNA port anyone?[message #206331]
|
Wed, 14 January 2009 18:29 
|
|
| Realist |
 |
Messages:28
Registered:September 2005 Location: Duesseldorf, Germany |
|
|
I'm quite interested in this project as well.
Are your specifications fixed or still up to debate?
Report message to a moderator
|
Private 1st Class
|
|
|
|
|
|
|
|
|
|
|
|
| Re: C#-XNA port anyone?[message #206441]
|
Thu, 15 January 2009 23:55 
|
|
BirdFlu |
 |
Messages:438
Registered:September 2007 Location: Lampukistan |
|
|
@KeldornKatarn
Quote:About the specifications... I'm doing this in a somewhat constinuous integration way. Meaning I don't design first, then implement, I rather implement one feature after another as the need arrises You better be careful here.
Quote:I am working right now on the basic UI system and I will make sure that in the end the system is flexible enough to adjust its contents to different resolutions and it will also allow to move windows like the dialogue window or stuff like that. Even Drag&Drop between two merc's inventories or crap like that will be easily possible with that. Been there, done that (but with OpenGL). UI stuff is easy. You have to look at the tile engine, because if that is not working you basically have no game. Look at renderworld.cpp, the function RenderTiles alone has over 800 lines. Porting it can/will be a real pain in the ass.
Then, 2D rendering is different from 3D rendering. I haven't try XNA myself and don't know how it abstracts 2D and 3D rendering (or just rendering). Can you just write plain Direct 3D code? In JA 2 there are calls to blit functions all over the place. I don't know if there is an equivalent in XNA. If there is, you could end up with code that looks like today's code, just with a simpler/nicer setup and in another language. If there is no equivalent, you would have to change and reorder a lot of code and not just low-level engine code.
Then there is the content problem. With simple paletted, 256 color images the final result in XNA will look exactly the same as it dos now. You cannot magically improve it with Direct3D. So, you (or someone else) would have to exchange existing images with better ones. Interface images should be very easy to replace, but tile images can be problematic, because there are quite a lot of them. Then, the STI format is NOT just an image format, it is a multi-image format and it also contains so-called Application Data. So just converting them to PNGs or MNGs won't be enough (but don't let this be your problem).
I would recommend you to look over the whole project and identify the main working areas and develop, at least, a basic plan how to port them. You don't want to end with a half ported project because a part doesn't fit into your new structure.
Report message to a moderator
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| Re: C#-XNA port anyone?[message #207123]
|
Sun, 25 January 2009 01:38 
|
|
casper1987vd |
 |
Messages:12
Registered:October 2008 Location: The Netherlands |
|
|
Great, I've been using svn for over 5 years.
You can give them access (r or rw) by using authz and passwd.
I use this one atm:
[groups]
bis_case2 = Casper, Remy, Stefan
bis_case3 = Casper, Stefan
ebus_case2 = Bas, Casper, Jeffrey, Stefan
spa = Casper
[/]
admin = rw
Casper = rw
* =
[BIS:/]
Casper = rw
admin = rw
[EBUS:/]
#Casper = rw
#admin = rw
@ebus_case2 = rw
Note that you can't set subfolders on accessmodifier, you need to make a seperated repo for that, when using svn turtoise.
Are you using apache?
If so, you need to enable the mod for it + i would recommend ssl too.
Report message to a moderator
|
Private
|
|
|
|
|
|
| Re: C#-XNA port anyone?[message #212061]
|
Fri, 03 April 2009 19:50 
|
|
snyper |
Messages:1
Registered:July 2008 |
|
|
I'm also very interested in this. I am familiar with C#, DirectX, and some XNA. However, I was trying to do the same thing and was in the design phase when I realized that if I ported JA2 to C#/XNA then why wouldn't I do it in 3D? I would like to see the effect that the actual equipment models have in-game... i.e. a ghille suit that actually shows in game and not just the UI.
3D is the way to go if we update this game. Possibly a 3D isometric type engine. My current research is dealing with skinned meshes in XNA. XNA 2.0 did not have a library to allow for skinned meshes and there is a third party lib that makes it easier if you're using XNA 3.0.
My current status on this: waiting for more free time (due to real life), working out a design for 3d animation, and terrain with day/night cycles and model collisions. I'm using an old version of 3ds max to create models, however, I am NOT a modeler/animator so this takes a lot of time.
I do have a basic terrain mesh (loaded from a bitmap heightmap) with a day/night shader and a simple dwarf model with 4 animations all in C#/XNA 3.0.
Report message to a moderator
|
Civilian
|
|
|
|
|
|
| Re: C#-XNA port anyone?[message #224321]
|
Tue, 30 June 2009 09:22 
|
|
JoeKing |
Messages:1
Registered:June 2009 Location: Austria, near Vienna |
|
|
@ KeldorKatarn : If you are willing to, you could also use the services offered by : http://www.assembla.com
If you want to give it a try, a free space is ready to go in under 1 minute and configured in about another 5 minutes.
The free services package includes 200 Mb of online space and free packages like svn (subversion, git, mercurial), ticketing and bug tracking, a wiki, message board, file and image hosting, user and permission management and a lot more.
If you contact the support team of assembla.com and can verify to them that you are working on an open source project, they may as well just raise the online space for your free package to 500 Mb.
If 500 Mb still wouldn't be enough, then the pricing of the "pro" packages are not that expensive either.
I think it's great package, especially if one (like me) doesn't want to bother setting up svn, trac, wiki, etc and just use them instead.
I don't work for or am in any way affiliated to assembla.com, I just want to point out an opportunity here.
This JA2 1.13 C# Project cought my attention and I'll keep following its process for sure.
Good luck with it !
As this is my first post here, let me quickly say hello to the community.
I may be new here, but I've been following JA2 1.13's process for ages already.
Report message to a moderator
|
Civilian
|
|
|
|
|
|
| Re: C#-XNA port anyone?[message #304148]
|
Tue, 01 May 2012 22:33
|
|
KeldorKatarn |
 |
Messages:37
Registered:May 2006 Location: Germany |
|
|
Since I so shamelessly abandoned this thread back in the day I guess I should now tell you guys what project kept me from making any headway with this. it was around this time that I became Lead Developer and Co-Producer of the Wing Commander Saga project. Some of your guys might have heard about us, we released this March: http://www.wcsaga.com
Back then I had to decide which project to focus on, and both simply were not possible. Sorry for that. I am now working professionally in the business and I share your pain about the latest Jagged Alliance mess but I cannot really do anything about it at this point but appologize for the sudden drop off the radar back then and I hope some of you can at least enjoy the fruits of the project that I chose over this one.
Keep up the good work with JA 1.13!
Report message to a moderator
|
Private 1st Class
|
|
|
|
Goto Forum:
Current Time: Wed Jun 10 23:44:06 GMT+3 2026
Total time taken to generate the page: 0.01672 seconds
|