Search Unity

Laircraft: Voxel Engine

Discussion in 'Assets and Asset Store' started by LaireonGames, Feb 15, 2017.

  1. LaireonGames

    LaireonGames

    Joined:
    Nov 16, 2013
    Posts:
    705
    Ah lame, must be an older device I am guessing then. Ok so before I do that I gotta lay out some warnings that explain why texture arrays are used and things you will need to consider when removing them.

    1: They are awesome for performance. Its typically very slow for a graphics card to swap out a texture and draw a new one thus its much quicker to draw one big texture which is why atlases (and in this case arrays) are used instead

    2: Since you can't use arrays on that phone, an atlas would be your next logical assumption BUT Unity has a big limitation/flaw here that arrays fixes which is to do with its automatic mip mapping. If you make an atlas then its final mip maps are going to look S*** and garbled. This is a post I made where I first discovered all this: https://forum.unity.com/threads/fun...aps-and-atlased-textures.438941/#post-2840055

    3: If you don't use an atlas, its going to be slow, if you do it will look bad. I am not sure if there is an easier solution :( But give it a quick google, other people might have found other ways.

    So! To remove texture arrays basically take a look at the shaders. They read from the array and draw the correct texture according to the Z value given to the meshes UV field. So if the vertice of the mesh has the uv (0,0,5) its saying draw this section with texture 5 from the array. You could probably work some magic here to run a test on the shader alone without having to edit tons of code just to see if it works.

    Otherwise your going to have to take a look at the ChunkMeshCreator class in general, maybe replace the UV code with links to different materials instead (as a note, the more materials you use the slower things will be!)
     
  2. m_wasim_bashir

    m_wasim_bashir

    Joined:
    Oct 2, 2012
    Posts:
    25
    Okay Thank you so much for your help. I will keep in mind all things. :)
     
    LaireonGames likes this.
  3. brownboot67

    brownboot67

    Joined:
    Jan 5, 2013
    Posts:
    375
    To solve the Mip mapping get PVR TexTool and pack your own mips. Don't have Unity generate them for you. That'll let you keep the edges clean.
     
  4. m_wasim_bashir

    m_wasim_bashir

    Joined:
    Oct 2, 2012
    Posts:
    25
    Hi brownboot67 Have you made its mobile version?
    Because I have issue in only texture on some of old devices, Latest devices are working fine.
     
  5. brownboot67

    brownboot67

    Joined:
    Jan 5, 2013
    Posts:
    375
    The tool I'm recommending will let you solve one of the visual issues Laireon outlined in his post.

    You will still have to solve setting block uvs and changing the shaders if you haven't already.

    (I've made mobile games, I have not made mobile Laircraft)
     
  6. MrBeros

    MrBeros

    Joined:
    Aug 27, 2015
    Posts:
    27
    Laircraft looks really interessting.
    Maybe i will buy it.

    I had some issues in your demo. First, the character was falling down with no stop, after i managed to get back on the terrain, it begun to rain and the demo crashed. Im not sure if its because of the rain or just my stupid computer.

    Anyway, i have a question or more:
    In minecraft as example, you have a forge, did Laircraft hast this too?

    Can i change the weather and use Enviro instead?

    Thanks for your work and have a nice day :)
     
  7. LaireonGames

    LaireonGames

    Joined:
    Nov 16, 2013
    Posts:
    705
    Hey :)

    Oh not cool :/ Na if it crashed chances are its not your computer, I've not had any bug reports for the weather so I think the latest version should have fixed whatever bug you have found. Since 2.0 was a massive influx of features my focus between 2.0 and 3.0 is generally bug fixing and performance improvements, hoping to get an update with a start on that shipped to the store at some point this week.

    Anyway yup it has a forge! There should be a video about it on the store page showing how you can define what items can burn or smelt and turn into other things.

    I don't see why not! Weather is currently defined by temperature in the current position (its currently only done in 2D,so if you have a temperature of 27 it will be same temp up in the sky and at the core of the world). If its below a cold threshold it snows otherwise it rains and you can control how much if its a desert or rainforest. I've not used Enviro so I can't speak in more detail there I am afraid but I don't think it would be too hard to hook up Laircrafts weather to another system.
     
    MrBeros likes this.
  8. Gaming-Project

    Gaming-Project

    Joined:
    May 12, 2017
    Posts:
    13
    Hm, every time i want to build the game i get this errors:

    Assets/Laireon Games/Laircraft/Scripts/Item.cs(111,35): error CS1061: Type `Laircraft.ItemDatabase' does not contain a definition for `itemPickups' and no extension method `itemPickups' of type `Laircraft.ItemDatabase' could be found. Are you missing an assembly reference?


    Assets/Laireon Games/Tabbed Scroll Groups/Scripts/ItemDatabase.cs(130,13): error CS0103: The name `itemPickups' does not exist in the current context


    ...and im not very good with scripting >.<
     
  9. LaireonGames

    LaireonGames

    Joined:
    Nov 16, 2013
    Posts:
    705
    Oh good spot! I swear I made a test build before pushing the update but I obviously didn't, this one is my mistake. I'll push an update out to fix it in the next few minutes.

    Are you on the repository btw? If not you will have to wait until Unity processes my update to ge tthe fix (can take a couple days). If you want to be on it drop me an email to support@laireongames.co.uk with your invoice number and I can hook you up
     
  10. LaireonGames

    LaireonGames

    Joined:
    Nov 16, 2013
    Posts:
    705
    Also if you want a manual fix this one is really easy move this line:

    Code (CSharp):
    1.         public PooledObjects<Item> itemPickups = new PooledObjects<Item>();
    Which is at the bottom of the variables section of item database out of the section:

    #if(UNITY_EDITOR)

    Then you should be sorted :)
     
    Last edited: Feb 1, 2018
    Gaming-Project likes this.
  11. Gaming-Project

    Gaming-Project

    Joined:
    May 12, 2017
    Posts:
    13
    I love to find bugs. If i catch more i`ll let you know :)
     
  12. LaireonGames

    LaireonGames

    Joined:
    Nov 16, 2013
    Posts:
    705
    Please do! I would say I like fixing them but that aint true :p I like knowing they are gone though :D

    Edit: Pushed an update to the store with fixes for builds, hopefully wont be long before its live
     
    Last edited: Feb 1, 2018
  13. Ryry36

    Ryry36

    Joined:
    Nov 10, 2017
    Posts:
    32
    Hi I'm interested in buying this, however when playing the demo it seems really buggy. The Inventory is really unresponsive. for example, trying to split a stack of wood, for some reason I could only split it once. Then after that the slots start to bug out and get an image stuck in the slot when there's actually nothing in that spot. another thing that was super buggy was the placement of torches. It would place them in the air and not touching anything 95% of the time I placed a torch. Anyways I don't know if just the demo is bugged but if you fix these small issues and just overall polish the assets features, I would love to get this! It seems really feature rich!
     
  14. LaireonGames

    LaireonGames

    Joined:
    Nov 16, 2013
    Posts:
    705
    Hey Ryry36,

    Oh interesting one for the inventory and torches, I will take a look just now!

    The biggest problem I have right now for Laircraft is feedback, I am a one man band and can't afford QA so there are going to be bugs since the project is so huge but once they are spotted I get them sorted as soon as I can. That's why I offer a private repository so you can get updates instantly without having to wait on Unity approving each bug fix :)

    Saying that though I have a few regular customers who are giving me great reports and squashing tons of bugs, couple examples:

    https://trello.com/c/nZSbawCr/130-bug-fixes
    https://trello.com/c/pRuDnHJq/134-bug-fixes
    Edit: Ah found the torches bug, its to do with snow caps (at least I think its what your seeing!)
    Edit2: Just uploading a new demo, should fix the torch issues and some inventory ones but without specifics I likely didn't catch what you saw!
     
    Last edited: Feb 12, 2018
  15. Ryry36

    Ryry36

    Joined:
    Nov 10, 2017
    Posts:
    32
    Hi just tried the new demo, and while the torches are ALOT better, they still will float occasionally. Try placing a torch on a tree but aim the cursor near the edge of the block, with the player standing at a certain angle to the block. Also the inventory is still really broken. If you right click on a stack of 10 wood it will split, but then if you combine it again, you cant pick up the stack again. I was trying to move a mine cart rail that I placed and picked back up again, and it wouldn't move, and after exiting the inventory and opening it back up the whole UI for the slots and Items had disappeared. Awesome support though with a quick fix! And I'm happy to help! Here's some other bugs that I found just from playing the demo:

    1: Placing a torch or mine cart rails on snow that is placed over water will make it float. I suggest maybe getting rid of snow caps on top of water completely. or add an ice block underneath. A lot of bugs have to do with the snow caps and water. Destroying a snow cap on top of water will make the water block below it disappear.

    2:After hitting a cow It ran away from me but it would walk through any blocks instead of jumping up them. I read that AI was not really a priority for this asset so this isn't a big deal.

    3: If you try to change Key Bindings It can really bug out and change ALL Keys to one Key

    4: A river that was generated went over a Ravine and It was super bugged. However It may be that water is just still in development, so once you finish that it might be okay.

    5: Destroying a block that a torch is placed on will not destroy the torch so it will float.

    6: While exploring caves sometimes you will fall through the ground.

    7: Why does sand disappear when falling and it hits the ground?

    8: Jumping when below a block will clip through it. Also Maybe change the jumping so that you can only jump up one block and its not so floaty. Just an idea

    And here are some Ideas:

    1: For terrain generation, I noticed there's no big hills of grass, instead there's mountains of rock. maybe add a new biome with big grassy hills.

    2: Increase the size of the collider for torches and mine cart rails.

    3: Also maybe an option to not collide with certain blocks. Like the torch. I don't know if there is an option for this because I'm just going off the asset demo.

    4: Clouds in the sky / a skybox. It would also be great to only have the blue fog in rainy weather. Also I'm aware that I could probably figure out how to do this if I bought the asset LOL.

    That's It for now I'm definitely going to buy this if you continue the great support! How long will it be on sale for 50% off?
     
    Last edited: Feb 13, 2018
  16. LaireonGames

    LaireonGames

    Joined:
    Nov 16, 2013
    Posts:
    705
    Holy S*** sweet :D Might take me a couple evenings to get through these but honestly thanks so much for letting me know!

    1) Ice underneath snow is something on the to do but I am planning a more generic and customisable system, maybe you have a biome where you want to replace your dirt with mud as it rains etc etc. Bugs have a higher priority over new systems at the moment though.

    2) Yeah I didn't want to go mad on AI but this one should be an easy fix so I will stick it in!

    3) Wow, I'll try and find a repro for that one.

    4) Yeah water is still in development and rivers + ravines/caves is one I have yet to consider properly. Its pretty easy to turn on the checks to get it to spread in that scenario, however doing so efficiently is the real trick!

    5) This one is actually as planned, minecraft does the same thing (I think!), but I agree its strange and I thought it a bug when I first saw it. I'll consider making that logic customisable.

    6) Hmm.. ah ok yeah I know about this one, its one that needs a semi complex system to fix properly and yet to design it. Basically to speed up, well everything, chunks that are not visible to the player at first spawn with a giant cube as their collider. If you break or get near to that section then its real collider is fed into the physics. Efficiently detecting when to feed it in is the system that needs more thought for caves. I have some ideas just need to sit down and get it done.

    7) Oh it shouldn't, I did do a fair bit of work on falling blocks a couple patches ago so I might have missed something. Is it a specific block or all blocks (I'll check myself tonight but asking incase you reply before I finish my 9-5)

    8) Hm.. thats a tougher one! Could move the camera so its in the players torso but then the world will look distortedly tall. I'll think about/look into it but not sure what the solution for it would be.

    1) This is very much project specific :) I added in some basic biomes but didn't want to make too many examples in an attempt to reduce asset flipping. So I aim to provide enoguh examples of what you can do, but don't intend to try and make it feel like a full game. Another example is animals, I provide a cow model and sound effects to feel a bit more like a world, but I dont provide a sheep model to encourage people to replace with their own animals.

    2) This is customisable but I agree it should be in the demo. Basically for any block, you can add a custom collider, I have used the torches mesh as its collider which as you rightly noticed is too small.

    3) Yup that is in :) Grass decorations have trigger colliders, its a checkbox to make any item a trigger instead of solid.

    4) Yeah that should be easy to figure out :) Clouds I have left because there are SO many environment and weather solutions on the asset store. I did have Instant Good Day as an example but not updated it in a while and not had feedback around it so i assume everyone has been dropping in their preferred ones easily enough!

    Glad your interested and really thanks for the feedback it means a lot! I'm not sure how long it will be on sale for, thinking until the end of the month at least but it depends on how it does. If the sale makes me more money than the typical price I might try another month, if both go well then it might become the new price. For now though its too early to say if the price is better. Looking at similar money so far but of course double the sales and thus double support
     
  17. Ryry36

    Ryry36

    Joined:
    Nov 10, 2017
    Posts:
    32
    hahaha no problem! On the falling blocks problem it happens when there are blocks above it. for example under a tree. for some reason it is placed on top of the tree. also another idea would be to make it so that when looking at a torch, the box indicator should be the size of the torch not a full size block
     
  18. LaireonGames

    LaireonGames

    Joined:
    Nov 16, 2013
    Posts:
    705
    Ah cheers I will check that :) Yeah I have plans to do that but its pretty complex to get it right in all needed scenarios.

    Tackling the bugs btw! Not updated the build yet but will do so at the end of the evening
     
  19. Ryry36

    Ryry36

    Joined:
    Nov 10, 2017
    Posts:
    32
    Perfect! I was wondering how hard it would be to spawn an NPC in the houses?
     
  20. LaireonGames

    LaireonGames

    Joined:
    Nov 16, 2013
    Posts:
    705
    Shouldn't be at all. For stuff like that typically what you do is a make an empty block. So you make a block called say villager and say it has no mesh or collider. Blocks can spawn prefabs when they are created so you drag in your villager prefab and it will spawn when that block is placed. You probably also want to make a custom event to remove the block once its done, or you can have the villager do it when it spawns
     
  21. Ryry36

    Ryry36

    Joined:
    Nov 10, 2017
    Posts:
    32
    Cool so making something like a dungeon from Minecraft wouldn't be to hard? How could you make it spawn in caves? Also I'm buying right now!
     
  22. LaireonGames

    LaireonGames

    Joined:
    Nov 16, 2013
    Posts:
    705
    It depends on how complex you want the dungeon to be but overal it should be fairly easy. To get a very primitive, all dungeons are the same exampe there is a structure builder where you can make a layout for a dungeon, then get the biome to spawn it randomly. If you make enough variety then people wont really notice.

    Getting dynamic ones will be a bit trickier. You will probably want to copy the code I have for detecting when and where to spawn villages (FYI villages are Extremely primitive and just there as an example) and apply it underground instead.
     
  23. Ryry36

    Ryry36

    Joined:
    Nov 10, 2017
    Posts:
    32
    okay! sounds pretty simple!

    I'm having troubles importing my own basic texture for dirt. I followed your video tutorial and everytime I add my texture it just appears white/grey/blank. I checked my settings and they are all exactly the same as your dirt.
     
  24. LaireonGames

    LaireonGames

    Joined:
    Nov 16, 2013
    Posts:
    705
    hm.. any chance you could jump on the Discord? Bit quicker to debug that way :)

    https://discord.gg/nx6mtZz (You can join via a web browser and dont need to sign up if you dont want)

    Edit: I'm going to head offline soon. If you drop me a message there I will reply next time I am online and we can debug what is going on

    Edit2: These are the bugs fixed tonight: https://trello.com/c/LmmWN2vq/138-bug-fixes
     
    Last edited: Feb 14, 2018
  25. Ryry36

    Ryry36

    Joined:
    Nov 10, 2017
    Posts:
    32
    Sorry I couldn't get on in time! I ended up overwriting your textures with mine when saving them and for some reason it worked. So I'm good on that.

    edit: so apparently the textures have to be 128x128 in size. Mine were 32x32. also another question, I want to use pixelated graphics similar to minecraft. How do I get rid of the specular maps, emissive and normals of your textures? Can I just get rid of them or do I have to create new ones for my textures. I guess what I'm asking is are they required? I'm new to unity so I'm not sure how to do this. All I want is some pixelated blocks lol

    Good job on fixing those bugs so quickly. That might fix some of these to. How do I update when its released? Sorry for all the questions and the long posts!

    1: I noticed that the lighting is a little weird. for some reason the block that you place a torch on will be lit up on the left side, but is dark on the right side. I think it has to do with the normals, specular, or emissive maps. Also if you have a massive cave opening on the surface the lighting goes from bright to black instantly underneath blocks. Kinda hard to explain

    edit: after watching your video on lighting, I could tell that there was no bug in that previous version. The lighting actually looked really good! Don't know what happened in the version I'm using because its not good haha

    2: If you save and exit the game, then come back in, light from placed torches will not load. also if your in a cave and come back in you will fall through the ground

    3 :Also not sure why but I set the torch to isTrigger and every once in a while it will no longer allow me to destroy it/target it.

    4: Sand doesn't fall through water.

    5: placing a block underneath the player when falling with perfect timing will propel the player into the air like a rocket ship.

    6: I was messing with the ore's and found that when exploring caves I would never find any ore. I turned off the stone though and saw there is a ton of ore just not by caves. It would be cool if you could add a modifier to spawn in cave systems or something like that.

    7: Doors should be able to be activated on the top block as well as the bottom. It felt really weird to me that I could only open it with the bottom half.

    8: I found that if I changed the Min and Max amount of villages to be spawned in a region, in my case 3 and 3, It would not load chucks on my next play. then once I exited and tried to play again it would lock up unity, forcing me to task manager quit. this happened 3 times in a row and I had to completely reimport my project to fix it.

    7: I followed the tutorial on the structure builder but Its not working. When I try to place a block It doesn't do anything. I have oakwood selected. also when I hit "D" on the keyboard it doesn't switch to the clear tool. Also when I load the Big farm I get this weird structure of ice.

    8: I was trying to delete "dry dirt" under the blocks editor and It would pop up the confirm button but when I hit it nothing happens.


    9: still having major issues with Inventory. This probably needs the most attention right now to be honest. Sometimes I cant place an item in my hotbar from my inventory.​

    If you can Iron out all these bugs I could see this making a game just as good as Minecraft!
     
    Last edited: Feb 14, 2018
  26. LaireonGames

    LaireonGames

    Joined:
    Nov 16, 2013
    Posts:
    705
    Edit: Current fixes, got a good chunk sorted that I had enough info for: https://trello.com/c/LmmWN2vq/138-bug-fixes

    Wow ok!

    Textures: They don't need to be 128,128 if you don't want but if you want to change the size you have to make a new texture array (the texture editor has helpers to do that for you). The thing about texture arrays is all textures in them have to be the same size, so if your adding into my example ones then they indeed need to be 128 :)

    Other textures: Yup get rid if you don't want them! I would suggest taking a look at the main shader and also getting rid of them there to get a bit more performance. Also worth considering the Unlit shader examples I have in there.

    Updates: Don't worry about it :) Honestly i really like and need the feedback so this is great! Plus by asking here then more people can see how to solve similar issues. Updates is up to you really, you can either wait for the store updates (I tend to do them every couple of months so people dont have to update constantly) or if you want the fixes right away drop me an email with your invoice number and I can get you hooked up with SVN which I typically update nightly and is the real solution to getting updates properly as well. I have a video explaining it in a welcome/getting started email I send out with the repository access.

    1: Should be fixed now (Demo updated)

    2: Fixed

    3: I increased its collider last night and found a bug with the detection of small colliders in general so hopefully last nighs bug fixes will fix this as well :)

    4: This isn't happening for me, pretty sure my fix last night for sand and trees has fixed this already

    5: Ah now this one is a bit of a bitch, its sort of a Unity bug and I need to find a work around for it. Have you ever played Creativerse? Its free, on steam, been out for a few years, it has the same bug and is made in Unity :p So I am guessing they have yet to find a real solution either. I don't want to add a sort of catch solution if your moving so fast incase you add a feature to your game like a gravity lift that would let you move in a similar way. I'll take another look into it but can't promise a quick result on this one (looked into it and reduced how often it happens a few times).

    6: That would be surisingly expensive (in terms of processing) to do! I'll rethink the algorithm though and try and give some more control over it. Gonna stick this as a lower priority and focus on the bugs btw.

    7: Fixed

    8: Fixed

    7 (9): Will look into it! Any errors in the console? (Structure builder)

    8 (10): Hm.. any errors when you do? (Deleting dry block)

    9 (11): (Fixed some more major scenarios causing problems) Fair enough, I have actually recruited my wife to help with this (she is lead QA for another company as her day job) last night and she has found some repro steps for me. Actually your big posts helped her since it was something I could show her that i Really needed the help :p


    Honestly, again, this is invaluable. Thanks so much for pointing these out and being so patient! I will post progress as I fix them like last time. I am taking a half day from my day job to focus on these so should be able to get a fair few ticked off
     
    Last edited: Feb 14, 2018
  27. Ryry36

    Ryry36

    Joined:
    Nov 10, 2017
    Posts:
    32
    Wow! This is awesome! your making me a happy customer lol! I cant wait to play around with this after work! I tested the demo really quick and saw that a lot of those bugs really are fixed! I'll shoot you an email with my invoice so I can download later!
     
    LaireonGames likes this.
  28. Ryry36

    Ryry36

    Joined:
    Nov 10, 2017
    Posts:
    32
    So I'm still having troubles on using my own textures. Ive created a new texture array and have set all of my textures up. however I cant figure out how to use my texture array over the old one. Just by selecting it under the textures tab glitches out the whole blocks tab. maybe you can create an updated video of how to create our own texture arrays from scratch and use them.

    The sand will not fall through water if it is placed directly above the water, if its more than 1 block it will fall through fine though.

    The increased Torch collider is now to big lol. If you try to walk through a cave that's 1 block in width and there's a torch it will block the way. Obviously if you change it to the isTrigger you don't collide with it, however I still think that the collider should only be about 1.2 times the size of the torches mesh. This will allow the player to delete the block behind or underneath the torch but still be able to target the torch easily as well.

    I also realized if you place a torch and then destroy the block underneath it will destroy the torch. this is good except when the torch has connected to the side of a block. I feel like it should be destroyed when that block is mined rather than the one below it.

    Inventory is better but if you split the 10 wood and then place it into a separate slot, so you have 5 wood and 5 wood in two slots, and then pick up one and try to combine it again they wont combine.

    I don't get any errors for the structure builder unless I load in the spiral steps or the other structures. Do you want that one?

    As for Deleting dry dirt in the blocks editor I get this error:

    Retrieving array element but no array was provided
    UnityEditor.SerializedProperty:GetArrayElementAtIndex(Int32)
    Laircraft.BlockEditor:ConfirmedDelete() (at Assets/Laireon Games/Laircraft/Scripts/Editor/BlockEditor.cs:1257)
    Laircraft.BlockEditor:Draw(Rect) (at Assets/Laireon Games/Laircraft/Scripts/Editor/BlockEditor.cs:516)
    Laircraft.MainEditor:OnGUI() (at Assets/Laireon Games/Laircraft/Scripts/Editor/MainEditor.cs:72)
    UnityEngine.GUIUtility:processEvent(Int32, IntPtr)

    and

    NullReferenceException: Object reference not set to an instance of an object
    Laircraft.BlockEditor.ConfirmedDelete () (at Assets/Laireon Games/Laircraft/Scripts/Editor/BlockEditor.cs:1257)
    Laircraft.BlockEditor.Draw (Rect position) (at Assets/Laireon Games/Laircraft/Scripts/Editor/BlockEditor.cs:516)
    Laircraft.MainEditor.OnGUI () (at Assets/Laireon Games/Laircraft/Scripts/Editor/MainEditor.cs:72)
    System.Reflection.MonoMethod.Invoke (System.Object obj, BindingFlags invokeAttr, System.Reflection.Binder binder, System.Object[] parameters, System.Globalization.CultureInfo culture) (at /Users/builduser/buildslave/mono/build/mcs/class/corlib/System.Reflection/MonoMethod.cs:222)
    Rethrow as TargetInvocationException: Exception has been thrown by the target of an invocation.
    System.Reflection.MonoMethod.Invoke (System.Object obj, BindingFlags invokeAttr, System.Reflection.Binder binder, System.Object[] parameters, System.Globalization.CultureInfo culture) (at /Users/builduser/buildslave/mono/build/mcs/class/corlib/System.Reflection/MonoMethod.cs:232)
    System.Reflection.MethodBase.Invoke (System.Object obj, System.Object[] parameters) (at /Users/builduser/buildslave/mono/build/mcs/class/corlib/System.Reflection/MethodBase.cs:115)
    UnityEditor.HostView.Invoke (System.String methodName, System.Object obj) (at C:/buildslave/unity/build/Editor/Mono/HostView.cs:285)
    UnityEditor.HostView.Invoke (System.String methodName) (at C:/buildslave/unity/build/Editor/Mono/HostView.cs:278)
    UnityEditor.HostView.InvokeOnGUI (Rect onGUIPosition) (at C:/buildslave/unity/build/Editor/Mono/HostView.cs:245)
     
    Last edited: Feb 16, 2018
  29. LaireonGames

    LaireonGames

    Joined:
    Nov 16, 2013
    Posts:
    705
    New Texture Array: Hmm.. come to think I have yet to make a completely new texture array since I updated the block editor to also exit textures (couple weeks ago). It sounds like a bug, I'll check that out this afternoon (busy this morning). Until I get back to you typically all you need to do once you make the new array is drag it into your materials. You can see a list of the current materials in use on the ChunkManager object. (Edit: I think I see what is going on. Basically your blocks are pointing at say texture 12, but you only have 3 in the array as an example. But, there is no option for the block editor to let you select a new texture when there is an invalid one. I will add a fix in for that just now. If its still causing you problems then I can make a new video)

    Sand: Ah ok! That should be an easy fix, just realised why this happens.

    Torch Collider: Oops! I was stupid... I must have updated the collider mesh rather than a custom selection one! Easy fix :) (Edit: I spoke too soon :p was dead simple to swap the colliders so will check that in tonight, however the extra collider will rotate to match the torch. Since I made the extra trigger a cube it means its not accurate, so you could technically select the torch from the block underneath but would be pretty hard to do. I will fix that side separately lately)

    Inventory: Something else must be going on :/ That seems too simple a scenario since I can combine like that just fine. Any chance of recording a video the steps of it happening? If you need a good free one I recommend Screen Cast o matic, I think you are doing something else to the wood to get it to bug out before you see that (then it probably does it all the time after). Last night we found a bug where if you split the wood and then combine it on the crafting slots (which you shouldn't be able to do) then it freaks out so I will have that one sorted soon if it was related.

    Structure Builder: Oh god sorry I never got around to that one yet, forgot to put it in my notes. Putting it in twice now to look at the structure builder!! Edit: Ha yeah I see some weird bugs there, my spiral steps have turned into a weird grass cigarette looking thing! Strange since that structure spawns fine into the world. Well, looking into it :D Edit2: should be fixed in the next merge, no need to update your structure files

    Deleting: Sweet those errors are perfect thanks! Deleting blocks is something I generally recommend avoiding btw once your project gets going (much safer to replace ones no longer needed). Reason being, I have to do a lot of checks when a block is deleting and a lot of room for error that I can't control. For example by removing one from the enum, everything shifts down one (So if snow is enum value 56 it becomes 55). Then I have to check for everywhere it is used, crafting, furnaces etc and try to compensate but sometimes there is nothing to be done (if your entire recipe needs a certain stick you delete, then its just broken :p ). I stick out as many warnings and errors in these scenarios as I can but its still something with a bit of risk! (Edit: I found the cause of the bug and seems to be deleting fine again)


    BTW I take it you got the repository setup with no issues? Going to put some changes into there soon, probably once I get these bugs ticked off, with the improved ore spawning solution so it favours cave walls. Turned out nicer and quicker than I thought :D
     
    Last edited: Feb 16, 2018
  30. Ryry36

    Ryry36

    Joined:
    Nov 10, 2017
    Posts:
    32
    Yup got the repository setup all good! Awesome news about the ores favoring caves! I will post a video of the inventory bug when I get the chance. Let me know when the update is out!

    edit: no need for a video I figured out that if you hold the mouse button down to pick up an inventory item and then let go to drop it, it gets buggy. also could you maybe add in an option to make new blocks that you pick up go to the hotbar if available?

    Also I noticed all of a sudden major lag when looking towards the ground. I also tried the demo and its now laggy? I don't know what could have caused this

    Lighting travels through blocks. I then tried to enclose my self in a box to see what would happen and the lighting kind of wigged out. I was playing around with the asset demo "Voxel Play" and it handles its lighting very well. Just personal opinion!

    If you place a torch on a block directly above you it is flipped upside down!

    If you break a block with the bucket in hand it will get rid of the bucket

    I also haven't really mentioned any bugs with water because I know that you are working on an update to improve it in general! Btw do you have an ETA on that?
     
    Last edited: Feb 18, 2018
  31. LaireonGames

    LaireonGames

    Joined:
    Nov 16, 2013
    Posts:
    705
    Sure thing, the update is going to be slower than usual since I am in the middle of a significant change to how I pool objects. This should be a better approach to keeping the inventory stable long term (which is what prompted the change) but it affects anything I pool in the engine, which is a lot.

    Hm.. I might still need the video but I will give it a try and let you know! I have a note for things favouring the hot bar to do for a while but like I say I am focusing on bugs rather than new features. Not entirely sure how I will tackle that one yet but its on my mind :)

    Lag: I did have to make a new system to fix one of the bugs you found (to do with falling through caves) so chances are its that. However I think I added an optimisation for it that is not in your branch or the demo yet. I'll hold off looking into it until you see that version since I have a feeling it will fix it, if not then I can take a look at the cause.

    Voxel Play: I actually hadn't heard of this one! But yeah their lighting is only nice because they don't have any ;) So if you dig and make a cave its the same light as the world which is very easy to do, you just set an ambient light, but it means you can never have proper lighting! Anyway as for your bug, can I see a screenshot of it travelling through a block? I'll try encompassing myself in blocks next working session and see what happens (not sure if I will work today, will be on Monday though).

    Torch: That is a feature :) Thought it looked better that way. If you want to disable it take a look at chunk mesh creator, there is a section of the code handling torches.

    Bucket: Huh! Weird one, will look into it.

    Water: Afraid not, hopefully I can get some more time on it this week though. Getting that inventory stable is my current focus, alongside the other bugs your reporting. Once I get the next update into the main branch I will get back on it.
     
  32. Ryry36

    Ryry36

    Joined:
    Nov 10, 2017
    Posts:
    32
    I would say your getting close to sorting all those bugs out after that! :)
     
  33. LaireonGames

    LaireonGames

    Joined:
    Nov 16, 2013
    Posts:
    705
    :D still working on the revamped inventory system btw, taking me longer than I would like but tons of scenarios to check. Once its done those are still on my list :)

    Edit: ok so the bucket breaking one was an easy fix, needed to add extra options to allow for infinite durability since before it was getting destroyed since it had 0 durability.

    Inventory is looking good so far but going to wait until tonight when my wife gets a chance to give it some QA before I stick it in the main branch.

    Looked at the lighting issue, its a complex one. But I see the problem, when i was encompassed with blocks it was bright and should have been pitch black. Not going to be an easy one to fix but working on it. If inventory looks good tonight I will leave this fix out of the branch so it doesn't hold up the other bug fixes

    Edit2: Bleh found more bugs in the new inventory :p Kinda expected to, new system and all but making good progress.

    If you want the fix for buckets before i post an update head to the tools tab and up its durability to 1000 or something as a temporary solution

    Edit3: Alright inventory is looking good again, gonna wait until tonight again to see what else breaks!

    In the meantime got started on the lighting bug and figured it out. Reworked the entire system which is now a bit quicker, much more reliable and fixes the bug you found. Still got a bit of work to do to tidy it up but the first pass of it looks really promising
     
    Last edited: Feb 21, 2018
    MrBeros likes this.
  34. Ryry36

    Ryry36

    Joined:
    Nov 10, 2017
    Posts:
    32
    Just tried it out and Its much better performance wise! However there's a few new bugs! I know your still working hard on these but wanted to list some!

    The torches seem to lose there light for some reason.

    If clicking water but the bucket is already full of water it will give you a new water block.

    The inventory is still buggy, hard to say what caused my problems, I was just splitting and stacking the wood stack like crazy lol. Also cant place anything in the Hotbar.
     
    Last edited: Feb 23, 2018
  35. LaireonGames

    LaireonGames

    Joined:
    Nov 16, 2013
    Posts:
    705
    Lame :p But as expected, there is a lot new in it :)

    Torches: strange since I have doubled their intensity! Part of the performance increasing is ensuring lights are turned off properly when they are off screen so if its happening when you turn around it could explain it. Edit: This was indeed to do with turning around. Working on a fix now

    Water: I still need a full system for this one, picking up water is not working at all (picking it up is fairly easy, getting all its linked water to contract properly is the tough part!)

    Inventory: Hmm.. that doesn't sound right one of the problems I had was crafting something and dragging it directly to the hot bar so I know that was working :/ I'll go check nothing got messed up in the merge in a bit, got some work to do this morning first.

    Edit: Ok just checked and can swap between the main inventory and the quick bar, might be worth dropping me a message on discord or summate so we can debug. I did notice an issue when scrolling the mousewheel on the quickbar though, it seems to mess up the order so looking into that now (Just found and fixed that, was nice and easy. I will put the fix into the main branch tonight)
     
    Last edited: Feb 23, 2018
  36. Ryry36

    Ryry36

    Joined:
    Nov 10, 2017
    Posts:
    32
    As far as the inventory goes just split the wood and move it around a little and restack it a few times and then place it in your hotbar. I found that just by doing this is usually bugs out!

    I think that I must be weird but the torches are still not always connecting to a block and start floating and it really bugs me ;)

    I'm still having troubles with adding in a new texture array. I'm able to select my new textures in the Blocks editor / tab but It is still using your old textures but just in the wrong order.

    Keep us posted on when the update is out! :)
     
  37. LaireonGames

    LaireonGames

    Joined:
    Nov 16, 2013
    Posts:
    705
    Inventory: I 'think' (getting a sense of deja vu!) I have fixed this one in the latest update. About to push it to the main branch.

    Torches: Ha na everyone is different and wants different things :) Looking at the code there is no simple single line change you can make to get the behaviour you want. I'll make a point of getting something like that in there today. Edit: got this tacked onto the last release, should be in the main branch!

    Textures: Can you send me a video of this in action? I had no issues making a new array before so chances are you missed something and I didn't make it clear what it is. I can also send you a quick video of the steps I took to see if you can spot what you are doing differently if thats easier.

    Update: Actually yeah sorry it has been a few days since my last one. I have a fairly big one building up, I've just posted a comment on the trello board with the release notes for it and will merge it into the main branch in a minute. As a sort of note/known issues I found some bugs in the chests inventory UI last night. I've fixed the major ones but not given it a full sweep to see if everything is working, if you spot any bugs in them its worth letting me know!
     
    Last edited: Feb 27, 2018
  38. Ryry36

    Ryry36

    Joined:
    Nov 10, 2017
    Posts:
    32
    Yeah the Inventory is fixed In the latest build! Finally some good news lol!

    I wanted to mention that I just tried the crafting and its a little awkward that you have to put stuff in the exact slot to get that it to work. for example to make sticks you have to have the wood in the top left slot or it wont work. Don't know how easy this would be to fix. Also I don't like having to use the X in the top right corner to take the wood back out of the crafting slots.

    I'm still having troubles with torches floating unfortunately, and lighting issues. I'll see if I can upload a video soon!

    edit:

    so heres a couple videos of some glitches I'm having!

    In this first video you can see a lot of the lighting issues, and the torch placement issues.
    I look around a lot like theres a glitch in the lighting when theres not, I was trying to see if it would gl



    in the second I just show where I can get to with textures, which are 32x32. Also there not mine I took them off the internet for testing purposes! The problem is they are super blurry/ not pixelated, I have them checked as point/no filter in the settings. Another problem is that they are really shiny in the light, I tried removing the normals and specular maps from the shader and they become super dark, so I'm not quite sure how to fix this. I couldn't record the process unfortunately it just recorded the screen playing the game



    I tried to email you the videos but it wouldn't let me:)
     
    Last edited: Feb 27, 2018
    LaireonGames likes this.
  39. LaireonGames

    LaireonGames

    Joined:
    Nov 16, 2013
    Posts:
    705
    Thank f**k :D Any other scenarios come up let me know

    Crafting: you can right click items in the grid to clear them as well but yeah I agree the exact recipe is annoying. I have a note on my todo list to look into shapeless crafting but no elegant solution has come to mind just yet (the editor makes it a bit fiddlier than usual). I might look into it tomorrow though now the build is looking healthier, I have been spending time on water improvements as well just sorta juggling what I can.

    Torch and Lighting: By lighting issues are you seeing things like an entire face is black seemingly randomly? I did put a fix in the main branch for that if so, might be worth double checking you have latest (I think I committed to the main branch 3 times today so it depends what time you downloaded it)
     
  40. Ryry36

    Ryry36

    Joined:
    Nov 10, 2017
    Posts:
    32
    hahaha well if you go to the first video at 0:16 you can see that one side of that block lights up like its in direct sunlight. and then at 2:15 you can see that it does go completely black after 2 blocks. I just redownloaded and am still having the same issues.
     
  41. HeadClot88

    HeadClot88

    Joined:
    Jul 3, 2012
    Posts:
    736
    @LaireonGames - You really need to make a in depth promo video for this asset. I almost past this asset over then I saw the amount of work that went into it.
     
    Last edited: Feb 28, 2018
  42. LaireonGames

    LaireonGames

    Joined:
    Nov 16, 2013
    Posts:
    705
    Wow yeah that video was Perfect thanks :D Got a busy day ahead of me but hopefully I can get these sorted for tonight, it seems fairly obvious what is going on so I'm hopeful its an easy enough fix.

    I see what you mean about the floating! I think the problem there is the cave roof since I had been testing in the open world. I should be able to get that sorted as well.

    Oops forgot to comment for the second video! Ah yeah that is your specular and an easy fix. removing the arrays from the material isn't quite enough. If you want that sort of approach for All your textures then you need to edit the shader, it would be dead simple in this case but not convinced you want that for every texture. Anyway the real fix, upload a black texture the same size as the rest of them into the specular slot and they wont shine at all.

    @HeadClot88 ha yeah tell me about it :p I've been juggling this alongside a full time job lately, never enough time in the day and all that! Saying that I did recently make a pitch video for the game I am making that uses Laircraft and it turned out awesome so I at least know someone who does great work there and will probably get him to re do it for me
     
    Last edited: Feb 28, 2018
  43. LaireonGames

    LaireonGames

    Joined:
    Nov 16, 2013
    Posts:
    705
    Alright new commit has gone onto the main branch, change log here as usual: https://trello.com/c/LmmWN2vq/138-bug-fixes

    I did notice some small scenarios still with lighting and floating issues and will try and catch them tomorrow but this one should be a big improvement over what you saw before!
     
  44. LaireonGames

    LaireonGames

    Joined:
    Nov 16, 2013
    Posts:
    705
    Just so everyone is aware I am going on holiday next week :D Should be back to normal on the 12th of March and hopefully flying out on the 3rd. I will probably check emails a few times but wont have work with me to look up source
     
  45. ghostboxer

    ghostboxer

    Joined:
    Dec 19, 2012
    Posts:
    8
    I must say this is in amazing asset, but I am having a bit of trouble wrapping my mind around the interaction between blocks and textures. When I use the supplied texture array, everything works fine, but when i supply my own the new blocks I created dont have a "TOP" texture available for me to assign. The other blocks' "Top" textures disappear as well as any block that has only a single face. What determines which of the cube faces are available to be assigned to?
     
  46. LaireonGames

    LaireonGames

    Joined:
    Nov 16, 2013
    Posts:
    705
    So glad you like it :D

    Hmm.. ah actually this sounds like a bug I have already fixed although I can't remember if its already live or just in the repository. When there is an empty top texture do you see a button that says reset?

    What is happening is that when you are using the example texture array your block will have a texture which is a reference within the array, say its index 25. But then when you make your own array it might only have 10 textures and be pointing to a now invalid value.

    Edit: yup this is definitely fixed in the repository but not made a new build for the store. I am in the middle of a water update so it might be a while before I get a build store ready. If you drop me an email to support@laireongames.co.uk with your invoice number I can hook you up to the repo so you can get the updates instead of waiting for the store build

    Edit2: an alternative is to select the blocks you want to change, change their texture to lava (or whatever is the very first texture in the array) then when you swap to your array it should be happy
     
    Last edited: Mar 13, 2018
  47. ghostboxer

    ghostboxer

    Joined:
    Dec 19, 2012
    Posts:
    8
    excellent, that makes sense. I spent a good while rumaging around through the editor code to try and understand the reasons why it was disappearing, with no luck. Also I do not see a reset button, other than the reset order button. Thanks for your timely response.

    I have one other question too, is there a way to effectively control the order of how a multi-selection of textures get put into the texture array? When i select my group of textures to make the texture array, they come in out of their numerical order. Furthermore, when I try to add the normals to a normals texture array in this same way, though all textures are named, numbered, and ordered a certain way in the project, they go into the array in a completely different order than the textures, and still not in the order they were selected. Ive tried adding them singly to match each to its texture, but doing so turns them grey and they loose their normal map qualities. Is there a certain texture setting i should be changing to avoid this?

    I appreciate all your hard work on this. you can tell a lot of blood, sweat, and tears have gone into this. This is the most robust block world asset on the store, or anywhere that I've found. I will email you my invoice number, because I do want to get regular updates. And I would like to check out how you optimize the water functionality.
     
  48. LaireonGames

    LaireonGames

    Joined:
    Nov 16, 2013
    Posts:
    705
    Ah sorry about that! I will try and get the water wrapped up soon so no one else has to go through the same problem.

    Hmm.. good point not considered that. The order will be controlled by Unity's secletion methods since all I do is iterate over your current selection. It doesn't take into account the order you select them sadly and just goes off of their names (at least it did last I looked a while back but I doubt it will have changed recently). I do have a task on my endlessly growing to do to be able to move and reorder your texture array but it always gets bumped as a low priority to bugs and world features.

    Ah they grey and normal map problem should be gone in the repository version, it has a ton of bug fixes in it: https://trello.com/c/LmmWN2vq/138-bug-fixes

    That one was to do with Unity versions, 2017 is a little quirky around normal maps compared to 5 so although the preview was grey it should have rendered properly. Wasn't the case though so its fixed now and the previews should match Unity's as well.

    Glad you like it, I appreciate the feedback :D Yeah a Lot of my time has gone into this over the years. It started out because the ones I found on the store at the time felt very like ticking a box and not going into everything that was needed, felt like a good gap to plug!

    Awesome once I get your email I will hook you up. Worth checking out the Discord group (details are in the email) or the Trello board above since its where I post updates and release notes
     
  49. johny256

    johny256

    Joined:
    Mar 3, 2015
    Posts:
    258
    hi. super asset, is plan Implementation Fiearm weapon?? and bow, fiearm m4 etc?
     
  50. LaireonGames

    LaireonGames

    Joined:
    Nov 16, 2013
    Posts:
    705
    Hey Johny, glad you like it!

    I did have a bow in there AGES ago so there is some code for it kicking around but I honestly forgot it was in there and no idea what state it is in :p Take a look for something called ArrowManager

    Otherwise for the engine I am sticking close to offering what minecraft offers so no intention to add other guns etc. I will make a point of going over that code though and ensuring bows up to par with the rest of the engine