Wanted: People who know more about Marathon than is healthy

Pfhorums news can be found here. Have a question or suggestion for the Pfhorums? Ask it here.
User avatar
Alex
Born on Board
Posts: 24
Joined: Mar 11th '18, 12:21
Location: Low Earth Orbit.

Greetings!
I am creating a port of Marathon to the Unity game engine.
The idea is to have a unity app that can read the marathon game files and display the game using that renderer (initially, exactly as Marathon does, but eventually with all sorts of extra eye candy that the engine is capable of)
Currently i have the level geometry rendering correctly, and the basic platforms/doors working. Mostly this is thanks to the fact that i can use large chunks of the Weland source code to decode the Maps and Shapes files.
What i need now is a way to read the sound and physics files.
So - Is there anyone here who knows what the data format is for those? Or is there somewhere where its been documented that google doesn't know about?
User avatar
Zott
Vidmaster
Posts: 1659
Joined: Jul 1st '06, 21:14
Location: Earth
Contact:

You may wish to try the source code for Shapefusion. It is an editor capable of modifying physics files.
https://sourceforge.net/p/shapefusion/code/HEAD/tree/

As far as what the physics actually mean. You can view this link for a high-level understanding of some of the properties.
https://web.archive.org/web/20160225072 ... index.html
User avatar
treellama
Vidmaster
Posts: 6105
Joined: Jun 2nd '06, 02:05
Location: Pittsburgh
Contact:

I'm surprised you're able to get the Unity engine to render 5D space. I'd love to see how that works.

I'm happy to answer questions about the file formats.
User avatar
Alex
Born on Board
Posts: 24
Joined: Mar 11th '18, 12:21
Location: Low Earth Orbit.

Thanks Zott, i can see where Shapefusion is opening files, that looks to be just what i need to get started, especially with that description you linked.

As for Impossible space, at the moment it just makes a mess, however the way Im assembling the world is that its being made from a whole bunch of gameObjects, each one containing the meshes needed to draw one marathon polygon. The plan is to just not draw the gameobjects for the polygons that the player shouldn't be able to see.
These show how the level is built.
https://www.acinonyx.me/shtuff/Ne%20Cede%20Malis.jpg
https://www.acinonyx.me/shtuff/Ne%20Cede%20textures.jpg
https://www.acinonyx.me/shtuff/polygon%20elements.jpg

I am vaguely thinking about having the map screen be an untextured level, like what you see in that first pic since the map turning into a mess of overlapping lines always kind of annoyed me, however that would show all the impossible space as overlapping geometry. I'll worry about the map once the basic game play is working, maybe someone will come up with some genius idea in the mean time...
User avatar
Flowers
Cyborg
Posts: 117
Joined: Jul 26th '17, 22:12

Alex wrote:Greetings!
I am creating a port of Marathon to the Unity game engine
Question: Will this port include jumping? I just wanna jump, man.
User avatar
treellama
Vidmaster
Posts: 6105
Joined: Jun 2nd '06, 02:05
Location: Pittsburgh
Contact:

I'd love to contribute to this project. I think it's a way better use of time than trying to shoehorn stuff like modern lighting and multiplayer into Aleph One.

I'm not interested in adding jumping though :)
User avatar
Flowers
Cyborg
Posts: 117
Joined: Jul 26th '17, 22:12

treellama wrote:I'm not interested in adding jumping though :)
:(
CluckyInventor
Born on Board
Posts: 34
Joined: Feb 25th '18, 07:10

Jumping already is a thing in the engine though? Ever heard of grenade jumping? Get good!

I mean, just think about it, how high can you jump in real life? Most people can't jump very high (well, I can't). Admittedly, you are a battleroid and not a me (don't try being a me, that's not very interesting). But you also have to consider the marine is wearing battle armor, something that doesn't sound particularly lightweight. Combined with the added weight of the battleroid's titanium bones and other such things it is reasonable to assume that the battleroid can't jump much higher than I can. And that kind of wimpy jump wouldn't be fun to use in the video game.

Just think about normal security officer duties. Jumping might be required in a military situation, but it's been a long time since you have done that if you have at all. Security officers probably don't encounter the kind of obstructions that military personnel do. While you get lots of practice running in battle armor as a security officer (presumably), you also presumably get much less practice jumping. With this in mind, it is very believable that you have the strength to run fast in battle armor but not jump high (because you can already "jump" horizontally pretty well as is in the engine).

As for the idea of porting Marathon (hopefully all of Aleph One so all of the scenarios work) to Unity, I love it. I don't have much experience in this community but one thing that has impressed me with this community is the ability to make small, useless changes over long periods of time. Actually getting Aleph One 1.3 out the door? No way! Making some textures into HD? Sure, that's not too hard, we can do that! Just look at how many things are on simplici7y ever since work on 1.3 started.

