Page 2 of 2

Re: Marathon Unity

Posted: Oct 4th '19, 09:28
by AnonFriction
Hey Alex!

I guess this is a bit late but I just stumbled across this thread :lol:

This appears to be run fine on windows (tested against Windows 10: Build: 18362.356)

However I did run into a few issues.

-After initially loading a Shapes file it became unresponsive, but after relaunching the shapes file was still selected and everything worked fine

-Sometimes after teleporting I fall through the map geometry

-Elevators don't appear to be functioning (not sure if they should be yet or not)

This is rad though! keep it up :wub:

Re: Marathon Unity

Posted: Oct 4th '19, 15:44
by Wrkncacnter
Don't hold your breath. It's been a year since it was worked on.

Re: Marathon Unity

Posted: Jun 13th '20, 14:49
by Daedalus
Shame that this is abandoned. Could've been a Daggerfall Unity-style revamp of Marathon.

Re: Marathon Unity

Posted: Jun 14th '20, 04:32
by Pfhorrest
If I'm not mistaken some parts of this are being used in the development of a new Unity-based map editor.

I'm probably mistaken though. I usually am.

Re: Marathon Unity

Posted: Jun 14th '20, 14:04
by The Man
In this case, though, you’re not. I’m not sure how much of the code Deram wound up using though, and Forge+ is only intended to be a map editor (though that’s not stopping someone else from potentially taking it and running with it).

Re: Marathon Unity

Posted: Jun 20th '20, 17:40
by Qweasy908
Munity uses plane clipping to handle overlapping geometry.

I use stencil buffer portals and layers to separate the polygons that occupy the same space in unity.

Separate the polygons or groups of polygons into two or more layers and the stencil shader portals separate the polygons visually.

The portals are quads and have a stencil shader attached to do the clipping.

The enemy, scenery and items have a stencil shader attached to the sprites when inside the 5D space.

Player and enemy layers change when crossing a portal.

Player and enemy layers change to that polygons layer when entering a portal then change to default layer when exiting a portal.

The layers are not able to collide, but can collide with default layer.

Player and enemy in different layers can't attack each other unless one or both is default layer.

The stencil buffer hides the geometry and sprites when not viewed from behind a portal.

For example the map 5-D space needs 30 portals and 2 layers.

Re: Marathon Unity

Posted: Oct 15th '20, 20:20
by Qweasy908
I have an idea on how to continue this project.

Program a automatic portal system using the stencil buffer and use code from Hopper's 5-D Intersections plugin for Weland.

Here is how I would program automatic portals.

Check for 5D space intersections and ignore those polygons that intersect, then build map.
Next put the 5D space polygons into a list and check for nearest neighbor.
Next different lists are made then continue checking nearest neighbor.
Next check nearest neighbor until there are no more, then there are two or more groups.
Next build the 5D space polygon groups from the lists.
Next if a 5D space polygon portal wall connects to a polygon that is not on the group list then build those portal walls.
Next flip the normals on the portal walls so they point outward from the polygon group.
Next put stencil shaders on the 5D space polygons and stencil shaders to the portal walls.
Next assign reference numbers to the different groups stencil shaders, different number for each group.
Next both portal walls and 5D space polygons of the same group share the same reference number.
Next the 5D space polygons stencil shader comparison function is set to equal and the portal walls are set to always.
Next change the render queue for each group, render queue is different for each group. (important)
Next check the 5D space polygon groups if they intersect with each other and assign them to different layers.
Next two groups of intersecting polygons are separated into two layers, if three groups intersect then three layers.
Next assign layer 8 scripts to layer 8 portals and layer 9 scripts to layer 9 portals.

The layers are changed so they do not interact with each other.

When the player is a certain distance in front of the portal then the player changes layers to match that group.

I don't know exactly how to make this and I'm not an expert in C#. ... ct.986004/