Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

DarkBASIC Professional Discussion / Cartography Shop Paging System w/ download

Author
Message
anwserman
15
Years of Service
User Offline
Joined: 20th May 2011
Location: Wisconsin
Posted: 1st Aug 2011 13:46 Edited at: 1st Aug 2011 13:53
I figured I'd post this here as the majority of my code could easily be applied to other level formats.

* multiple maps - load multiple maps into the application and interact with them all at the same time. if a couple maps are there just for scenery or for far-away graphical detail, you can choose which entities and properties you'd like to parse from the map.

facilitates map re-use, if needed =)

* Zone system - if a mesh is assigned to a zone, you can have it toggle visibility and/or collision states for objects based on where you are in the map.

~~~~~~visibility is automatically toggled w/ exclude object on and exclude object off.
~~~~~~ as there are multiple collision detection systems, I have made blank functions w/ parameters that should provide all you need to apply collision detection to said objects. (all that happens right now is a debug console print out that says "enabling/disabling collision for obj# i)

Also, as enabling and disabling collisions can be a computer intensive process, you can customize how many objects will be activated per frame. E.g., if you need to activate 100 objects when moving into a new zone, you can choose to activate 10 objects per frame of gameplay.

ALSO: Forgot to implement a 'priority' system, so that objects with a higher priority get their collision enabled before others. Easy fix

* Animated textures - apply four flags to a group and you can have animated textures for your meshes. If need be, you can also have the texture be influenced by the cartography shop lightmap, so that the animation will be shadowed as well.

* hardware lights - allows you to remove an object from the lightmapping system in the map and be influenced by hardware lights.

* dynamic shadows - allows you to allow an object to cast dynamic shadows from the primary hardware light in the map. e.g, the one you'd pick as the 'sun'

* eXtends Virtual Lights - partially implemented for now - (forgot to include the update code so the lights render, heh). Allows you to move through the map and toggle which hardware lights are active, so any and all light entities have the ability to illuminate local dynamic objects when within range.

This code also includes my module that will use a timer to return the time in seconds since the last frame was rendered. e.g., 10 frames per second would result in .1 being the time since the last frame.

I've included an executable with sample media. To run this, you need these plugins:

Extends
Ian M's Matrix1 utility plugins
Ian M's cartography shop .X exporter
Apex Now's CSM importer

Please provide me feedback =)
anwserman
15
Years of Service
User Offline
Joined: 20th May 2011
Location: Wisconsin
Posted: 2nd Aug 2011 12:51
Updated. Rewritten major portions of the code!
Also provided functions very similar to the lighting system in eXtends =)

Feel free to parse and cannabilize for your own needs

Login to post a reply

Server time is: 2026-07-10 17:19:54
Your offset time is: 2026-07-10 17:19:54