English Stranded III Dev. Blog

69 replies
Goto Page
To the start Previous 1 2 3 4 Next To the start
Up
DC
Admin
Offline Off
UI to C# conversion progress
I made good progress with the conversion of the Stranded III UI system from Lua to C# (as mentioned in the previous blog entry).

√ finished / • nearly finished / × not started or very unfinished

√ Button
√ Icon button
√ Bar
√ Sprite
√ Label
√ Checkbox
√ Input
√ Context menus
√ Combobox
√ Optionbox
√ Slider
√ Listbox
• Tooltips
• Layout & window system
× Scrollbar
× Tabs
× Item Slots
× Drag & Drop

Now as the UI elements are programmed in C# instead of being scripted in Lua, I'll also expose a Lua API for them so you can very easily build your own custom menus.

Some new models
There's finally something visual again. Screw that broing chatter about weird code stuff, right?!

Shelter
This is a raw and unfinished version of the basic shelter. It's one of the most primitive buildings in the game.
The shelter can be built quite quickly and it gives you a minimum protection from bad weather when sleeping.
IMG:http://stuff.unrealsoftware.de/pics/s3dev/models/shelter_ingame_pre.jpg

> click to enlarge


It's a standalone building which means that it is not modular and can't be extended. At least that's the plan for now. I might change that later.

Hand Axe
Here's a real stone-age tool: The hand axe. It helps you to cut down trees. Of course it's pretty inefficient but still better than no tool at all.
IMG:http://stuff.unrealsoftware.de/pics/s3dev/models/hand_axe_pre.jpg

> click to enlarge

I wanted to make the texture look like the stone was processed to make it sharper. This didn't work out well unfortunately but I guess it will do for now.

Feather
I also made a feather. Yes, I'm not kidding. It's just a feather and for my standards I went quite crazy with the poly count there...
IMG:http://stuff.unrealsoftware.de/pics/s3dev/models/feather_pre.jpg

> click to enlarge


Unfortuantely I made some mistakes when making it. For example I didn't plan ahead properly and first made the 3D model and afterwards painted the feather texture on the exported UV layout.
When drawing the texture however I decided to make it more pointy at the upper end which doesn't really match the mesh geometry.
Luckily it's not a huge problem as you probably won't notice this flaw in game.
www.UnrealSoftware.de | www.CS2D.com | www.CarnageContest.com | Use the forum & avoid PMs!
29.03.17 01:57:53 pm
Up
DC
Admin
Offline Off
Again too much time without a dev blog entry! Sorry! Let's change that!

More Models at Sketchfab
I uploaded some more models to Sketchfab so you can see them in 3D.
I put some work in improving a few of the existing models. I made the palm tree bark texture more beautiful for instance.
Moreover I improved some bushes because the arrangement of the leaves was too boring and made them look too flat.

> Palm Tree @ Sketchfab
> Lifebuoy @ Sketchfab
> Driftwood @ Sketchfab

I also made some new plant variations. For example there are now more "curly" fern versions.
Didn't quite manage to achieve the look I actually wanted to achieve but I like it anyway:

> Curly Fern @ Sketchfab
(Sketchfab seems to have some alpha/z-sorting issues with that model)

And here are some more shrooms:
> Champignon @ Sketchfab
> Amanita Pantherina (Panther Cap) @ Sketchfab
> Amanita Muscaria (Fly Agaric) @ Sketchfab
(yes, both Aminata shrooms use the same model and I basically just re-colored the texture and changed some details. But hey, why not?)

Menus
I mentioned earlier that I want to move all basic menus (like the settings menu) to the C# code base instead of using Lua for them.
This process is nearly done. So not only the UI elements are now C# but also the menus themselves.

Of course you will still be able to create custom menus in Lua and for some menus there will be ways to influence/modify them a bit.
Moreover you will always be able to add additional elements to existing menus and to add sprites and effects.

There also have been some optimizations behind the scenes.
I moved all icons used by the UI to the same sprite atlas for example. This way Unity can batch stuff more efficiently and render the menus even faster.

I also drew some new icons:

IMG:http://stuff.unrealsoftware.de/pics/s3dev/settingsicons_pre.jpg

> click to enlarge


