#blueprint

402296 messages ยท Page 571 of 403

languid fog
#

Does anyone know why my finished event won't fire?

spark steppe
#

anyone had that it reported errors like "Accessed None trying to read property FooBar" while it does in fact seem to reference the correct object as the call on one of its methods works fine?!

tight schooner
#

@plucky aurora sounds like a question for #graphics

#

@trim matrix generally speaking people use a custom enumerator (enum) to distinguish between several mutually exclusive states rather than a series of boolean variables

#

so you should look into that

#

You also have to de-spaghettify your node graph layout before you show it to the channel

#

cuz reading spaghetti is hard

lyric flint
#

Hello everyone

#

I wanted to ask a question about events and I cant find an answer in the docs

#

So, can I continue the event outside the event?

#

and inside of Request Server To Do Action I want to somehow to end on a branch and if its true then continue to event Lights Not Working

lyric flint
#

actually

#

I will need this event many times

#

and its something like that

#

and It would be great if it wasn't necessary to always copy paste all that

maiden wadi
#

Typically, your Event RequestServerToDoAction, would be a function and return a boolean. And you could branch on that boolean before doing the RPC.

lyric flint
#

oh yeah that should work better thanks

#

Because I want from a client to run an event on server

#

replication rule?

#

If you mean that I should make the function multicast or running on server or running on client

#

I want something like unicast

maiden wadi
#

Yeah, not sure what you're looking to accomplish with these functions, was just offering an easy way to make the one easily branchable. For networking stuff it's likely there's a better way. What exactly is your use case with all of this? What does this do?

lyric flint
#

So I have button and I when is pressed I want to change a boolean on all actors of class

#

probably not so I would like to make something of a lobby system

#

I watched the ue4 tutorial about multiplayer

#

until video 19 I think

#

and then I hit a dead end probably cuz it was outdated

maiden wadi
#

Which machine do you want to change the boolean on? All machines? Just server? Just the client that pressed the button?

lyric flint
#

All machines

#

so kind of yea make all clients can execute server orders

maiden wadi
#

And the machine with the button can be any machine, not just the server machine?

lyric flint
#

wouldnt it work If I casted to the server?

maiden wadi
#

Hold up a sec, I'll explain.

lyric flint
#

oh you mean that I should check player controller if it is server

maiden wadi
#

@lyric flint Follow up question, what is the boolean? and in what actor is it? What's it for?

lyric flint
maiden wadi
#

Okay. So the bool is in a lamp?

lyric flint
#

yea exactly

maiden wadi
#

Okay. This is terrible usecase, but we'll still use GetAllActorsOfClass for testing.

lyric flint
#

so this could be done a different way?

maiden wadi
#

You make a ServerRPC in some actor that any client can own. Probably the controller, maybe their controlled pawn. Lets assume you put this RPC in the Controller. The button will get this local client's controller with GetPlayerController(0) and call this serverRPC. This will get you onto the server's version of the button clicker's controller. Now that we're on the server, you GetAllActorsOfClass of the class of the lamp. And then for each loop over those to set the boolean.

timber cloak
#

Anyone here has CLEAR understanding of using "REMOVE INDEX" Array, please? I am getting mixed answers here and there for this node alone only.

#

i want to remove the Hunter Array Index from PlayerController Array Index.

#

so where the green line actually goes to? I received mixed answers for this

#

some says the "Add" node, some says the Loop node, i even heard some told me it has to be directly to the PlayerController.

lyric flint
#

I cant find the function or something

maiden wadi
#

@lyric flint Start with the Widget, it should look something like this.

timber cloak
#

@unique flicker I have no clue, without the minus the amount won't be the exact amount, so i let it be with minus 1

lyric flint
timber cloak
#

i suspect the last index on the macro itself requires minus

#

i even previously saw this method from someone's video tutorial

#

you can try it, without a minus you won't get the same amount

#

anyone with clear understanding* on remove index array usage?

maiden wadi
#

@lyric flint You probably could. Just breaking it apart for understanding. But after that print, would be where you would get all the lamps, and set their replicated boolean.

timber cloak
#

i also don't understand why the engine gives me EXTRA one more amount if i don't give a minus

#

it's the results

lyric flint
#

oh wait I think I do

#

why do we need to print string?

#

I have seen this elsewhere but didnt understand also why

maiden wadi
#

You don't. It's there for understanding. It's just a test tool.

#

If you click that button with that setup, it would always print from the server machine It'd say like Server: Hello. If you put a print above on the SabotageLampAllTheLamps event, it would print something more like Client1: Hello

mental tendon
#

Hello everyone!

I am trying to take a screenshot of the game at runtime, than use it as a thumbnail for a widget.

cmd: HighResShot 1 "100" "100" "100" "100"

Tried it in the Execute command BP too.

I know the first int after HighResShot is the resolution multiplier and the rest is as follows

HighResShot filename=PATH (XxY OR Multiplier) CaptureX CaptureY CaptureW CaptureH

So I tried dividing subtracting random values you name it but all I got out from it is this:

