eventhorizon5 / skyscraper

The Skyscraper Project (Skyscrapersim) - an open source building, city, and elevator simulator
https://www.skyscrapersim.net
GNU General Public License v2.0
28 stars 7 forks source link

Lighting issues with Cut function #9

Closed eventhorizon5 closed 1 year ago

eventhorizon5 commented 1 year ago

It appears that the Cut function, which creates sets of polygons with a single texture mapped across them, doesn't work properly with dynamic lighting.

Using polygon sets: lights1

Using individually-mapped polygons (three AddFloor commands) without cut function: lights2

I've been trying to see if I can remake the Cut functionality to create individual polygons instead of sets, or try to fix the reason why the sets don't work properly.

eventhorizon5 commented 1 year ago

I found out that manually making the polygons does the same thing, it's not just the Cut function. In the demo photos I was making three polygons of the same size, and so it worked, when the middle polygon is smaller, the first photo is what happens.

eventhorizon5 commented 1 year ago

This issue has been fixed, had to do with polygon normals not being calculated properly.