Research/Excursion: Baking
Even though Stranded III's art style doesn't imply high realism I want to be familiar with the mechanics in the game and how they would work in real life.

I'm sure that this kind of knowledge helps a lot to make better games. For Counter-Strike 2D for instance it helped me to fulfill my military service at the German Bundeswehr. That way I learned first-hand how real weapons actually work and managed to design them way more accurately in the game with details like recoil animations and muzzle smoke as well as bullet casing particles.

Therefore I decided to bake my own bread rolls. And I made pictures to document the process.

IMG:http://stuff.unrealsoftware.de/pics/s3dev/research/baking/breadrolls_01_pre.jpg

> click to enlarge


The ingredients are very simple:
• 250g flour (of course I used high quality type 1150 flour!)
• 150ml water
• 6g salt
• 21g yeast

(the recipe I used was everything of this times 2 but it was for 8 rolls and I only wanted to make 4 so I only took half of the original ingredients)

IMG:http://stuff.unrealsoftware.de/pics/s3dev/research/baking/breadrolls_02_pre.jpg

> click to enlarge


And actually the instructions on what to do are very simple as well... at least in theory...
Just put everything together, knead it very well, let it prove, bake. That's basically it.

IMG:http://stuff.unrealsoftware.de/pics/s3dev/research/baking/breadrolls_03_pre.jpg

> click to enlarge


After my first round of kneading my hands were so full of dough that I forgot to take a picture of the kneaded dough...
So here you can see the dough proving for 1 hour. Nicely covered with a wet towel.

The ultra sticky dough was actually my main problem during the whole "experiment".
It was caused by me not sticking to the recipe. When mixing the stuff the dough felt way too dry.
• What I should have done √ more kneading!
• What I did × adding more water

The worst thing about this: After searching for another recipe on the web I found one which warns you about exactly that mistake. It seems to be a common one among newbies.

Oh and in case you wonder: No, I never made any dough before.

It felt like wasting half of the dough when washing my hands after kneading because so much of it was stuck to them. It was horrible and no fun at all.

IMG:http://stuff.unrealsoftware.de/pics/s3dev/research/baking/breadrolls_04_pre.jpg

> click to enlarge


This is the dough after proving. Of course it was still way too wet and I was forced to add more flour to compensate the excess water. I'm not sure how much flour I had to add but it was quite a lot. So in the end I probably had more like 400g-450g of flour instead of the planned 250g.

Without extra flour I would not have been able to knead the dough properly and neither to form the rolls.

By the way: I tried to use the spoon to scrape some dough off my hands and the bowl. It didn't help much.

I wish I had photos of my hands after kneading the sticky dough. They looked absolutely disastrous. At that point I didn't dare to touch my smartphone (which I used for the photos) though.

IMG:http://stuff.unrealsoftware.de/pics/s3dev/research/baking/breadrolls_05_pre.jpg

> click to enlarge


Here are the formed rolls. I only wanted to eat two so I saved the rest of the dough which should easily be enough for two other rolls.

Fun fact: Note the smudges on the flour bag. That's because I somehow had to pour more flour into the bowl with my messed up hands.

Fun fact²: Note the wristwatch. After messing it up with dough as well I decided to take it off for kneading.

After forming the rolls there was another short proving phase.

IMG:http://stuff.unrealsoftware.de/pics/s3dev/research/baking/breadrolls_06_pre.jpg

> click to enlarge


Time to bake! Note that I added some sunflower seeds. Not only on top and bottom but also to the dough itself while kneading.

I didn't watch the clock while baking them at 220°C...

IMG:http://stuff.unrealsoftware.de/pics/s3dev/research/baking/breadrolls_07_pre.jpg

> click to enlarge


... but they were in the oven for too long.
This is the top view after baking...

IMG:http://stuff.unrealsoftware.de/pics/s3dev/research/baking/breadrolls_08_pre.jpg

> click to enlarge


... and this the bottom view. When only looking at the bottom one could think they were bread rolls actually made in a bakery, right?!

I then tried to cut one of them with a regular knife and failed. They were too hard.
This was probably caused by two things:
• Baked for too long
• Added too much flour without adding more yeast - leading to very dense rolls