which is an empty jpeg, or it looks like one... :(

It comes up as a green square in the file browser

timber cloak
#

@unique flicker so basically, the Hunter Array Index that is being "Add-ed", is removed from the PlayerController Array, correct?

#

just to clarify properly.

#

@unique flicker then what is the correct way to removed all the "Add-ed" players that goes into Hunter Array?

#

there's no video talks about Array, this is on my own study

lyric flint
timber cloak
#

otherwise, i won't even ask

#

my own study = learning to improve

lyric flint
timber cloak
#

i am learning to REMOVE INDEX after Adding them into new ARRAY Index

#

which was mentioned at start

#

i want to remove the Hunter Array Index from PlayerController Array Index.
so where the green line actually goes to? I received mixed answers for this

#

yeah i got that correct from start

maiden wadi
#

@lyric flint PlayerControllers only exist on the server and the owning client. Therefore whether you're on a client or a ListenServerClient, the PlayerController at index 0 will always be the local client's controller. Since that GetPlayerController(0) is from a widget, that means it's ran from that client.

timber cloak
#

someone who's pro at C++ told me i got it wrong

#

ah the minus-ing, i would like to find back the old tutorial video

lyric flint
timber cloak
#

how do you minus one from floats?

#

let me re-run several "Play" button to see if i get the accurate amount

#

yeah, i tried few times of play now, without MINUS one, i won't get the accurate amount

#

it gives extra one

#

let me try +1 and see

maiden wadi
#

@lyric flint The widget button's onclicked gets the local controller, casts it to the correct class, and calls the event "SabotageLampAllTheLamps" That in turn calls "ServerKillLampsDead" which is set to RunOnServer from the replication selection if you click on the Event. Hence why that print would always print from the server.

timber cloak
#

@unique flicker i tried +1, it gives me ANOTHER EXTRA 1, so basically +2

#

without + or -, i get extra 1

#

with -1, i get correct amount

#

with +1, i get +2

#

it's insane stuff, i don't even have any clue why the engine behaves this way

lyric flint
timber cloak
#

@unique flicker to double check my engine's For Loop Macro :

maiden wadi
#

@lyric flint If you want to create those custom events, yes. Clients can only interact with the server through ClientOwned Actors. By default, this is the PlayerController and the Pawn it possesses.

#

@drowsy thistle Because you didn't split the struct.

lyric flint
maiden wadi
#

@lyric flint Class hierarchy. Basically inheritance. UObject>Actor>Pawn>Character

lyric flint
#

Ohhhh thank you very much for everything you are the best ๐Ÿ˜„

maiden wadi
#

@timber cloak What exactly are you trying to do with that loop?

#

It looks like you're trying to translate an array of playercontrollers into a list of their controlled pawns? If that's correct?

timber cloak
#

@maiden wadi sorry didn't know you would response. Yes, correct. The update is here:

sterile wraith
#

does any one have experience with nDisplay here?

trim matrix
#

hey guys

#

i can't find destructible component in variables

#

how i can get this shit ?

steady apex
#

How can I create a static mesh component at runtime? ๐Ÿค”

sonic pine
#

Hiho i dont know why my widget cant take variables from my ThridPersonCharacter. 2 other Widgets can take that variables but this one can -.-

#

It looks like the other widgets but no "get Health", "get Vita", "get Stamina" Variable can be found.

steady apex
#

Try dragging of the Character Ref pin or unchecking context sensitive in the top right ๐Ÿ™‚

#

Might just be that you're not seeing the proper option

sonic pine
#

ok but i need to connect the Charref to the target ^^

maiden wadi
#

@timber cloak Why not just iterate over the PlayerControllers array, check if the controller pointer is valid, if it is, get it's pawn, cast it to the right pawn. If if that's valid, add it to the array of pawns and at the same time, remove that index from the ControllerArray?

timber cloak
#

@maiden wadi but then how do you get the Amount of "Pawn" that you wanted to cast to?

#

put a Integer Variable linked to Branch node before that part?

maiden wadi
#

I don't understand what you're asking?

timber cloak
#

your way is indeed better, less bloated and cleaner

#

well, like in my screen shot, there's "Number of Hunter" Variable Integer

#

so, if i put number of hunter is 3, it will get 3 from PlayerController Array

#

this was my screenshot

maiden wadi
#

Right. The only issue with that is that you have to keep that number, and your PlayerControllers array accurate at the same time. What does the PlayerControllers array represent? How is that being populated initially?

timber cloak
#

That was populated directly from "OnPostLogin" New Player node, straight forward

#

so with an Integer Variable like 'Number of Hunter", you definitely have to go my way, correct?

#

yours is directly convert whole PlayerController Array into another new Array

#

without any Integer Variable to select an amount

#

i would like to try your way with Integer Variable linked to Branch node prior your BP nodes

#

wait, can't lol

tired saddle
#

Is it safe to do remove index on an array while it's being iterated over?

timber cloak
#

i forgot branch is simply boolean lol

maiden wadi
#

I think I need more information on the end result for the logic. Number of Hunters is for what? Is that a total number of players?

timber cloak
#

my bad

maiden wadi
#

@tired saddle ReverseLoop.

timber cloak
#

Total of Players that will be selected as "Hunter" role.

#

so example, 5 players connected. "Number of Hunter" is 2, then the node will pick 2 players out of 5 players as Hunter.

#

correct right my way?

#

Yours is entirely convert the whole PlayerController Array as another new Array.

maiden wadi
#

Okay. So PlayerControllers is added to OnPostLogin, and then you pick a number of players to be hunters, and you want to add their pawn to the PawnArray and remove them from the PlayerControllers array?

timber cloak
#

correct

#

please correct me if my whole BP node is wrong

maiden wadi
#

Do you want it randomized from the PlayerControllers array? Or is it always deterministic?

timber cloak
#

already randomized. Randomed using after the "Add" PlayerController Array. i didn't mention due to not trying to be out of topic.

#

again, please correct me if i am wrong somewhere

maiden wadi
#

Okay. What you have there should be perfectly fine. Only change I'd make is to add the IsValid check for the controller before calling GetControlledPawn.

#

Perfectly okay to pass around possibly invalid pointers, but always check they're valid before calling functions on them or trying to get variable data from them. Unless your shuffle function does that, then I probably wouldn't worry.

timber cloak
#

i have no IsValid on my node. I suppose your IsValid will solve the random issue, which is, EVERY 1 out of 20 tests, there's usually extra 1 Hunter being spawned into the game.

maiden wadi
#

Yeah, not sure. That should only be affected by the integer NumberOfHunters, however that's set. The -1 on it for the loop is perfectly normal.

#

Theoretically I wouldn't think the controller check would solve that. Cause it wouldn't change the amount of times this is being called.

timber cloak
#

Like this? with IsValid "Input Object" selecting ThirdPersonCharacter

maiden wadi
timber cloak
#

i see. The minus -1 was not my question. But that guy was confused as to why I used -1 minus node

#

Therefore he asked you after I told him, that is the correct way to get the correct amount

maiden wadi
#

Yeah. Even if it was incorrect, that'd leave you with one less hunter, not one more.

timber cloak
#

I see. Thank you for correcting me.

maiden wadi
#

How is the number itself being calculated?

timber cloak
#

at the moment i leave it to ClassDefault Setting. I am doing this to learn the engine.

maiden wadi
#

So it's always the same number, but sometimes you have one MORE hunter? O.o

timber cloak
#

Yup correct sometimes with 1 more hunter. I ran the test very very frequently. About 1 week, since i made changes to code and trying something like calculating number of index inside Array

#

so if my guess is correct, it happens like ONCE every 20+ test.

maiden wadi
#

That's odd. As long as that integer doesn't change for any reason, it has nothing to do with this. If anything, this code would cause less to spawn.

timber cloak
#

i am going to try with IsValid now

#

actually, is there any difference between IsValid and IsValidIndex?

maiden wadi
#

@timber cloak Yes. IsValid is directly on the pointer. IsValidIndex is on the Array. For example, an Array can have a ValidIndex that is an Invalid pointer.

#

@timber cloak Best way to thoroughly explain that is consider this. You spawn ten actors and you add their actor pointers to an array. Then you destroy those actors. The array doesn't inherently automatically resize. Instead, you have ten array index points that all point to invalid objects. So if you used IsValidIndex 0-9 it would return true, IsValidIndex at index 10 would return false, since the array is 10 objects in size, and index starts at 0. Despite the 0-9 returning true on IsValidIndex though, that doesn't mean those Actor pointers point to valid objects. Specially since you destroyed them. So if you try to use these IsValidIndex pointers, they would throw errors. Which is why you have to check that the pointer itself is valid with the IsValid node.

timber cloak
#

okay, i ran the test over and over. It rarely gives 1 extra hunter. Like probably 1 out of 30-50 times of tests.

#

@maiden wadi appreciate that thorough explanation, very helpful. Thanks a lot really.

#

I have been wondering if you have multiple roles to be added into multiple arrays, instead of a single role like that "Hunter" role. What would one suggest to do this? Repeat it, even it means to be bloated and spaghettis ?

short pawn
#

I know this is an old response but I tried making them procedurally with no results. They are all different buttons for each collectible in my game

maiden wadi
#

@timber cloak Usually just make a single generalized function that can be called multiple times with differing inputs. There's multiple ways to accomplish it depending on desired code flow.

wispy pumice
#

Say how do I make this leaf transparent around the edges of the leaf texture? In Unity we would use alpha clipping but I'm not sure how it's done in Unreal

trim matrix
#

how would I lerp between more then 2 textures?

#

my brain cant figure it out

maiden wadi
#

@wispy pumice Not sure what AlphaClipping is, never used Unity, but I think you'd normally use a masking texture for that. #graphics channel is often a better place for material questions.

wispy pumice
#

Oh thanks and I'll keep that in mind next time sorry just realized I'm in the blueprint section

maiden wadi
#

@wispy pumice All good. Does that green leaf's Alpha have the right mask you need?

wispy pumice
#

no

#

it only came with two but I could just grab another

#

I was just testing a program for making tree's and it wasn't designed for Unreal

shadow saddle
#

im trying to exe my game

#

which one should i choose?

trim matrix
#

set the blend mode to masked

maiden wadi
#

@wispy pumice See the Blend Mode in the bottom left of your screenshot? It's currently on Opaque. Change that to Masked or Translucent depending on if you want a simple mask of a semi transparent texture.

trim matrix
#

if it has an alpha channel on it

#

but if youre making foliage

#

its more complicated then that

wispy pumice
#

Well I tried that and it just made it transparent

maiden wadi
#

Do masked, and plug a constant value of 1 into the OpacityMask

wispy pumice
#

Alright, thanks

maiden wadi
#

That'll at least keep it from being transparent I think. But you'll need an alpha mask, black and white texture to put there if you want per pixel visibility for the material.

wispy pumice
#

Alright, I think I'll try and use ShaderMap 4 to generate me one and see how that looks

shadow saddle
#

anyone know ?

#

shipping or debuf

#

debug

maiden wadi
#

@shadow saddle Isn't that kind of a question for yourself? Are you trying to ship it, or are you just debugging a cooked version of your game?

trim matrix
#

how do i make a scalar parameter only affect the one obj

#

have a simple cooking setup

#

but its cooking all the chicken legs

#

wanna keep it contained to one actor but being able to have as many as i want

#

does that make sense?

maiden wadi
#

Perfect sense. You just have to set the scalar parameter on that instance of the chicken leg.

trim matrix
#

how do i do that?

maiden wadi
#

Dunno. Depends on your setup. What are we even talking about? What is the Scalar parameter for? A MaterialInstance?

trim matrix
#

Yea it blends between 2 textures

#

obv this doesnt work cause its setting the value on ALL of them lol

maiden wadi
#

It's probable that you've somehow started all of these at the same time? It looks like it's already setting the instance's own value.

timber cloak
#

I wrote the entire thing in Paint to get a clearer picture

#

the bracket beside the name, is the amount of the occupation/job's role.

#

so for non-role type of jobs, it is straight forward.

trim matrix
#

@maiden wadi what?

timber cloak
#

Whereas, the "role" types of jobs, it is you become* either that or this.

maiden wadi
#

Specifically for the ones where it can be multiple types. Picking Doctors/Surgeons out for example. Is it always three of one or the other, or can you have say 2 doctors 1 surgeon?

timber cloak
#

You can't, only 3 doctors or 3 surgeons. Either 1. I don't mind randoming again but I am afraid it will be more complicated but good for learning purposes.

#

I am just trying to "level up" my learning skills.

#

going too far might be too complicated

maiden wadi
#

It's pretty much the same either way.

timber cloak
#

really? to me, it is simply a guessing game to code it

#

i would like to see the general/proper way of coding this.

maiden wadi
#

If we translate this into Unreal stuff. I assume that each one of these might be a player?

#

16 players for example.

timber cloak
#

correct. Total 16 players, all of them will be given roles/jobs randomly.

dense isle
#

I added Enable Music and Enable SFX properties to the PlayerSettings struct. Now they show up everywhere as non-connected pins.

Is there anyway to prevent this behavior? I want them to start hidden, not expanded

timber cloak
#

If they got the "roles" type of job, they will get either (this or that)

#

i should colour it out to avoid confusion.

dense isle
timber cloak
maiden wadi
#

Initial design concern would be how are the 16 roles selected to also match up with the fact that there are 16 players? If that's not a factor, the rest is easy.

trim matrix
#

is there always 16 players? thatd make it easier

timber cloak
#

do the normal way, "OnPostLogin" -> "Add" array node, "Promote Variable" into "PlayerController" Array.

#

unless this is not the correct way

timber cloak
maiden wadi
#

I'd probably just get a list of PlayerState pawns at the time of choosing.

timber cloak
#

It is purposely made to learn something new easier rather than guessing.

#

List of Struct/Enum?

#

Wouldn't it be better to be straight forward from GameMode?

trim matrix
#

well that makes it a lot harder cause how are you gonna divide the roles when theres lets say 12 players?

maiden wadi
#

For example. Instead of relying on the addition/subtraction from the array of people joining, Get it at runtime.

timber cloak
trim matrix
#

hm

timber cloak
maiden wadi
#

If you always know the 16 roles. You can just hardcode them. Otherwise you'd probably want to create a struct, that can be placed in an array, and assign roles along with weights for a randomization function to pick from.

timber cloak
#

the amount of 16 players is fixed. But the roles are GIVEN RANDOMLY to different people each time "Play" button is clicked.

maiden wadi
#

My initial thought is to create an array of roles based on the selection weights/limits to how many of each role there can be and then just iterate over the playerpawn's and assign them a role.

timber cloak
#

so basically, a struct of Arrays containing Arrays?

maiden wadi
#

Nah. Just a sec.

timber cloak
#

at first, i thought of copy-pasting the like how you showed me the "Hunter" role code earlier. And be bloated with BP nodes after lol

#

then i thought of enum with switch and selections

#

but then there's no integer to run enum switch/selection though. I could be mistaken

maiden wadi
#

What are the roles exactly? Different pawn classes?

timber cloak
#

nope, similar. It is simply to give another random array

#

You give random job to 16 differents players, if they get role type, you given them random role again

#

basically randoming 2nd time.

maiden wadi
#

What's in the array?

timber cloak
#

"Either 3 home tutors or 3 lecturers"

#

"Either 3 doctors or 3 surgeons"

#

"Either 2 electrical engineers or 2 material engineers"

#

random between 2 different jobs

#

1st random = give the job randomly to 16 different people
2nd random (if they get "role" type of job) = random again either (this or that job)

maiden wadi
#

I'm having trouble following that particular part. Back to the doctors part. Are there subclasses of Doctors? Or are you just rerandomizing between Doctors and Surgeons?

timber cloak
#

if you want to do another pattern of random on 2nd time randoming, like your question about "2 doctors and 1 surgeon". I would like to see this but i am afraid it gonna get complicated

#

There are no subclasses of Doctors. If you give 3 Medic Role to the 3 People. These 3 selected people, will become as either 3 Doctors or 3 Surgeons.

#

let me know if my explanation is bad. I will keep on re-explain until it is clear

maiden wadi
#

What is the 2nd randomization for?

trim matrix
#

this doesnt even work

#

cant connect half of the fucking pins

timber cloak
#

the 2nd randomization is choosing between 3 Doctors or 3 Surgeons.

#

if you get the "role" type of jobs.

#

if there's no "role" type of jobs like "Salesman" then just be "salesman", that's all.

#

Salesman, is basically like what we talked about earlier, the "Hunter" Array.

#

straight forward.

maiden wadi
#

What keeps confusing me is the end result. Do you want there to only be 3 doctors OR 3 surgeons when the game starts, or 3 medical people randomized between doctor and surgeon, so that there can be 1 doctor and 2 surgeons in game?

dusky dome
#

Hi guyes I have a quick question, thank you in advance. My problem is, that when I try to get the game mode on my client blueprint, it says the game mode is null. I'm not using any dedicated server, just set the Unreal play setting to be (max player 2, play as client). Wondering if there is a way to launch the game mode into the simulated server so that the client can get it?

maiden wadi
#

@dusky dome GameMode does not exist on clients. It only exists on the server machine.

dusky dome
#

this is the game mode class default

timber cloak
#

Do you want there to only be 3 doctors OR 3 surgeons when the game start
Yes. 3 doctors or 3 surgeons only. Whichever. Doctor/Surgeon.

so that there can be 1 doctor and 2 surgeons in game?
This part was what you asked earlier, which i then replied, that I am very afraid it will get complicated as learning purposes only.

dusky dome
#

right so for example, if i want to test my game locally without setting a dedicated server now, (possibly in the real game it will be an lan multiplayer), how could I do the setup?

timber cloak
#

The latter part, is definitely looks very advanced as you might need to* random for 3rd time (i think?)

maiden wadi
#

@dusky dome The difference between Dedicated or Listenserver doesn't matter. If you try to get your GameMode on a client actor it will be null.

timber cloak
#

use "Listen Server"

dusky dome
#

oh i get it

timber cloak
#

Click the arrow at "Play" button and select Listen Server

dusky dome
#

so listen server means that the editor will server as both a server and a client, and if the player number is more than 1, the 2nd window will play as client, right?

maiden wadi
#

Correct.

timber cloak
#

correct

#

it will tell you on the Window's name.

dusky dome
#

thanks!

odd ember
#

it's almost as if the editor wants to help you make your game

timber cloak
#

LOL

dusky dome
#

thanks!

maiden wadi
#

@timber cloak Okay. What gets changed based on the role? For example, you were making an array of Pawns? What were you doing to those if they were selected for being a Hunter?

timber cloak
#

So, hunter is the same as Salesman, Chef, and Dentist. All being randomize once.

#

Non-"role" name.

#

Those names with "roles" included, will be randomed again between the 2 choices stated. Like Medic Role, they will become as either Doctor or Surgeon.

maiden wadi
#

But why? For example, what happens to a player or their pawn when they become a Doctor?

timber cloak
#

they will be given ability to perform as a Doctor occupation.

#

So, salesman, Dentist, Hunter, Chef will straight forward be given ability to perform their occupation respectively.

#

complicated as a learning skill, right?

maiden wadi
#

So is it a setting in their Pawn?

timber cloak
#

i am thinking of struct of arrays containing arrays.

timber cloak
#

ability is given on ThirdPersonCharacter class Blueprint.

#

if they get dentist, they just gain ability to do dentistry job like cleaning/fixing teeth

#

what would be your way of doing this? Using Enum/Struct?

#

definitely not data table, right?

odd ember
#

datatables are for static final information that you want to load in

timber cloak
#

i see

maiden wadi
#

I think majorly it comes down to how different the subroles are. Also how many of them there are. Because if the Subroles are the actual classes, and you just want to categorize them, I'd just put all of the subroles in a huge enum table and make an array out of the larger roles with the larger roles being an entry in the array with a sub array of the subroles.

odd ember
#

or you could have an EducationManager taking inputs of your roles and assign them new ones based on what they're doing

#

or did you already cover that

#

a bit like a tech tree really

timber cloak
odd ember
#

I mean you'd want one class to act as a manager for all your peons

#

so basically any time the peons have spent enough time as a role or fulfilled whatever conditions you have

#

they would query the manager

#

the manager would then assign them new roles based on the data parsed

timber cloak
#

listening

odd ember
#

the manager would really just be a glorified lookup function that takes the data, measures it up against what is currently available in the tech tree, and reports back its findings

#

replace tech tree with role tree in your case

#

but the principle is the same

#

enums would probably be a bit bulky for this but they could work

#

and tbh I don't see great alternatives for them

#

but maybe the likes of @twilit heath would know

timber cloak
#

tech tree, that means using data tables, correct?

odd ember
#

I mean you could I guess represent it with data tables

#

since it's static

#

but you could probably find better ways of doing it too

#

perhaps a dictionary tree or some such cpp structure

timber cloak
#

I will try your way too. Thanks for the detailed inputs.

odd ember
#

I'm trying to think of if it's possible to do in BP

timber cloak
#

same been thinking for a week since.

odd ember
#

the tech tree

#

I reckon that you can't do it with structs

#

because you cannot link structs

#

of the same type

#

but

#

if you can link classes

#

you could link a series of BP objects as your nodes for your tech tree

#

those objects would need two variables

#

an array of next nodes to point to

#

and the conditions for reaching this node

#

that'll build a tree for you

timber cloak
#

or just do manually minus and plus until your BP is spaghetti

dusky dome
#

sorry just a quick question

timber cloak
#

okay basically the subclasses can be run Boolean switch

dusky dome
#

I know that playercontroller exist both on server and client, but yet in the Event BeginPlay, when I was trying to get the game mode, it gives me null

timber cloak
#

whereas the large/main class just repeat it and remove array index each time complete giving roles

dusky dome
#

is it normal?

#

my blueprint is derived from playercontroller class, so it should also be on both server and client, right?

odd ember
#

@dusky dome put a delay in before asking for it

#

see if it's null then

dusky dome
#

no luck, 1 second delay

odd ember
#

have you assigned a game mode in your project settings?

dusky dome
#

oh that could be the case! Let me try

#

no luck, default game mode (both server and local) are set to be the fpsgamemode

odd ember
dusky dome
#

thanks!

odd ember
#

dont have access to UE4 right now cant test it

ornate cairn
#

What's the most efficient way to make a dialogue system that reads from a file?

#

Like line-by-line

sterile wraith
#

is it possible to create a dropdown list in a blueprints Detail section which you populate dynamicaly when pressing a button(event trigger)

odd ember
#

@ornate cairn what do you mean "most efficient"?

ornate cairn
#

like I'm recreating a dialogue-heavy game in VR using UE4 and I have all of the dialogue already, is there a way to port that dialogue to the engine efficiently without having to go through a bunch of crap?

#

Also, how do I set up vr headset tilt as axis mappings for turn and lookup in engine input?

odd ember
#

string tables

#

for your dialogue

#

or just data tables in general

#

depending on your needs

ornate cairn
#

so I can't just import the file?

odd ember
#

what is "the file"

ornate cairn
#

I'm recreating DDLC in VR

#

it's a visual novel

#

so it's like tens of thousands of lines of dialogue

#

:/

#

but I have all of the dialogue already, so I'd prefer not to have to make it all all over again if possible and just read from a file

#

but I guess I can

#

:p

odd ember
#

what file

ornate cairn
#

the entire game

odd ember
#

you still didn't answer the question

ornate cairn
#

I have every file of dialogue

#

it's not just 1 file

#

it's like 30

odd ember
#

but what format

#

etc.

ornate cairn
#

oh it's written in a simple dialogue format. I'd be putting it all line-by-line in a text file.

odd ember
#

if it's an excel sheet

#

you can import those

#

if it's csv

#

you can import those

ornate cairn
#

wait seriously?

#

like how?

#

sorry- really new to dialogue trees

odd ember
#

there are no trees

#

this is purely for import to the game

#

if you want to make tree structures etc.

#

you'll have to do that yourself

ornate cairn
#

ok but does it import it as a table then?

#

like what does the table look like?

odd ember
#

yes

#

a bunch of text

#

look up the documentation

#

it's all there

#

data table import

ornate cairn
#

ok and do you know the answer to the vr question by chance?

#

I think it's just rotation rate and tilt, right?

#

in the motion menu>

#

it's really not specific on it in the docs

odd ember
#

I don't do VR

void quest
#

Hey I'm trying to make my character controller to lunch off slopes here, but because the Third person controller is not Physics based i have to manually writes this.

I don't want the controller to be physics based.

How would I solve this issue?

Im thinking I need to get the Forward velocity based on the slope, and then launch it in that direction when the slope declines from the previeous tick right?
even that im not sure of how to do

#

ive been stuck on this for days now

odd ember
#

a timer

#

but yes

#

your assumption is correct

#

if you're lucky then gravity is not necessarily physics based

void quest
#

the thing is im not sure how to go about it

#

how to blueprint it its a tiny bit over my head

odd ember
#

well if gravity works you do nothing

#

it just works

#

as long as gravity is enabled

ornate cairn
#

woah that's super neat!

#

all vr is automatically set up in the editor already!@

#

if you play in vr it automatically sets up tilt controls

trim matrix
#

@void quest bro that games looks adorable!

timber cloak
#

basically repeated from earlier but with a selection

trim matrix
#

@timber cloak lol you still on the professions thing? ๐Ÿ˜„

#

looks sooo messy, does it work tho?

timber cloak
#

it wasn't made just now. All was trying to get an inputs from more people

trim matrix
#

ah

odd ember
#

you could simplify a lot of htat down to a bunch of select nodes

#

not that I recommend it

#

I think there are better ways

trim matrix
#

coding is like a different way of thinking tbh

odd ember
#

no it is just thinking

#

lmao

trim matrix
#

well yeah everything is ''just thinking''

timber cloak
#

i am still thinking

#

geez, 2am now and still haven't get my dinner. All was focusing on this alone

#

brb

trim matrix
#

cant think straight on an empty stomach bro

#

eat, drink , take a walk etc

#

refresh your mind

maiden wadi
#

Programming at it's core is nothing more than the logical processing of numbers.

trim matrix
#

right, but youre almost like thinking backwards, you know the end result

#

you just need to get there

odd ember
trim matrix
#

lol fair enough

maiden wadi
#

That's not programming, that's problem solving. Which I'd argue is applicable to many things. For example, you know what you want to paint, but you still have to do the brush strokes in order to get the correct look.

trim matrix
#

isnt coding just problem solving? lol

odd ember
#

well, everything is problem solving

#

any employee working any job in the world is solving a problem

#

and tbh probably multiple problems at once

#

their own and other people's

trim matrix
#

i mean

#

suuure?

odd ember
#

without the gas station clerk the store would be unattended etc.

maiden wadi
#

Not really. Designers can be told that certain functions do certain things and to use them that way. If you make the inputs names and don't give them any control over the inputs much, they can place nodes or call functions just like a programmer. But then ask the same person to understand how that function actually runs internally based on those parameters? They might not have even a vague idea.

trim matrix
#

yea but like, i just started unreal maybe 2 weeks ago, and im making a simple cooking system with my limited knowledge

#

i know what i want

#

but doing it requires a lot of problem solving

odd ember
#

coding is like learning a language

vapid hatch
#

i have an array of materials but cant assign material instances to it, if i change it to material instances i cant use "normal" materials, whats a solution to that?

odd ember
#

there's grammar and there's vocabulary

trim matrix
#

i need different states, raw/cooked/burned. How do i get these states?

#

i made a cooking timer that ticks up to 3. 1 is raw 2 cooked etc etc

#

its a lot of small problems

#

or ideas

#

it really tickles your brain lol

#

i guess if you know more code it gets slightly easier but still

odd ember
#

it's like any language

#

once you're fluent you can say complex phrases and discuss the finer topics of life

#

but in the beginning you're stuck with "hi how are you"

#

or in the case of programming, "hello world"

#

which I'm sure is an ominous portent of the future

trim matrix
#

yea like you know a few words and you can just make rough sentences

#

me want food

#

me hungry

odd ember
#

pretty much

trim matrix
#

lol

maiden wadi
#

Pretty much what Cranz said. And getting to the point that you're using complex phrases pretty much revolves around the requirement that you realize that everything in coding is just the logical processing of numbers. You can pretty them up with Enums or Strings, or Name style tags, but it's all just numbers.

#

Realizing that will make it all a lot easier to understand.

trim matrix
#

i mean the core computer is just binary right?

odd ember
#

yes

#

but binary is more than just a number

#

it's also a logical switch

#

which is essentially what a transistor is

#

and a boolean variable

#

etc.

#

it's not just numbers but the perspective of "how can a number be represented"

#

enums are numbers, but to us they're strings

#

a boolean is a 0 or a 1

#

but it's still a number

trim matrix
#

yea

#

my first piece of code was just a bunch of booleans hahah

loud coral
odd ember
#

then you realize there's a switch

#

and state machines are great

vapid hatch
#

@loud coral thank you very much!

odd ember
#

then you get a look into data structures, class hierarchy and polymorphism

#

etc.

#

little by little the world opens up

#

and if I wanted to be a bit poetic

#

it's the same world you start by saying "hello" to in your first piece of code

trim matrix
#

i have no idea what you just said

loud coral
trim matrix
#

haha nice

odd ember
#

they are like advanced grammar

#

so your code stops being code and starts becoming more of a system, and then later, an architecture

trim matrix
#

im still trying to figure out how to properly cast to without going insane after 2 weeks lol

void quest
#

'

odd ember
#

casting is polymorphism

#

so if you understand polymorphism

#

you will understand casting

trim matrix
#

you turn shit into sheep?

maiden wadi
#

Casting is incredibly simple. Do you understand class inheritance?

odd ember
#

@trim matrix it's taxonomy of classes

#

Taxonomy (general) is the practice and science of classification of things or concepts, including the principles that underlie such classification. Originally used only about biological classification, taxonomy has developed to be synonym for classification (see Classification (general theory)).
Specific taxonomies include:

trim matrix
#

kinda understand how casting is supposed to work , just can never get it to work properly

#

mostly the object pin confuses me

odd ember
#

BP even simplifies it for you

#

since only down casting matters

maiden wadi
#

If you understand the character inheritance chain. Character>Pawn>Actor, then you understand that an object that is a character can be cast to Character, Pawn, or Actor. Where as an object that is a Pawn, cannot be cast to Character, but it can be cast to Pawn or Actor.

odd ember
#

think about how we share an evolutionary ancestor with monkeys somewhere down the line

#

but we are not monkeys

#

we share some traits though

maiden wadi
#

Unreal passes around a lot of pointers as Actors, because it's one of the lowest classes, and therefore nearly everything can be cast to it. This allows you to pass Characters, Pawns, GameModes, PlayerStates, Apples, Oranges, Guns, etc all around as Actors if they derive from the Actor class. And then cast them back to their real class where you need them to be.

trim matrix
#

ahh ๐Ÿ‘€

maiden wadi
#

@trim matrix Do you know how to use the Line Trace By Channel node?

odd ember
#

the above is also an example of polymorphism. polymorphism translates into "many forms"

#

which is how you can have an object be one thing at one time and something else at another

#

purely by casting it back and forth

#

or, up and down, really

trim matrix
#

@maiden wadi ive used it yes

#

oh ive used linetraceforobjects

maiden wadi
#

Imagine if you had to have a different line trace by channel node for every single actor type. LineTraceByChannelForActor, LineTraceByChannelForCharacter, LineTraceByChannelForPawn. That's going to add up fast when you have more than a few classes. Alternatively, Make one node that outputs everything as a hit actor, and allow casting to the type they want.

trim matrix
#

ah I see

#

that clears it up abit ๐Ÿ™‚

trim matrix
#

got dynamic material instance's to work finally

#

mah chicken is cooking bois

high frost
#

How can I set up collision on a static mesh component so that my character couldn't phase through it but the SM component would generate a sort of overlap event where I could get my character through casting?

odd ember
#

create a collision box or sphere that does that

trim matrix
#

does the custom collision setting not do that?

spark steppe
#

any suggestions how to work of a list of cpu intense tasks without taking up too much cpu time?

#

basically i want that other events can happen in between each job (otherwise my editor crashes and the final game probably, too)

odd ember
#

that's very vague

spark steppe
#

yea indeed, so rendering to rendertarget freezes actually my whole desktop

#

i have about 20 renderjobs to do, so im making a array now which i want to work of, but ideally there should be some delay between each job

odd ember
#

are you meeting the minimum requirements for using UE4?

spark steppe
#

probably, are they carved in stone?

odd ember
#

they should be on the documentation somewhere

#

and yes they are

spark steppe
#

but im pretty sure that i meet them

#

it's just that it takes a while to bake a 4k texture from a material with 20 layers...

maiden wadi
#

YO NED FIE MO GIGBITES

spark steppe
#

yea i need more vram indeed, 6gb ain't much when working with 4k textures ๐Ÿ˜ญ

odd ember
#

sounds like there is a lot of room for optimization

spark steppe
#

the baking is the optimization

#

๐Ÿ˜„

#

so i can go from 20 layer material to a simple with just 2-3 textures

odd ember
#

I mean if you're doing that runtime

#

you're freezing your game until it's done

spark steppe
#

yea or till it crashes (but not sure if the crashs may have been out of VRAM issues)

odd ember
#

so not really an optimization as much as a solution that doesnt work

spark steppe
#

meh, starting a job in the onTick event seems to work around the freezing

#

still i hate to use onTick just for that... might delegate it to an actor or smth

#

sidenote, its about 1.2GB that are generated and compressed for 20 jobs :>

#

i guess that would freeze any machine for a while moment ๐Ÿ˜‰

odd ember
#

yeah you shouldn't really be doing that in BP

spark steppe
#

where else?

trim matrix
#

you wanna bake textures?

#

in unreal?

spark steppe
#

i do now

odd ember
#

yeah that's silly

trim matrix
#

why not use a package thats made for rendering and baking textures?

#

like you know

#

blender

#

idk

spark steppe
#

because reasons, its not silly

#

if i could use prebaked ones i would use them obviously

trim matrix
#

i feel like youre way overcomplicating what youre trying to do

elfin inlet
#

could someone give me some insight on how GAS could be implemented for a realtime strategy game?

#

or thats not useful and i should structure things myself

#

(im planning on replication)

dense isle
narrow wyvern
#

Holy hell trying to work with different elements that are on different levels is such a PITA

#

Currently I'm trying to hide the text on the HUD showing the vehicle's speed but destroying the actor doesn't make the text in the blueprint disappear

pearl rose
#

@narrow wyvern You need to aim directly the Widget reference or the text and call a Set visibility. You could also remove the widget from blueprint, but I wouldn't recommend this if it need to be toggle often

brittle fiber
#

on developing tolls for learning and presentation.. issue on data table > control over spawned bp class with 3d widget component. each is different.. i spawn 10 copies of a bp class as is in data table.. failing to get 3d widget text to be controlled by data table and defined there, any1 willing to aid the servant of the race of men, screenshit dm only..

pearl rose
#

@elfin inlet If you go through the documentation you'll get everything you need to know regarding the GAS system. If you have an issue applying or understand something, then I'm sure some people will be able to help

narrow wyvern
elfin inlet
#

i've dug thru some GAS documentation, but i'm not sure how would it work with RTS gameplay

pearl rose
#

@brittle fiber It's hard to help you for that specific trouble without seeing the code. My guess is that you are not casting correctly to the 3d widget

narrow wyvern
#

The vehicle (and player) originally start out in this open world, and are then teleported to the garage area where the car is destroyed, but the HUD is remaining and I need to find a way to remove the HUD as well

pearl rose
#

My guess is that your In car Gear/Speed is not well set. Are you getting any error?

#

(Or exist multiple time, so when you set the visibility, you still have one bhind)

#

The only strange thing is that you are not aiming for a Widget reference. You are setting the visibility of a scene component, which is not the same as a UMG

#

@elfin inlet The same way it's working in any project? You need your question be more specific, what are you looking for exactly?

elfin inlet
#

unit combat, unit production, resource gathering etc.

brittle fiber
#

@pearl rose can i dm you?

elfin inlet
#

i'd like to try GAS because it handles network well and does a good job of handling odd cases

brittle fiber
#

clasified

narrow wyvern
#

@pearl rose Not getting any errors. I'm using the vehicle advanced template that comes with Unreal for this.

elfin inlet
#

but i think how it works with the tag stuff, doesnt synergy with how a RTS game works

pearl rose
#

It's good for ability and specifically for ability that need to be use on network. You probably don't need the GAS for what you are mentioning

#

@brittle fiber Yes

elfin inlet
#

doing everything with data assets and structs seems better to me

pearl rose
#

@narrow wyvern I do not use this template. First do you know where the widget get spawned?

#

@elfin inlet It mainly depend on the speed of your game I guess, unreal network is not perfect, the GAS help for very fast mechanic that need to be reliable over multiple client regarding what need to be display

elfin inlet
#

I see, there isn't time-critical gameplay for me

pearl rose
#

So you can go without GAS

elfin inlet
#

i just wanted to know if GAS would be worth implementing

pearl rose
#

From what you describe to me, no. After all, the best way to find out is to try ๐Ÿ™‚

elfin inlet
#

at this point i'm thinking it could potentially flood the network with all the units using gas

#

because apparently GAS does everything to keep clients in perfect sync

pearl rose
#

It's possible, you'll have to deal potentially with syncing yourself some content, but could be worth if you have multiple hundred of unit spawned

timber cloak
#

i realised this way is actually can get messy once more Occupation is being added up, especially Subclass Occupation. This one subclass took my whole 20inch monitor screen size in one go =.=

wise salmon
trim matrix
#

lol

wise salmon
#

how do i make collisions smooth as a skate park

#

when modeling

#

and implementing the models in unreal

#

sometime my shit flys through the models like "too fast sorry"

#

how do i make a model 100% solid

summer harness
#

do you have ccd enabled?

wise salmon
#

ccd=?

summer harness
#

continuos collision detection setting in physics for fast moving actors

wise salmon
#

okay, so i need to set this only for the pawn or the map

summer harness
#

the thing moving and your collidiong with, your skateboard

trim matrix
#

matze you know something about physics constraints? using it to pick shit up but its all wobly and flies everything lol

wise salmon
#

okay

trim matrix
#

think its damping but theres no damping on the physics constraint

summer harness
#

projection maybe?

#

or limits

wise salmon
trim matrix
#

these are my options

summer harness
#

thats a pretty intense mesh for collisions ^^

trim matrix
#

i can add more damping to the physics object i can grab BUT itll make them fall super slow lol

summer harness
#

you using complex as simple collision in the mesh?

trim matrix
#

trance?

wise salmon
#

no, i have passed that issue

#

the issue is as folllows

summer harness
#

@trim matrix try setting all limits to locked and projection disabled

wise salmon
#

there is a video of what happens

#

at about 2/3rds through the video the capsule passes through the ramp

summer harness
#

yeah try setting ccd on the capsule and if that doesnt help you can lower the physic sim steps, but would be careful with that

trim matrix
#

@summer harness kinda works but now it just fucking everything up lol

#

so glitchy pushing it into stuff

wise salmon
#

looking that up

summer harness
wise salmon
#

holy shit

#

that WORKED

trim matrix
#

haha

wise salmon
#

i HAD TO CLICK THE vv BUTTON TO EVEN SEE THE EFFING OPTION

#

JESUS

#

thank you guys

summer harness
#

so many hidden options ๐Ÿ™‚

wise salmon
#

BEHOLD. THE BOX

#

NICE

#

caps off

summer harness
#

thats a spring or soft constrain

#

click the magic v button and check if its enabled

wise salmon
#

they shouldnt hide the guts like that

trim matrix
#

should it be disabled?

summer harness
#

i think i saw a autoexpand option in the engine somewhere but could be wrong

#

yeah disabled it, but youll have to snap your object yourself

trim matrix
#

linear movement is xyz right?

summer harness
#

yes

trim matrix
#

cool

#

i set damping to 1000 and it works

#

probably abit overkill but whatever

summer harness
#

most of the time i do grabbing like that just with lerp to grab pos and attach to socket

trim matrix
#

ah feels so much better now ๐Ÿ˜„

#

What is map and what is it used to do?

#

thanks matze!

summer harness
#

@trim matrix you can for example store meshes by a name in a map with string as key and mesh as value, easy to search and check

#

see it like an array with a custom index

trim matrix
#

When should you implement it?

summer harness
#

for example in a parser when you litarlly want to map values from one thing to another

trim matrix
#

Ohh so if I want to store some objects variable in a UI should I use maps then?

#

Like for example if you click on this button you will get this actor and if you press on the other button you will get another type of actor

summer harness
#

i map an enum to a mesh and search for that in the map

trim matrix
#

Can it only store a mesh as a variable or was that just an example

#

how do you make the pretty straight lines?

summer harness
#

@trim matrix just an example

trim matrix
#

Damn those lines look nice

#

@summer harness Can you choose yourself if the node itself is going to be default or not?

summer harness
#
Gumroad

An alternative flatter appearance of Unreal Engine 4 Blueprint nodes in a minimalist style. Improves the readability of nodes.Suitable for the latest version of the engine.To install, you need to unpack it into the folder with the engine with the replacement of files.This design pack does not affect the stability or performance of the engine in ...

trim matrix
#

Ohhh so you it is two different

odd ember
#

the drawback is that you kind of have to do a lot of selects and they will boolean options

trim matrix
#

@summer harness Is the electric nodes plug-in just for the lines?

summer harness
#

yes

trim matrix
#

@summer harness Are they all free?

summer harness
#

no, but totally worth it

trim matrix
#

my chickens sizzling bois

#

will definitely get the node graph assistant and electric nodes

#

@summer harness why isnt that in unreal yet for free?

#

thats looks SO GOOD

timber cloak
safe narwhal
#

What action is this one? cant find it

#

oh.. nvm

#

im stupid

#

it was my byte variable

#

._.

raven pilot
#

haha i was just trying to look for it.
At first i was going to tell you that am new to BP so i wouldnt know but i thought maybe i could still find it @safe narwhal

safe narwhal
#

Oh is k

#

im dumb and didnt realised what it was

#

at least i could figure it out on my own lol

raven pilot
#

haha yea, +500 XP

odd ember
elfin inlet
#

Is it even possible to reference blueprint classes in data tables?

#

i'm trying to add a "class to spawn" in my data table but it's not editable (atleast from the editor)

earnest tangle
#

iirc it should be - what type did you make the column?

#

as in, did you make it an object reference, or a class reference

elfin inlet
#

@earnest tangle might help

earnest tangle
#

based on the color it looks like Building Master is an object reference

elfin inlet
#

yes

#

parent class for buildings

earnest tangle
#

right, so if you want to refer to a BP class, make it a class reference. Then you should be able to set it in the data table

elfin inlet
#

jesus

#

its working now

earnest tangle
#

Object refs are references to specific objects, such as ones that are spawned in your level, so using that doesn't make a whole lot of sense in DT's :)

