Star Trek Fan Games
http://bote2.square7.ch/forum/

Engine changeover
http://bote2.square7.ch/forum/viewtopic.php?f=29&t=2431
Page 1 of 1

Author:  jigalypuff [ 19 Aug 2008, 14:49 ]
Post subject:  Engine changeover

I have recently found out that the engine i was useing has a bug in it`s networking code, sadly this means i shall have to make my game single player only (which would suck) or change engines. I have decided to go the xna route for now but i may change over to the c4 engine or unity if they ever finish the windows platform for it :)
I shall keep people updated with progress on the new engine.

Author:  Malvoisin [ 19 Aug 2008, 14:59 ]
Post subject:  Re: Engine changeover

is that bug not fixable respectively is their no only development or support for this old engine?

Author:  jigalypuff [ 19 Aug 2008, 15:05 ]
Post subject:  Re: Engine changeover

yes it is fixable but conites are focusing on new terrain editors and other features, the yhave decided to let multiplayer lag in development sadly :( no biggie though i was already toying with xna so i`ll be able to plug along just fine :)

Author:  Matress_of_evil [ 24 Aug 2008, 00:09 ]
Post subject:  Re: Engine changeover

The two programs that Strings made before he disappeared (His combat system and the model viewer) used .xna, Jig. They might have been little programs, but they were impressive. You never know, this change might turn out to be a blessing in disguise... :wink:

I've got backup copies of both of the programs if anyone wants them. The model viewer comes with a small number of Federation, Klingon, Romulan, and Minor Race models in the .xna format Jig, so that might be of particular interest to you.

Author:  jigalypuff [ 24 Aug 2008, 08:04 ]
Post subject:  Re: Engine changeover

xna uses .x and .fbx, but his meshs looked nice s oi`ll have em if there going, plus his code if you have it :0

Author:  Zeleni [ 24 Aug 2008, 08:29 ]
Post subject:  Re: Engine changeover

@ Jig, is it possible to revert x. format to some other format like 3ds.?

Author:  jigalypuff [ 24 Aug 2008, 08:37 ]
Post subject:  Re: Engine changeover

ya of course it is :lol:

Author:  Matress_of_evil [ 24 Aug 2008, 11:13 ]
Post subject:  Re: Engine changeover

My mistake; the models are in .xnb filetype. Anyways, here's the links, jig:

Strings's Model Viewer

Strings's Combat System

In both of those links, click on the blue "Click to Download" link on the left to start the download. You might want the combat system since it's got the models of the Defiant and the Asteroids as well.

Author:  Zeleni [ 24 Aug 2008, 13:19 ]
Post subject:  Re: Engine changeover

Sry Jig my mistake i was tkinking on xnb not x format, so can we convert strings models to 3ds?

Author:  Matress_of_evil [ 24 Aug 2008, 13:58 ]
Post subject:  Re: Engine changeover

I'm not sure about .xnb, but to my knowledge, there is currently no way to convert a .xna file into another filetype. that's one of the main reasons why supporters of it use it. It prevents hacking and converting. Idiots. :evil:

Author:  jigalypuff [ 24 Aug 2008, 14:26 ]
Post subject:  Re: Engine changeover

well strings demo has no source code, shame really. As for file formats i dunno why there is .xnb files when i add files to the content pipline i can use .x or .fbx, there is no mention of .xnb so far :)

Author:  Matress_of_evil [ 24 Aug 2008, 15:30 ]
Post subject:  Re: Engine changeover

I wish there was a way to contact Strings and see if we could get him to continue development of the programs, help you, or at release his source code. This programs were really promising and it wouldn't hurt to have another competent programmer working with us. I've sent him PMs and emails but he's not even read them. :(

Author:  jigalypuff [ 24 Aug 2008, 17:34 ]
Post subject:  Re: Engine changeover

.xnb is what all resource files get changed to when you publish the game, does not make for a moddable engine does it :( perhaps i`ll try dx studio but it is meant to be a bit slow.

Author:  Strings [ 26 Aug 2008, 13:04 ]
Post subject:  Re: Engine changeover

Hey Jig, yeah I'm back, hopefully for a long while :) Matress told me about the engine problem and this thread. I think it's great that you want to move to XNA, I'll try to help any way I can, but first I have to familiarise myself with it again. Sounds like you are already using it, good, it's pretty easy to get into.