IMG:http://stuff.unrealsoftware.de/pics/s3dev/research/baking/breadrolls_09_pre.jpg

> click to enlarge


I then took a better knife and finally managed to cut the bread roll. A lot of hot and good smelling steam streamed out of it. It was an amazing moment
As you might see it was indeed quite dense. Also it wasn't salty enough. Again a problem probably caused by the additional flour.

I have to admit that I already ate better bread rolls but these ones were still quite okay for my very first self-made ones!

So what did I learn in the whole process?
• Baking bread (rolls) is quite some work even though the recipe is so simple
• It's crucial to get the flour/water ratio right otherwise kneading will be hell
• When adding (a lot) more flour you should also add more salt & yeast
• It causes backache if you're tall and don't have an extra high working top

How will this new knowledge affect Stranded III?
• Like in Stranded II bread will probably stay a powerful item for nutrition because it is difficult to produce
• Kneading dough will probably take (a short) time unlike in Stranded II where it happened instantly
• Idea: Having a proper kitchen(-table) could give you a bonus on kneading speed and dough/bread quality

Will I do more real life research like this in future?
Maybe but I have no plans yet. I can't (and don't want to!) try everything which is part of a survival situation however.
edited 13×, last 30.03.17 12:55:52 am
www.UnrealSoftware.de | www.CS2D.com | www.CarnageContest.com | Use the forum & avoid PMs!
06.05.17 07:19:43 pm
Up
DC
Admin
Offline Off
Y U NO WRITE BLOG ENTRY?!
I didn't update the dev blog for 38 days and that's bad
But I have an excuse: I worked a lot on CS2D which is now on Steam Greenlight:
IMG:http://www.unrealsoftware.de/img/game_cs2d_greenlight.jpg


If you don't know CS2D: It's a free tactical top-down multiplayer shooter and working on it helped me to gather a lot of experience in multiplayer game programming. This knowledge will also help me to make Stranded III a better game.

You can learn more about CS2D at www.CS2D.com

Do you like CS2D AND have a Steam account? Then please vote for it on Steam Greenlight!

Anyway! There's also some Stranded III progress!

Fish
I spent some time making fish models/textures.

I already modeled the suregonfish earlier but now I finally painted a texture for it
> Surgeonfish @ Sketchfab

Missing Nemo? Here you go!
> Clownfish @ Sketchfab

IMG:http://stuff.unrealsoftware.de/pics/s3dev/models/clownfish_pre.jpg

> click to enlarge


Aaaand I also started working on a shark and made two videos.
The first video is about the modelling process in Blender:
> Shark Modelling @ YouTube
And the second video about painting the texture in Photosh.op on my Cintiq pen tablet:
> Shark Texture Painting @ YouTube

IMG:http://stuff.unrealsoftware.de/pics/s3dev/models/shark_pre.jpg

> click to enlarge


Note that after taking a look at some other references I decided to adjust the dorsal fin and some other details.
I didn't record these changes but you can see the changes on the model when you compare the models in both videos or take a look at the image above which shows the adjusted version.
edited 1×, last 06.05.17 07:49:53 pm
www.UnrealSoftware.de | www.CS2D.com | www.CarnageContest.com | Use the forum & avoid PMs!
21.05.17 09:33:00 pm
Up
DC
Admin
Offline Off
Sprite Sorting Layers
Looks like Unity improved the sorting layer scripting API in one of the 5.X versions!
I adjusted my code and made it much cleaner and simpler using the new API. No longer setting layers by string ID and getting the int ID afterwards.
I described that ugly hack in dev blog #28 back in 2015 and I'm really happy that it is not required anymore!

Food
Eating food is important if you want to survive. So I made some more food models.

Meat for instance:
IMG:http://stuff.unrealsoftware.de/pics/s3dev/models/meat_big_pre.jpg

> click to enlarge


And berries. They are insanely high poly (80 tris each!) for my standards and yes, they are basically just spheres. MADNESS! No idea why I'm even showing them...
IMG:http://stuff.unrealsoftware.de/pics/s3dev/models/berries_pre.jpg

> click to enlarge