So if the engine is in place for nice lighting and maybe even, gasp, true 3D monsters instead of cardboard cutouts sort of thing, it really is conceivable that the game wouldn't look quite as primitive in, say, a decade.
User avatar
Alex
Born on Board
Posts: 24
Joined: Mar 11th '18, 12:21
Location: Low Earth Orbit.

treellama, I'll add some sort of basic interface to the thing so that they paths to the data files dont need to be hard coded, and then upload it to github, and then anyone with any unity experience can help out. (seriously, any experience - I basically downloaded unity, ran through a couple of tutorials and then went 'Lets make marathon go.')

As for jumping... on one hand Im pretty sure that a combat cyborg who can one hit punch a pfhor fighter to death can jump, or at least climb up ledges (and the same goes for ducking/crawling under gaps). On the other hand that ability would ruin half the levels ever made for marathon, and were trying to make marathon here...

All that said, once the basic movement is done, it will probably be trivially easy to add a jump ability, so if someone wanted to grab the code and add the ability to do that i doubt that i would reject it (especially if you got creative and added the ability to mantle up ledges like in doom 2016, that would be pretty cool, although much less trivial to add)
User avatar
JohannesG
Mjolnir Mark IV
Posts: 607
Joined: Jan 22nd '06, 23:52
Contact:

Now this is a fascinating project! I am looking forward to seeing the code of this up on github. <3
User avatar
ravenshining
Vidmaster
Posts: 889
Joined: Jun 17th '17, 22:50
Location: Hawai'i

CluckyInventor wrote:Just think about normal security officer duties. Jumping might be required in a military situation, but it's been a long time since you have done that if you have at all. Security officers probably don't encounter the kind of obstructions that military personnel do. While you get lots of practice running in battle armor as a security officer (presumably), you also presumably get much less practice jumping. With this in mind, it is very believable that you have the strength to run fast in battle armor but not jump high (because you can already "jump" horizontally pretty well as is in the engine).
So we aren't playing a soldier, we're playing a trigger-happy mall cop. Love it.

No offense to any genuine security officers out there, I'm in that line of work myself.
User avatar
Flowers
Cyborg
Posts: 117
Joined: Jul 26th '17, 22:12

Even though I was mostly joking, I was still genuinely curious about the physics. Marathon has very unique physics that I have not personally seen in any other game. I remember a few people discussing Marathon's "floatiness" and trying to replicate it in Doom but couldn't get it working right.
User avatar
treellama
Vidmaster
Posts: 6105
Joined: Jun 2nd '06, 02:05
Location: Pittsburgh
Contact:

I don't have any Unity experience. I have a lot of Marathon experience. So if you can think of a way that's helpful (within the limits of my very limited free time), let me know.
User avatar
HelviusRufus
Cyborg
Posts: 241
Joined: Apr 15th '15, 03:37

For jumping, why not just use the jumping lua from Simplici7y?
It requires some skill and coordination; it works to get you on top of something
but only allows one iteration.

At the bottom of the cheats lua that comes with AO, below the qwe function, there is a jump script,
which can be extracted, that allows multiple iterations.

Both of these use the mic key.
I just play 'em; I don't know how they work.
User avatar
Alex
Born on Board
Posts: 24
Joined: Mar 11th '18, 12:21
Location: Low Earth Orbit.

So. Theres source code uploaded here
https://github.com/Trichosurus/munity
If anyone is interested in helping out there, let me know.
As far as helping in other ways, theres probably not much you can do yet. That said, the thing should be able to load any M2/Moo map + shapes file, but im only really using the first level of infinity and m1a1 as my tests so far, so if you have any maps that do anything particularly tricky with the level geometry, it would probably be good to know if they explode the thing sooner, rather than later. (theres basically 0 gameplay at the moment, the player spawns, and has the worlds most basic fps controls, but thats it, you still need to use the editors scene camera to fly around the level if you want to see more than the area you start in)

Also. I hadnt actually come up with a name for this until i made the git repo, and for the moment im calling this thing Marathon Unity, which is just about the most boring name possible. Mostly because i couldn't work out a good marathon based pun that conveys the general idea of marathon inside unity. If anyone has an amazing name for it, you have untill i stop hating that name, or i make a thread in the projects section to tell me about it. (so a few days i guess)
User avatar
JohannesG
Mjolnir Mark IV
Posts: 607
Joined: Jan 22nd '06, 23:52
Contact:

