Page 1 of 1

Bit of help getting started.

Posted: Fri Jun 26, 2015 10:27 am
by Ernisius
I would like to get involved with some daggerfall projects but I need a little help to get started.
I've been playing with Unity for a month or so and have done the complete Unity developer course at Udemy.

In every project I've seen to date, all object in the game are represented in the hierarchy of Unity, but I don't see them in these tools or examples. I also don't see any prefabs for them.
I can find the objects in the scene when the scene is running, and see all attached components

I thought that enemies for example must be a gameobject, and all gameobjects appear in the hierarchy when they are created. I am clearly missing something, so would be grateful if anyone could save me some time by pointing me in the right direction.

Thanks

Re: Bit of help getting started.

Posted: Fri Jun 26, 2015 7:34 pm
by LypyL
Hello Ernisius, and welcome to the forums!
In every project I've seen to date, all object in the game are represented in the hierarchy of Unity, but I don't see them in these tools or examples. I also don't see any prefabs for them.
There aren't currently prefabs for the objects you're looking for (that will change soon with the next update). They're simply being created from code right now.

As far as not seeing them in the hierarchy, that's due to the HideFlags applied to the game objects. If you search through the entire project with Visual studio or Mono Develop for HideFlags, and comment out the DFTFU ones you find (or just the specific ones you're interested in) you will see the missing gameobjects in the inspector.

Re: Bit of help getting started.

Posted: Sat Jun 27, 2015 9:07 am
by Interkarma
Ernisius wrote:I thought that enemies for example must be a gameobject, and all gameobjects appear in the hierarchy when they are created. I am clearly missing something, so would be grateful if anyone could save me some time by pointing me in the right direction.
Before getting stuck into StreamingWorld and the procedural side of things (which tends to hide game object for performance reasons in editor), I'd recommend working through a few of the tutorials to build a static dungeon & city to play around with. The Dungeon Basics tutorial is a great one to start with. You end up with a playable version of Privateer's Hold to explore with moving platforms, enemies, and basic combat. Everything is laid out nicely in the imported scene to play with as you see fit.

http://www.dfworkshop.net/?page_id=1364

These tutorials have been written for Unity 4 and DFTFU 1.2 so there will be some differences if you're using Unity 5 and DFTFU 1.3 Developer Preview. I'm about to release a close-to-final 1.3 preview in a day or so and will start updating all the documents over coming weeks.

For now, just try to keep in mind that everything does end up in the Hierarchy as a GameObject, so you're not really missing anything. Daggerfall is just a very huge, procedural-heavy game and we're laying everything out from native file formats in real-time. This necessarily means that a lot of game objects are instantiated 100% procedurally and often must be dynamically combined for performance reasons.

LypyL is correct that 1.3 release will start introducing prefabs for non-static elements such as lights, doors, and enemies. These are still augmented procedurally at runtime, but it will be easier to extend behaviours on these objects moving forwards. As a totally stupid example I made in my lunch break, I added a script to the city lights prefab to make them animate to music. In the same fashion, you could extend the enemy prefab to add custom AI, etc.

If you get stuck with anything, please don't hesitate to start a thread here. You're also welcome to contact me directly via email. :)

Good luck with getting started!