I've been experimenting with collision and different ways of loading in shapes.
I am currently only testing with flat one-sided planes.Loading the .dts file with a StaticShape datablock is much simpler than using a fake brick datablock.
TSStatic shapes work with transparency, but textures must be modified specially to look right.
StaticShapes do not seem to work well with transparency.Neither StaticShapes or TSStatic shapes have shadows cast on them. I'm considering trying to use other types of objects which do have shadows cast on them.For collision I can scale down the thickness of the object to get better collision.
0.25 allows a vehicle to slowly glitch through.
1.00 allows vehicles such as the Magic Carpet to glitch through at high speeds.
0.5 seems to work perfectly.
I will be releasing a map in modification help tommorow for collision testing. See if you can glitch a vehicle through the walls.You can see part of the process of my testing here:
https://forum.blockland.us/index.php?topic=307590.0I made a loopdeloop out of staticshapes.
From doing so, I've learned that I can only rotate a staticshape 90 degrees before collision gets really weird. In my first attempt at that loop I used 1 .dts object, duplicated for each surface on the entire thing. About halfway up the loop, where it hits the first 90 degrees, my jeep stopped moving forward and stayed stuck to the wall. I discovered that If I shifted the jeep into reverse it would make it farther up the loop. Further, if I set the jeep's maxWheelSpeed to 60, I could make it all the way around the loop after a few tries. Hitting reverse at the right spot was tricky.
I came to the conclusion that
something's forgeted up with rotating a collision object. So I made 3 more .dts objects. One for each 90 degree section. The result is what you can see in the video.
In the same project I learned that
you can affect the "bounciness" of an object by adjusting it's thickness. A surface with a scale of 0.05 will simply
stop a jeep that falls onto it. A surface with a scale of 1 will make the jeep bounce normally.
This is one of the reasons why the jeep "stuck" to the wall in my earlier test. To keep the jeep going all the way around the loop, I had to turn up the "bounciness" of the surfaces in some areas, and turn it down in others.
I also learned that skis move
very slowly on surfaces that have been scaled down.
In a previous project I was attempting to take the maps from Descent, a 1995 6DOF shooter, and put them into Blockland. The texture work on that project was... difficult. So I opted to make a simpler map using only one texture. From that project I learned that
Blockland lags with 5000 static shapes in it.
For most of my testing I was using a mass exporter script I wrote in python for blender. This script cycles through all of the objects in the scene, exports them and writes script files for them to work in Blockland. This rapidly sped up the testing process for large maps.
Guys you can't just convert a map with the method and have it work. For collisions to work you need loads of convex shapes, and with intricate maps like the kitchen or gsf maps it would require possibly thousands of shapes. Even then, the collision with these things is really weird with big shapes, which can be seen when you try to drive a vehicle on the bedroom.
Terrain is a completely different matter as well, you can't really turn it into a dts, and creating collision would be even harder.
Thousands of static shapes will lag. If anyone does attempt to remake Kitchen, I suggest they test how many static shapes their computer can render before they start.