Just downloaded this and loaded up in Unity. Selected the Marathon Infinity data files but when I hit "Go" I get "Display 1 No cameras rendering" on the screen and the following error in the console.

Code: Select all

ArgumentOutOfRangeException: Argument is out of range.
Parameter name: index
System.Collections.Generic.List`1[UnityEngine.Material].get_Item (Int32 index) (at /Users/builduser/buildslave/mono/build/mcs/class/corlib/System.Collections.Generic/List.cs:633)
Map.getTexture (ShapeDescriptor texture) (at Assets/Scripts/Map.cs:329)
Map.makeWorldFromMarathonMap (Weland.Level Level) (at Assets/Scripts/Map.cs:235)
Map.Start () (at Assets/Scripts/Map.cs:46)
User avatar
Alex
Born on Board
Posts: 24
Joined: Mar 11th '18, 12:21
Location: Low Earth Orbit.

Hmm. It sounds like it’s trying to draw a texture that isn’t in the shapes file. The no camera will be because it didn’t spawn the player.which would be because it didn’t finish building the world. If you switch to the scene camera in the editor, did it manage to draw anything? If not, can you check that it’s the correct shapes?
User avatar
JohannesG
Mjolnir Mark IV
Posts: 607
Joined: Jan 22nd '06, 23:52
Contact:

Apparently the bug is in the menu/file chooser. For some reasons if I for example choose a physics file in the Physics box it will both populate the physics box and shapes box menu item with the physics model path. This was causing the above error as it was trying to read the physics model as a shapes file in my case.

I am unable to determine under what circumstances this happens, as currently it seems relatively random.
User avatar
JohannesG
Mjolnir Mark IV
Posts: 607
Joined: Jan 22nd '06, 23:52
Contact:

Tested out some of my ancient maps from 20 years ago. Working quite nicely apart from it really doesn't like 5D space like expected.

Image
User avatar
Alex
Born on Board
Posts: 24
Joined: Mar 11th '18, 12:21
Location: Low Earth Orbit.

Its also using the landscape as a normal texture. Thats on my list. If i can ever get the platforms generating correctly - it turns out that there are a surprisingly large number of ways to abuse the collection of hacks that bungie decided to call a platform, and my idea to create an empty polygon and then have an actual platform object that goes up and down inside that is proving to be more complex to implement than i thought.
Hopefully i can get that working tonight.
then get the basic character movement working,
then the switches and tags
then liquids
then get the 5d space correct
then get the physics files loading
the player movement right
load all the map objects
make the ui work
make the guns work
make the ai work
get the terminal data loading
then i think there is a fully functional marathon.... simple ;)
User avatar
JohannesG
Mjolnir Mark IV
Posts: 607
Joined: Jan 22nd '06, 23:52
Contact:

Yes, the landscape textures are displayed as regular textures. and if i am not mistaken I also noticed some transparent textures simply displayed as blue (where it was supposed to be transparent) when I tested out the Marathon Eternal data files.

What's your plan regarding lighting?
User avatar
Alex
Born on Board
Posts: 24
Joined: Mar 11th '18, 12:21
Location: Low Earth Orbit.

Im not entirely sure. I think im going to have some sort of shadowmap that will be generated from the map data, that way it should look exactly like a marathon map but you can have point lights from weapons and explosions illuminate the scene as well.
Further down the track, id like to look at getting rid of baked shadows and attaching lights to textures so that you can have the scene illuminated from where the lights are drawn on the screen. The lighting quite often doesnt make any sense in maps tho, so it will probably also need to have some sort of algorithm that looks at the lighting on the surfaces and spawns lights throughout the map to try to approximate the lighting in the map data.
User avatar
JohannesG
Mjolnir Mark IV
Posts: 607
Joined: Jan 22nd '06, 23:52
Contact:

Yeah, the problem with lighting in maps is that it's relatively freeform and many mapping methods use lighting in a more "practical way" rather than realistic.

Then there's of course the problem with custom lights. :/
User avatar
Alex
Born on Board
Posts: 24
Joined: Mar 11th '18, 12:21
Location: Low Earth Orbit.

Yeah, I might have a look at some of the doom source ports, IIRC some of them added fairly complex lighting so they would have run into similar problems. I dont think dooms lighting was as complex as marathons tho, so maybe their solutions wont quite work here. Especially with how to light 3d models added to the scene.
User avatar
Pfhorrest
Vidmaster
Posts: 1825
Joined: Oct 12th '07, 22:08
Location: California
Contact:

I really like the idea of trying to infer the existence of point lights from surface lights, and then applying dynamic point lighting from those inferred lights.
Post Reply