Note that these are intended for single berries / as inventory item. When they grow on a bush I'll probably use another model with a bunch of lower poly berries. Maybe something like the Stranded I berries?! Each of them consists of just 6 tris:
IMG:http://stuff.unrealsoftware.de/pics/s3dev/s1_berries.jpg

- don't click to enlarge - it's so low res that a bigger version of this image would just look worse. haha -

Drinks
Drinking is even more important than eating. My current plan is to have containers which can be filled with liquids. With liquids I mean the obvious stuff like water but also other things like wine or milk. Without a proper container you won't be able to take any liquids with you. One of these containers would be.... a bottle.
IMG:http://stuff.unrealsoftware.de/pics/s3dev/models/bottle_pre.jpg

> click to enlarge

This mesh also has quite some polys. That's because it's round and because the glass has an actual thickness so there are also triangles/faces inside. You can see it if you take a close look at the transparent wire frame pictures.

I think the rendered version from Blender looks pretty cool. I hope I can find a proper shader / the right material settings for Unity3D to make it look like this - or maybe even better?! - in-game. I didn't try that yet.
www.UnrealSoftware.de | www.CS2D.com | www.CarnageContest.com | Use the forum & avoid PMs!
05.06.17 07:47:25 pm
Up
DC
Admin
Offline Off
CS2D
All that CS2D Greenlight stuff was kind of distracting for me recently. The good news: CS2D is currently on Rank #1 on Greenlight with nearly 12k yes votes! Thank you all for your amazing support!
> See CS2D on Steam Greenlight
> Try CS2D! Free download at CS2D.com

UI
Do you remember when I wrote about converting the Lua UI elements to C#?
I now worked on the Lua API of the C# UI elements so you can use them in Lua to easily and quickly build your own dialogs, windows and UI elements.
There are a lot of different UI elements with many settings so it will be a lot of fun to document all this...

I also rebuilt the inventory menu now using the new Lua UI API.
Most in-game menus will be fully scripted while most of the stuff in the main menu will be hardcoded but extendable.

Models
I made a sardine. I'm not convinced by the result yet and I guess I will touch it again later. Luckily sardines are quite small so it's okay for now.
> Sardine skin painting time lapse @ YouTube

Furtheremore there's now a bandage:
IMG:http://stuff.unrealsoftware.de/pics/s3dev/models/bandage_pre.jpg

> click to enlarge


Which can be found in this useful first aid kit - well, if you're lucky enough to have one:
IMG:http://stuff.unrealsoftware.de/pics/s3dev/models/firstaidkit_pre.jpg

> click to enlarge

> see 3D model @ Sketchfab
www.UnrealSoftware.de | www.CS2D.com | www.CarnageContest.com | Use the forum & avoid PMs!
11.06.17 08:35:07 pm
Up
DC
Admin
Offline Off
3D Inventory Items
Why should I waste video memory and effort for 2D item icons? I have cool 3D meshes!
Unity 3D is - as the name implies - a 3D engine. An the entire UI is in fact 3D too. It just looks 2D. I can easily mix in 3D meshes! And that's what I did:
IMG:http://stuff.unrealsoftware.de/pics/s3dev/ui/inventory3d.gif


Fun stuff!
I'm using Graphics.DrawMesh (like I did for the icon preview rendering) this comes with the advantage that no game objects need to be instantiated for the 3D items in the inventory.

I use very simple code to get the right scaling for the 3D items:
Code:
1
2
3
4
Bounds bounds = mesh.bounds;
Vector3 boundsSize = bounds.size;
float maxBounds = Mathf.Max(boundsSize.x, Mathf.Max(boundsSize.y, boundsSize.z));
float scaleValue = 0.32f / maxBounds;

So I'm basically just getting the axis where the mesh bounds are the highest and then I use that for scaling. 0.32f is used because the UI has a scale of 100 units per pixel and inventory slots have a size of 32x32 pixels. 32/100 = 0.32f.

As you can see in the gif some items do not fit perfectly. That's mainly the case for items which are not "centered" in the coordinate system. The best example for this problem are the mushrooms. Their center is at their bottom, not in the middle of the mesh. I guess and hope that it isn't a huge problem to fix that. Letting these items rotate around their actual center might be a bit trickier though.