elfin inlet
#

i tried that and i guess it was frozen, because it was still saying its unsettable

earnest tangle
#

Ah

elfin inlet
#

thank you!!

earnest tangle
timber cloak
#

This was shown earlier

#

can't we have like a list of enum with values attached (instance editable) on it, then make arrays for each randomly given job straight forward?

#

or that is only possible with C++ ?

static charm
#

yeah you can a make a map of enums

#

and do what you want in blueprint

timber cloak
#

Thank you

languid lichen
#

can you replicate map in BP yet?

odd ember
static charm
#

as of 4.25, no replication directly for map. but im sure there's work arounds

timber cloak
#

it is indeed terrible, that screenshot is only One Subclass. And it is already taking whole 20" inch monitor screen.

Imagine having 10 more of that.

earnest tangle
#

wasn't there a quote from Tim Sweeney where he said something like "I meant to do TMap replication for Unreal 1" strikLUL

static charm
#

i might i get that struct might not be as efficient but that can replicate

trim matrix
#

i mean if it works its a achievement

#

cleaning it up comes later right

languid lichen
static charm
#

dont be sharing my code

languid lichen
#

sorry, i fell down and some UE4 blueprints fell out of my pocket

trim matrix
#

broooo

#

what the fuck is tha

static charm
#

blueprintsfromhell

