[FREE] Example(s) - Build System

Yes, its checking if the mesh has any overlapping actors of different collision channels.
In your case its overlapping with the ground.
You can either change the collision rules / remove them completely or again change the pivot point so that he is really below the mesh.
It is annoying to do that stuff but once you got how it is suppose to be it is fairly easy.

You trace and you set the pivot point of your mesh to the impact point, so the pivot point is going to be at the top border.
But you need a small gap between to make sure its not overlapping.

Later on you would change the mesh a little bit and the collision checks to make sure it works on actual terrain.

Yes im going to do that.
No thanks i got that already with disease and deacying food and such stuff… sooo much fun to make ! :slight_smile:

Hi Urm,

First off, what you have done here is awesome! Second, I downloaded the project and almost have everything setup but, I need some help and since you made this project I figured you would be able to help me. I set all of the events for interact, inventory, crafting, etc. However, when I play the game I don’t enter build mode (I don’t think). All of the hud shows up and I can interact with the chest, door, campfire, etc. I can’t enter building mode though. Also, which objects can you pickup? One more thing, the objects that you can pick up, which ones do you place in the world? If there is an easier way to contact you, feel free to let me know, otherwise thanks for your help.

Oh I thought it was a rocketbuild/incredibuild/octobuild visual studio thing :stuck_out_tongue: . good work anyway

Im glad you like it, i wish i had more time to work on this one :confused:
So you are implementing it in your project?
The build mode gehts entered when you use (function UseItem) with an item with ItemTyp = Building or just passing a itemstructure in Build function.
You can pick up every child class from MasterItem but be sure that the have their row in Table_Items, the row name has to be exactly like the class name.
It is your choice what objects you place in the world :slight_smile:

At the end of the week you can also contact me via email.
For now doing this here or via PM is totaly fine!

In case i did not really help you, send me a pm with some pictures / more information and i will help you.

Hi Urm,

Thanks for your response. My problem is that the line trace doesn’t work. So the character won’t pickup any objects. I don’t get any errors and I didn’t make any changes to the project you gave out. I just fixed the errors I was getting when I opened the project. I’m not sure if I am just not putting the correct objects into the game. Are you able to pickup objects like wood? If so, what class to I put into the world for the controller to pickup?

Thats weird. There should not be any errors.
I dont have any and i dont get any even if i download the project again.
What errors did you get?

The Linetrace only works on Item and Building collision channel, take a look if you have them at all and that the item meshes have the item channel and respond to traces.

I just turned on the debugging for the line trace and noticed that every time I moved my character it spawned a ton of line traces that didn’t even look in the direction of the player’s camera. Do you know what the cause of this would be?

Could be wrong trace calculations.
It “should” look like this:

And

Thank you for providing screenshots, I see my problem is that for the make array they are set to " 0] ObjectTypeQuery10" and " 1] Projectile". However, “Item” and “Building” do not show up in the drop down list. Any ideas on the cause for this?

To be honest, i have no idea what is causing any of this. As i said its working perfect for me :confused:

The problem might be the DefaultEngine.ini in the config directory.

These should be in there

+DefaultChannelResponses=(Channel=ECC_GameTraceChannel1,Name=“Building”,DefaultResponse=ECR_Block,bTraceType=False,bStaticObject=False)
+DefaultChannelResponses=(Channel=ECC_GameTraceChannel2,Name=“InvisibleBuildings”,DefaultResponse=ECR_Ignore,bTraceType=False,bStaticObject=False)
+DefaultChannelResponses=(Channel=ECC_GameTraceChannel3,Name=“BuildingOverlaps”,DefaultResponse=ECR_Ignore,bTraceType=False,bStaticObject=False)
+DefaultChannelResponses=(Channel=ECC_GameTraceChannel4,Name=“Item”,DefaultResponse=ECR_Overlap,bTraceType=False,bStaticObject=False)
+DefaultChannelResponses=(Channel=ECC_GameTraceChannel5,Name=“InUseInvisibleBuildings”,DefaultResponse=ECR_Ignore,bTraceType=False,bStaticObject=False)

in [/Script/Engine.CollisionProfile]

I redownloaded the project and loaded it up and everything works now. One question I do have though is, when I pick an item up it doesn’t destroy the actor, is this how it is supposed to be? Also, when I drag items from my inventory into my slot they don’t disappear from my inventory which allows me to duplicate the item by dragging it to the other 2 slots. Is there a way to remove it from the inventory when I drag it into my slot?

Go to MasterItem there are branches after Pick Up that are not connected. If you connect them the items get destroyed after picking up but thats in my opinion nothing you want for testing/playing around.
Slot? you mean the actionbar? The actionbar only saves a ItemClass not the item itself. Its just for quickusing an item from your inventory.
You could make it take the whole item if thats what you want but lets do that via PM.

I will PM you right now.

@Urm92 tested this out not a bad effort, I’m also working on a survival game but i used and adapted the ARPG inventory to my needs, i looked though some of your logic and some of it like the build system frame work you mite want to look at rebuilding if you plan to use this for more than single player, have a single build manager rather than creating a actor for each part you build.

Still a lot of work to do :stuck_out_tongue:
Performance is something i have to look into and gain some experience, thank you :slight_smile:

awesome I will follow

Hi Urm,

I am currently setting up this building system to my project and I changed the crafting widget and put it in the inventory widget to make it all one screen. I am having a problem though, when I play the game and I go to the crafting side and I click on one of the items in the list for example, foundation, nothing happens. All of the other buttons work fine. Any ideas on why this would be?

I would check if the mouse click is registered correctly.
Look into Widget_CraftItem and check OnMouseButtonDown , MousePressed and SetSelected.
After that look into Widget_Crafting SetCraftItem if it does what it should.

Its hard to say wihout any specific information.

Everything looks fine. I don’t get any errors after compiling. I do get errors when I exit the game. Here is my error log if it helps you:

It does!

First of all you dont have a valid character.
I hope you always set a valid controller for your widgets, if so you could use getOwningPlayerPawn cast it to your character and set it (do this in the Construction Script befor Init gets called.

The single one tells me that you need to look into SetSelected in Widget_ItemCraft plug Self into CraftWidget.