By the way regarding rotation: The way the items are rotating in the gif is just an example. The rotation in the final game will look differently. Maybe the items won't rotate at all or only a little bit. I have to find out what looks best. I also plan to make them scale up a bit when you hover them.

If you ask yourself what the first item is: It's a backpack without texture and which I accidentally exported with weird and messed up scaling.

Oh and please also note that I did not set up the materials for all these items properly yet. They all look a bit glossy and for many it really doesn't make much sense. I know!

Sorry for the long* post. Here's a potato!
IMG:http://stuff.unrealsoftware.de/pics/s3dev/models/potato_pre.jpg

> click to enlarge




*) I'm aware that the post is not that long at all. 9gag people will understand.
www.UnrealSoftware.de | www.CS2D.com | www.CarnageContest.com | Use the forum & avoid PMs!
18.06.17 08:48:55 pm
Up
DC
Admin
Offline Off
Inventory Item Offset
Remember the mushroom problem from last blog entry? The offset?
I solved it and it was easier than expected. The solution was to get the Renderer component and to use the center of its bounds. This offset needs to be subtracted from the original rendering position, taking the object rotation into account. Here's a code sample:
Code:
1
2
3
4
5
6
7
Quaternion renderRot = GetFancyRotationStuff()
Vector3 renderPos = GetFancyPositionStuff()

Renderer renderer = GameObject.GetComponent<Renderer>();
renderPos += renderRot * -renderer.bounds.center;

// do render stuff using renderPos and renderRot


Here you can see the result of that change. No weird offsets anymore!
IMG:http://stuff.unrealsoftware.de/pics/s3dev/ui/inventory3d_v2.gif

You can also see that I tried less annoying rotation and added a "scale on hover" effect. This is still work in progress and needs some fine tuning.
Colors are pretty ugly due to bad gif compression.

Backpack
It really annoyed me to see the white backpack in my inventory so I textured it!
IMG:http://stuff.unrealsoftware.de/pics/s3dev/models/backpack_pre.jpg

> click to enlarge

I should have double checked the geometry before UV mapping. Now there's crazy stretching going on in some places but... hell.. whatever!