trim matrix
#

literally

#

spaghetti code

static charm
#

honestly some of them are pretty impressive

#

Advent of Code is coming up in a few days. I made some crazy spagetti trying to solve those puzzles last year ๐Ÿ˜ฉ

languid lichen
#

hey but it works!

#

lol

steady apex
#

What's the proper way to put child components in a custom SceneComponent?

#

e.g. have a component I can place on my model that has some functionality and a mesh attached to it

trim matrix
#

how do i send a boolean to a traced obj?

#

๐Ÿค”

#

i guess cast and get boolean?

steady apex
#

Depends on where you're casting from and to what

#

Best way is to use an event on an Interface. It avoids a cast and you don't even have to check if it's implemented

trim matrix
#

yea but i only want the boolean to affect the thing im pointing/casting at

steady apex
#

Line Trace will yield the actor it hits

#

Then send the boolean using an interface ๐Ÿ™‚

trim matrix
#

ah yea

#

scary interfaces

steady apex
#

You should avoid casting in cases like these usually, since it creates an asset connection between unrelated classes

trim matrix
#

I see

#

this okay?

steady apex
#

Sure

#

Simple functions in interfaces without return nodes are events

#

functions like these are normal functions ๐Ÿ™‚

trim matrix
#

this doesnt work

#

