DF-21 Forums Forum Index DF-21 Forums
The Dark Forces Community
 
DF-21.net Home | FAQ | Search | Memberlist  | Register 
Profile | Log in to check your private messages | Log in

HOM Formula for Hall of mirrors. Updated with pic.

 
Post new topic   Reply to topic    DF-21 Forums Forum Index -> Dark Forces Levels & Editing
View previous topic :: View next topic  
Author Message
Cal72521
Ree-Yees

Joined: 14 Sep 2006

PostPosted: Dec 30, 2008 06:30    Post subject: HOM Formula for Hall of mirrors. Updated with pic. View user's profile Send private message Send e-mail Reply with quote



After alot of hours of testing different df rooms to find how and when homs' happen. I have discoverd it is a liner function not log or something.
Frist:
Take some graph paper let each square represent 16 df units, label width for y[up and down] next label distance/diamiter for x [side to side]. Finally take a ruler and find w/y=256, d/x=128. next point will be w/y=160, d/x=208; w/y=64, d/x=288 and so on. Draw a line between these points. This is the dividing line for homs. The event horizon if you will.
The Meat:
Homs are a function of wall width and the distance you view the wall from. The engine draws the entier wall you can view even if you can only see part, so hour glass shaped rooms will not let you cheat.
Also if one stands in the corner one can see more 'wall' at a greater distance than in the middle edge of a square room.
Remember continuous wall width is the key here, height and the amount of separate walls don't seem to make homs.
In practace:
Take the diamter of the room you want on the graph say 320. Find the width of wall,for a hom is ~24 acording to our graph, so 16 is plenty safe.
320df*3.14=1004.8/16df=62.8<63
Finally create a sector with 63 sides and a radius of 160.
or
A room 320df long and 16df wide that works to.
The largest room i've made so far is 320df units with 15.95 walls and 63 vertices. And DF it loads fine with 3dos and objects too. Even larger rooms could be made! A note at 288 and above, some clipping happens but no homs.
The largest practical size square room is 176x176.
homs= Hall of Mirrors
Diamiter= Viewing distance from a wall
Rooms= Sectors
Cool
Try it out!
You'll find homs happen at exact points.[/img]

_________________
Cool


Last edited by Cal72521 on Mar 18, 2009 10:21; edited 5 times in total

klasodeth
Trandoshan

Joined: 03 Mar 2008

PostPosted: Dec 30, 2008 23:22    Post subject: View user's profile Send private message Reply with quote

Hmm... That sounds like it might be useful information for lucius. I thought I remember him saying that he planned some sort of heuristics for the DarkXL editor so that it could warn the user if a level might break Dark Forces compatibility. If so, knowing how to check for a HOM condition would be useful.

Lionel Fouillen
Gamorrean

Joined: 27 Sep 2003

PostPosted: Jan 28, 2009 21:18    Post subject: View user's profile Send private message Reply with quote

No time to test it myself, but thanks for the info!

Barry Brien
Dark Trooper Phase 1

Joined: 26 Sep 2003

PostPosted: Jan 31, 2009 19:44    Post subject: View user's profile Send private message Send e-mail Reply with quote

Good work must give that a try.

Barry Brien
Dark Trooper Phase 1

Joined: 26 Sep 2003

PostPosted: Feb 15, 2009 04:12    Post subject: View user's profile Send private message Send e-mail Reply with quote

Guys I've been trying this out on a new level that I've started messing around with, and to be honest I'm amazed. This works really well. Why didn't we figure this out earlier? I had a big area I as working on and I got to the point where it was homming on me when i went near any of the edges. So I divided up the walls and hey presto: hom is gone. So good work Cal, this is pretty important stuff as far as I'm concerned. Cheers!

Burning Gundam
Kell Dragon

Joined: 28 Sep 2003

PostPosted: Feb 15, 2009 05:13    Post subject: View user's profile Send private message Send e-mail Reply with quote

You're working on something again? I hope you are. This could be good news.

_________________
I don't think outside the box... I customize it.

Barry Brien
Dark Trooper Phase 1

Joined: 26 Sep 2003

PostPosted: Feb 15, 2009 23:00    Post subject: View user's profile Send private message Send e-mail Reply with quote

Cheers Gundam, but you know how long I take to put stuff out so don't be holding your breath.

Burning Gundam
Kell Dragon

Joined: 28 Sep 2003

PostPosted: Feb 16, 2009 01:22    Post subject: View user's profile Send private message Send e-mail Reply with quote

** Holds breath **

** Face turns a rainbow of colors **

** Dies **

_________________
I don't think outside the box... I customize it.

Cal72521
Ree-Yees

Joined: 14 Sep 2006