Quote:
.xnb is what all resource files get changed to when you publish the game, does not make for a moddable engine does it :( perhaps i`ll try dx studio but it is meant to be a bit slow.

Yes, at first I was having the same concerns, or more specifically; what if someone wanted to add new ships to the combat system, without having to go into the source? So I experimented with the model viewer that I was working on at the time - instead of hard coding in exactly what models to load, I made it so that the model viewer looks at the Content/Models/ folder and determines what models are in there at run time, and then proceeds to load them into memory and readies them for display.

Matress_of_evil wrote:
I'm not sure about .xnb, but to my knowledge, there is currently no way to convert a .xna file into another filetype. that's one of the main reasons why supporters of it use it. It prevents hacking and converting. Idiots. :evil:

I wouldn't say no way, but no easy way (like a conversion tool from Microsoft) to reverse the process and get a .3ds model out from a .xnb, like Matress said it is a design feature to protect game assets. There might be unofficial tools to do this, I haven't looked lately, but I can imagine some code wizards might be able to take the model in memory and put it back into various formats. A quick work around would be just to release a modders pack of the models and other assets in their editable forms, isn't that what you would want anyway if you were a modder ?

Author:  jigalypuff [ 26 Aug 2008, 13:26 ]
Post subject:  Re: Engine changeover

were there`s a will theres a way, i can begin to code with xna and switch engines easily enough to unity (which i will once it is windows supported) both use c# and .fbx so no big deal there.
As c# is a new language for me (having worked in c-script) i`m going to be on a learning curve as i go, so don`t expect massive progress for a bit :) Is your demo based around the flythrough tutorial strings? i`d like a look at your collosion detection code, do you use abb or polygon detection for it?

Author:  Strings [ 26 Aug 2008, 15:03 ]
Post subject:  Re: Engine changeover

Fly through tutorials? I haven't heard of them before, so I don't think so.

The collision code, right ... for the demo I only needed something simple that got the job done, and being okay at maths, so I used the quickly hashed together maths approach, I drew out something like this to visualize the problem

From Picture:
Image

To words: basically there is a collision whenever the distance between the defiant position and any asteroid's position is less than the sum of radius of the asteroid and the radius of the defiant.

In code:
I implemented a method that I called to check whether the defiant has hit anything, I supply it with the defiant's position and radius, and it checks through all the asteroids for a collision, if there is one, it spawns smaller moving asteroids through calling the SplitAsteroid method. (note there are two lists of asteroids because I kept the moving ones and the stationary ones separate, for performance reasons in other parts of the code.)

Code:
private int CheckCollision(Vector3 position, float radius)
        {
            for (int i = 0; i < asteroidList.Count; i++)
            {
                currentAsteroid = (asteroidStruct)asteroidList[i];
                if (Math.Sqrt(Math.Pow(currentAsteroid.position.X - position.X, 2) +
                    Math.Pow(currentAsteroid.position.Y - position.Y, 2) +
                    Math.Pow(currentAsteroid.position.Z - position.Z, 2)) < radius + currentAsteroid.radius)
                {
                    asteroidList.RemoveAt(i);
                    i--;
                    SplitAsteroid(currentAsteroid.position, currentAsteroid.radius);
                    asteroidsDestroyed++;
                    returnValue = 2;
                }
            }

            for (int i = 0; i < movingAsteroidList.Count; i++)
            {
                currentMovingAsteroid = (movingAsteroidStruct)movingAsteroidList[i];
                if (Math.Sqrt(Math.Pow(currentMovingAsteroid.position.X - position.X, 2) +
                    Math.Pow(currentMovingAsteroid.position.Y - position.Y, 2) +
                    Math.Pow(currentMovingAsteroid.position.Z - position.Z, 2)) < radius + currentMovingAsteroid.radius)
                {
                    movingAsteroidList.RemoveAt(i);
                    i--;
                    SplitAsteroid(currentMovingAsteroid.position, currentMovingAsteroid.radius);
                    asteroidsDestroyed++;
                    returnValue = 2;
                }
            }
            return returnValue;
        }


I admit it's not pretty, but it got the job done. there is a much more elegant solution built into XNA, it's called the BoundingSphere class, I think.

Author:  cdrwolfe [ 26 Aug 2008, 15:18 ]
Post subject:  Re: Engine changeover

Nice, i use a similar one for mine though it needs some work to make it look and act correctly i feel.

Regards Wolfe

Author:  iwulff [ 27 Aug 2008, 18:16 ]
Post subject:  Re: Engine changeover

Is it official now, Jig? Better make a new article then. :wink:

How are things with C# going? I am familiar with C# and so are others on this forum, so if you need any tips or help, you are free to ask us. :)

Author:  Zeleni [ 28 Aug 2008, 08:30 ]
Post subject:  Re: Engine changeover

@ STRINGS- we have lost your ships because of sharepoint, Botf 2 Site and my hard drive failure. Please can you upload your Malon and Vulcan ships to some hosting site it would be a shame to the people if they don't see such nice ships in the game. :)

Thanks

Author:  Strings [ 28 Aug 2008, 12:57 ]
Post subject:  Re: Engine changeover

Sorry for the thread hi-jack :P here they are again, with the 270x255 .pngs
Malon Freighter (3 tanks version) and Malon Freighter (no. 2 / "the double decker")
Poly: 3290 & Poly: 5566 respectively
.PNGs
ImageImage
Downloads
http://myweb.tiscali.co.uk/strings/MalonFreighter1.rar
http://myweb.tiscali.co.uk/strings/MalonFreighter2.rar

Comparison shot :P
Image

Author:  Zeleni [ 28 Aug 2008, 13:11 ]
Post subject:  Re: Engine changeover

Thanks mate, nice ships i think it would be good to represent them on main site page but that is job for Iwulff.

P.S. Second link doesn't work and i am waiting for Vulcan ships too. :)

Author:  Strings [ 28 Aug 2008, 13:39 ]
Post subject:  Re: Engine changeover

Oops, didn't notice the upload to my ISP's webspace got stuck at 99%, it works now. :)

About the Vulcan ships, I noticed Ken has made a D'kyr-class, and it looks great, the mesh is really detailed, and I think we should use his model. But the textures could be re-hued to be a bit less red though. Here's a pic of it.
Image
Maybe ask Ken to send it to you.
As for the Sh'Raan/Suurok/Surak class (just different names/spellings, but it's the same ship), I still have the re-texture job I did on the model that was on SharePoint.
Image
Here it is if you need it.
http://myweb.tiscali.co.uk/strings/Vulcan%20Surak-class.rar

Page 1 of 1 All times are UTC [ DST ]
Powered by phpBB® Forum Software © phpBB Group
http://www.phpbb.com/