cause of the input I guess

#

pretty sure im being a big dumdum now

steady apex
#

I'm not sure what you're trying to accomplish

#

You probably want to pass something other than self to the call target though ๐Ÿ™‚

trim matrix
#

so i got a line trace

#

to object

#

and when I press Q

#

i wanna send a signal to that object

#

for something to happen

steady apex
#

Then you need to pass that object to the signal call

trim matrix
#

i already got something set up, cause I can pick up objects

#

but its on my player

#

and this

#

wich works

#

but i cant do the whole bolean stuff

#

cant i use the hit actor somehow?

steady apex
#

Yes. Call the interface method on the hit actor

trim matrix
#

sorry im quite new

steady apex
#

And implement the interface on whatever you're trying to hit

#

Just find a tutorial on how to use interfaces or look at the docs, it's not very complicated ๐Ÿ™‚

trim matrix
#

i know but its confusing abit

#

like this?

steady apex
#

Yes

#

Provided that's the event you're trying to call ๐Ÿ™‚

trim matrix
#

idk.. lol

#

just wanna send a boolean lol

steady apex
#

It doesn't matter what you're trying to send

#

The mechanism is the same ๐Ÿ™‚

#

You get a reference to another actor from the line trace and you can operate on it

#

Interfaces let you establish a common "language" between classes