PostPosted: Mar 18, 2009 10:19    Post subject: View user's profile Send private message Send e-mail Reply with quote

Barry Brien wrote:
Guys I've been trying this out on a new level that I've started messing around with, and to be honest I'm amazed. This works really well. Why didn't we figure this out earlier? I had a big area I as working on and I got to the point where it was homming on me when i went near any of the edges. So I divided up the walls and hey presto: hom is gone. So good work Cal, this is pretty important stuff as far as I'm concerned. Cheers!



Uploaded a graph, took all day with paint. blah blah.
Cool

_________________
Cool

Barry Brien
Dark Trooper Phase 1

Joined: 26 Sep 2003

PostPosted: Mar 20, 2009 17:34    Post subject: View user's profile Send private message Send e-mail Reply with quote

I think that's probably the coolest fecking graph I've ever seen.

Fenwar
Admiral Ackbar
Admiral Ackbar

Joined: 15 Sep 2003

PostPosted: Mar 22, 2009 22:05    Post subject: View user's profile Send private message Reply with quote

Fantastic work, and I can't believe that this was never discovered before (particularly having seen the level of research that went into the DF specs).

Anyone want to start a new HTML version of the DF Specs?

Or better still, stick it in the Dark Forces Wiki. Use it or lose it, kids.

lucius
DarkXL Developer
DarkXL Developer

Joined: 17 Feb 2008

PostPosted: Mar 23, 2009 03:26    Post subject: View user's profile Send private message Send e-mail Reply with quote

It seems like this could be used by the DarkXL edit to split walls to avoid HOM (optional only - probably something you have to tell it to do). It could also flag walls that would be problematic. Good job.

_________________
DarkXL....http://darkxl.wordpress.com

Cal72521
Ree-Yees

Joined: 14 Sep 2006

PostPosted: Mar 30, 2009 12:06    Post subject: hom wiki View user's profile Send private message Send e-mail Reply with quote

[url=http://df-21.wikidot.com/hom]Dark Forces
Hom wiki made, its late so spelling is bad.
I'll research how many ajoins it takes to hom, or how ever that one works.

_________________
Cool

Cal72521
Ree-Yees

Joined: 14 Sep 2006

PostPosted: Mar 31, 2009 11:51    Post subject: Adjoin View user's profile Send private message Send e-mail Reply with quote

I did some tests with ajoins between sectors for homs, no subsectors. my graph holds true! i did sevral tests with walls 64, 128, and, 144. two tests at 64 where used, every 16dfu an adjoin, then every 8dfu. Doubleing the amout of adjoins. 32 then 16 adjoins no homing point corrilated to the above graph! euraka! if recreating these test it was found nessary to reskin the test wall. after hom point was exseded the next closest sector was drawn.
Its my opion that the gloden graph holds true for this kinda hom. there seems to be no max adjoin limt.
now subsectors are a diffrent story. I check that one next week.

_________________
Cool

Cal72521
Ree-Yees

Joined: 14 Sep 2006

PostPosted: Apr 07, 2009 11:50    Post subject: Subsector hom phantom torus results View user's profile Send private message Send e-mail Reply with quote

ok did some testin!
you can NOT look thru two subectors in diffent sectors at once. like this O- | o | o | =hom.
also you can not it seems look thru more than 7 subsectors at once with in the same sector.
and of crouse you can't have a subsector within a subsector work.

Does anyone have any input? Thanks.

_________________
Cool

lucius
DarkXL Developer
DarkXL Developer

Joined: 17 Feb 2008

PostPosted: Apr 07, 2009 17:23    Post subject: View user's profile Send private message Send e-mail Reply with quote

Those are interesting points to keep in mind. Those cases work just fine in DarkXL which means that the editor will have to eventually flag those cases with a warning if you want full DF compatibility. So the editor will have an DF compatibility option - which will warn in cases where it will HOM like you mention here. Of course you will be able to turn this off if you just want the level to work in DarkXL.

Thanks for all the testing. Smile

_________________
DarkXL....http://darkxl.wordpress.com

Fenwar
Admiral Ackbar
Admiral Ackbar

Joined: 15 Sep 2003

PostPosted: Apr 07, 2009 21:30    Post subject: View user's profile Send private message Reply with quote

Excellent stuff Cal, but maybe don't try to write when you're drunk? Wink Wink

Cal72521
Ree-Yees

Joined: 14 Sep 2006

PostPosted: Apr 15, 2009 10:22    Post subject: subsectors View user's profile Send private message Send e-mail Reply with quote

oh df specs are so great to have.
there is a 40 adjoins viewable hard limt.
i didn't even know!

_________________
Cool

Display posts from previous:   
Post new topic   Reply to topic    DF-21 Forums Forum Index -> Dark Forces Levels & Editing All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group