100
I did it! I made a model with exactly 100 tris! I didn't even plan it. Coincidence? Fortune? One thing is for sure: It's a tremendous achievement. People will tell the amazing story about the model with exactly one hundred triangles for centuries to come. And what majestic thing did I create while randomly hitting that wonderful triangle count? A snail. A slimy little snail. Not even a very good one (I screwed something up with the shell and I don't want to talk about it). Great!
IMG:http://stuff.unrealsoftware.de/pics/s3dev/models/snail_pre.jpg

> click to enlarge
edited 1×, last 18.06.17 09:10:06 pm
www.UnrealSoftware.de | www.CS2D.com | www.CarnageContest.com | Use the forum & avoid PMs!
02.07.17 10:45:48 pm
Up
DC
Admin
Offline Off
Crab
Another animal! It's a crab!
IMG:http://stuff.unrealsoftware.de/pics/s3dev/models/crab_pre.jpg

> click to enlarge

Oh yes, I know, insane triangle count for my standards but... these things have just SO MANY LEGS!

Arrows
I made some arrows. I plan to have more arrow variants in Stranded III than I had in Stranded II.

Currently the sharpened point arrow is the most simple one. It's basically a sharpened stick with feathers:
IMG:http://stuff.unrealsoftware.de/pics/s3dev/models/sharpened_point_arrow_pre.jpg

> click to enlarge


If you have a sharp stone you can also make the more advanced stone point arrow which will cause more damage:
IMG:http://stuff.unrealsoftware.de/pics/s3dev/models/stone_point_arrow_pre.jpg

> click to enlarge


You managed to get some poison somehow? Craft a poison arrow!
IMG:http://stuff.unrealsoftware.de/pics/s3dev/models/poison_arrow_pre.jpg

> click to enlarge


And you can also set stuff on fire with arrows. You just need a fire arrow to do so:
IMG:http://stuff.unrealsoftware.de/pics/s3dev/models/fire_arrow_pre.jpg

> click to enlarge


An arrow with a tranquilizer would also be pretty cool.
And I can think of a lot of other arrow types. E.g. other points like metal or teeth or bones. Or replacements for feathers like leaves or duct tape. There could even be a simple sharpened stick without feathers or anything. Of course that one would have a pretty low range when used as arrow.
edited 1×, last 02.07.17 11:34:23 pm
www.UnrealSoftware.de | www.CS2D.com | www.CarnageContest.com | Use the forum & avoid PMs!
09.07.17 11:38:34 pm
Up
DC
Admin
Offline Off
Clay Pot Skin
Do you remember the magnificient clay pot modeling video? No?
> Clay Pot Modelling Video @ YouTube
Finally, about one year later (oh my god...) I made a (simple) skin for that thing:
IMG:http://stuff.unrealsoftware.de/pics/s3dev/models/claypot_pre.jpg

> click to enlarge


Gecko
Yet another modelling video! I made a gecko!
> Gecko Modelling Video @ YouTube (20x time lapse)
I made the head extra big to make it look more cute

And I painted a texture for it because white models are boring (racism not intended):
> Gecko Texturing Video @ YouTube (30x time lapse)

Here's the textured model:
IMG:http://stuff.unrealsoftware.de/pics/s3dev/models/gecko_pre.jpg

> click to enlarge


I'm not entirely happy with the texture
I rushed the texture painting a bit and it could be better. Also some weird UV texture stretching is going on along the mirror axis...
It's not a huge problem for this model because it just stretches the red pattern a bit. It actually looks kind of intersting, but... this effect isn't intended...
www.UnrealSoftware.de | www.CS2D.com | www.CarnageContest.com | Use the forum & avoid PMs!
16.07.17 08:43:09 pm
Up
DC
Admin
Offline Off
Kits & Boxes
I changed the color of the first aid kit because red simply seems to make more sense (and because of my recylcing efforts):
> First Aid Kit @ Sketchfab

Recycling FTW! Ammo boxes normally totally don't look like plastic first aid kits. They are boxy wooden or metal crates. I don't care. I just took the first aid kit and changed its texture to look a bit like a (somewhat weird) ammo box.
> Ammo Box @ Sketchfab

<Random Justification>
Even though this is not what a real world ammo box looks like, I somehow embrace the fact that the boxes/kits in the game look alike. This makes them easily readable for players. I may still decide to change that later.
</Random Justification>

Tiger Model
I'm working on a tiger model. You can see my current progress in the following video. It took quite long (over 2h) so I made a 40x time lapse. The video is available in HD @ 60 FPS!
> Tiger Modelling @ YouTube
The head still needs some changes. Looks too much like a bear. But I guess that a texture would also help a lot to fix that issue

Some words about how I create my models:
I do not blindly model them from my head of course. I have a second screen with reference images and sometimes even reference models. You can't see that screen in the video so I thought it would be good to mention it. The reference stuff allows me to quickly check proportions and details without minimizing Blender. Watch the taskbar closely and you can see when I switch to Chrome on my second screen to rotate my 3D Sketchfab reference. I use a mirror modifier in Blender. This way I only have to model one side of the model. The other side is just mirrored. Thank god that most animals are symmetrical! Other than that I'm mainly extruding, moving, scaling, rotating, knifing and merging stuff to make my models. For animals I like to start with boxes and to extrude them as required. When I make items I normally don't use the mirror modifier and I start with one of the primitive base shapes from Blender which is closest to what I want to make.

Unity 2017
Unity recently released the new major version of Unity: Unity 2017. I did not migrate Stranded III to the new version yet but I plan to do so because I want to take advantage of the improvements.

The downside of this is Unity's new licensing model. I had a expensive pro License for Unity 5 but they changed their license model to a monthly fee thing. I can understand that this is way better for them but I really hate monthly fees. Especially when they are rather high. My old Unity 5 Pro license is basically worthless now because I can't use Unity 2017 with it.

Is that a real problem? No, it isn't. The free version of Unity is basically feature complete. The only advantage of Pro is that you get some additional services and that you don't have to show the Unity splash screen in your game (and some limits in case you sell your games).

So I'll keep the free version for now.
www.UnrealSoftware.de | www.CS2D.com | www.CarnageContest.com | Use the forum & avoid PMs!
To the start Previous 1 2 3 4 Next To the start