trim matrix
#

yea but my parameters dont work lol

steady apex
#

Not sure which parameters you're talking about

languid lichen
#

isnt there another thing you have to do since he wants to return the bool with that interface event

steady apex
#

There's a ton of tutorials for exactly this on youtube by the way ๐Ÿ™‚ It's fairly straightforward.

languid lichen
#

like another node to handle that

steady apex
#

Then it's a just an interface call of a function instead of an event

trim matrix
#

when I press Q on an object, send a signal to that object

trim matrix
#

i got the object by line trace

#

just need to send it

languid lichen
#

is the problem the interface event never happens at all or that it happens but doesnt return your bool correctly?

trim matrix
#

just not sure how to set it up thats al

languid lichen
#

do you even have the interface event in your object, you havent shown it in a picture

#

you showed a function

steady apex
#

You need to implement the interface on whatever actor you're trying to hit

#

Just look up the docs on blueprint-to-blueprint communication and/or interfaces

#

That's what they're written for ๐Ÿ™‚

languid lichen
#

ya and on top of that once its implemented there will be a new event in your menu, thats the node you need in your graph to call your eat function

#

iirc if you are returning something with the interface, like your bool, theres an extra node to handle that part too i think

trim matrix
#

ah you so you cant just get the function? you need the event

languid lichen
#

ya it should show up once you implement the interface in the actor

#

the caller should be using the function

trim matrix
#

got it to work

#

somehow

#

heh

#

thanks both of you! youre the best ๐Ÿ˜„

#

@steady apex @languid lichen

#

just pretend theyr bones ๐Ÿ‘

steady apex
#

Yay!

trim matrix
#

all that headache just to replace an actor haha

trim matrix
#

bruh you cant put delays in functions?

steady apex
#

Nope

#

Either use a timer or make it an event ๐Ÿ™‚

rough jay
#

how can i add two actor bps in one array

#

like get all actors of 1 get all actors of 2 put them in a array

lime lichen
#

What would be the best way to setup different hairstyles for the player to chose? Can anyone point me towards the right tutorial/doc to learn that?

wanton coyote
#

trying to wrap my head around adding impulse to an object when it leaves a sphere. but I don't want it to ever have the impulse added more then the speed of the sphere its leaving + specified additional speed.... sounds like a logical statement.

Reality I get is A - It will always break the speed i want it gated at and B its calling the exit sometimes as soon as it enters the moving sphere anyone ever run into similar issues?

#

wait i got an idea..

stray island
#

When i add a camera to an actor, it Doesnโ€™t get added to its child actors

Is there a way to do so?

maiden wadi
#

@stray island Not sure what you mean? A child actor is a very vague term in unreal because it can mean a lot of things. It doesn't get added to classes that inherit from the class you added the camera to?

stray island
#

Um like i have a main enemy character , and i created a child actors of it , when i add a camera to the main it doesnt get added to childs

#

I have to add a camra to each child individually

maiden wadi
#

That's odd. That's not normal behavior. You compiled the parent class?

twilit heath
#

hates the term Child used for inheritance lol

stray island
#

Yes , everything gets added to childs besides camera

maiden wadi
#

@stray island Pure blueprint, no C++?

twilit heath
#

there is Editable when Inherited checkbox on components

#

you sure your Camera has that on?

stray island
#

Oh never mind i think I figured out that its not the main character i got the childs from

#

Thanks

maiden wadi
#

Haha. Asking if the child's parent in the top right of their blueprint was the parent class was my next question.

trim matrix
#

So I have setup a dialog system that works by a dialog system that triggers events in the ui Blueprint. But how can I make it so I get typewriter text. (Text is typed out letter by letter) Here is the setup:

trim matrix
#

Hey. I have disable input and after that I would make it enable input after a while. How can I have the character have input held down during the phase of disable input and automatically register on enable input? Now I have to press the button again when enable input happens.

#

sorry fixed it was not the input enablers fault

marsh lintel
#

Hi everyone! I'm trying to use SetTimerbyFunctionName on the Construct Script but seems like it doesn't even run. Function name and everything is correct but it's not working ๐Ÿ˜ฆ Any idea? Thanks!

trim matrix
#

@marsh lintel Itยดs much better to use set timer by event instead as it is easy to forget the name of some functions later

marsh lintel
#

@trim matrix My idea was to use evets at the start, but from the construct script it seems like it's not possible to create events :/

tight schooner
#

@marsh lintel use beginplay

#

Construction script is more of a level editing thing. I never tried setting a timer there but I'm not surprised it doesn't work

#

In a packaged game, all construction scripts for actors placed in a level are run in advance so those scripts don't even run at runtime

#

e.g.

marsh lintel
#

I wanted to blink some lights and would be "fun" if we can already see the result from the editor instead on the game itself. But from all I've been doing and from what you just said, from BeginPlay would be the best choice.

#

Thanks! ๐Ÿ˜

trim matrix
#

How can I make it so a behavior tree "remembers" if it already did something?

maiden wadi
#

Same way that a brain does. Make a decorator for it and a bool to set. DidDoThisAlready? False or True?

trim matrix
#

@maiden wadi thanks

spark steppe
#

and make the bool randomly flip if you want real brain behavior ๐Ÿ˜‰

maiden wadi
#

Haha. No kidding.

#

At the moment, my brain is frying trying to work around this solar system orbit lane particle. I'm almost there though. Attempting to draw a simple solar orbit with nothing more than the gravity location, and the Periapsis and Apoapsis. Thankfully I'm doing this all in local space.

charred mango
#

Hi do you know why in python, when i do a for loop to 4, it do the loop from 0 to 3 in the correct order

spark steppe
#

new lines are printed above old lines if im not wrong

maiden wadi
#

^

spark steppe
#

so first it prints 0, then it moves it down to print 1 and so on

charred mango
#

ok, that's why.

maiden wadi
#

Newest line will always be on top.

charred mango
#

And the index goes to 4 is that normal ? different convention ?

spark steppe
#

its inclusive

charred mango
#

ok

maiden wadi
#

It's to last index, not to length of loop.

spark steppe
#

you get one bonus iteration for free in unreal ๐Ÿ˜›

maiden wadi
#

Haha

charred mango
#

another question, do you know how to see what is inside a variable (for example a 2D array of int) ?

#

i could print each value

#

but is there a way to see it in a table or something more visual ?

#

maby save it it in json format ?

maiden wadi
#

I think the blueprint debugger can do that? I haven't used it much.

#

I keep most of it sorted logically in my head and print them for a visual picture.

#

Try right clicking and putting a breakpoint on the SetArrElemINT and right click the array and WatchThisVariable.

charred mango
maiden wadi
#

Sec. Let me see.

charred mango
maiden wadi
#

Let me check structs too.

#

Still works here with IntVectors.

charred mango
#

did you enable something to see it in the blueprint editor ? (other than the breackpoint and the see variable ?)

maiden wadi
#

Nah. Just those two. Breakpoint on the print, and right click the 9square array icon pin and WatchThisValue

#

I'm out for a bit, but someone else might know better if you can't get it working.

charred mango
#

ok, thanks

#

i'm trying to understand how the debugging in blueprint work

summer harness
#

thats a breakpoint like in visual studio, you are stepping through the code one by one, disabled debugging and it should run normal

stuck palm
#

Hello, I'm trying to detect where a hitr has happened on my character, but when I draw a debug sphere it looks like its in the wrong place, very wrong... any ideas?

charred mango
#

oh, that is break point, ok, thanks ๐Ÿ™‚

charred mango
#

I didn't know the existance of breakpoint, ok, thanks, the debug now work fine without breakpoint ( i just don't fully understand the data struct of the var but that's another issue $$ )

summer harness
# stuck palm

try printing the object name with get display name and check with what exaclty you are overlapping

#

if you only want to overlap your player character, cast other actor to that

strange pike
#

dumb thought, is it possible to clear a string append?

summer harness
vapid hatch
#

i have an animated skeletal mesh and want to get another one that copies the exact movements, how would i go about doing that?

paper rampart
#

I am getting
LogScript: Warning: Script Msg: No world was found for object (/Game/Unlighted/DecalSystem/BP_MeshDecalActor.BP_MeshDecalActor_C:TEST_ComponentWithRef_GEN_VARIABLE) passed in to UEngine::GetWorldFromContextObject().
When i'm trying to get ChildrenComponents of SceneComponent based BlueprintClass from CallIneditor function on child component in blueprint editor. So there is no world context in blueprint editor on CallInEditor function ?

summer harness
#

I think there is get editor world in editor blueprints

paper rampart
#

GetOwner also returns null actor reference when calling CallInEditor function from child component details in Actor Blueprint Editor

summer harness
paper rampart
#

Yeah, I know. There is just a specific case where I need to copy vertices from spline component to another component in blueprint editor. So I need to get reference to child spline component somehow

trim matrix
#

Hey does someone mind helping me optimize a bit of code just so I can see how smart people do it? ๐Ÿ˜„

maiden wadi
#

Depends on what it is.

trim matrix
#

its more like id like to know how YOU would of done it, so i can learn from it

#

it already works its just iffy haha

maiden wadi
#

What is it though?

trim matrix
#

when it overlaps it begins a ''timer'' its a freaking delay

#

that increases the cookingtimer float

#

and im using that to control how cooked it is

#

its pretty flawed tbh

#

and then here i have it set up the different states based on the float

#

like it works.. somehow

#

but I feel like this is a terrible way to do it

maiden wadi
#

You can ditch tick entirely by just calling a SetTimerByEvent where you're setting the boolean IsOverlapping. The boolean list of Raw, Cooked, Burned can be condensed into one Enum. The smoke component thing can be activated at the same time you set the enum for burned.

trim matrix
#

Not sure what enums are