Download

Night and Day

Well,
to start things off, I’m new at this.
I’m currently working on an item that has different functionality at different stages of the day. Unfortunately I have no idea where to find this information.
I’ve tried looking through the different folders for anything and have only come up with the transition sound files (ie night to morning, morning to noon, noon to night).

Any help or ideas are greatly appreciated.

-WM

Awesomesauce.
So if I’m reading this graph correctly, K2 Get World contains world related info and returns that in the form of a world reference. ‘Get Day Cycle Manager’ and ‘Is Daytime’ look to both be user defined functions with ‘Is Daytime’ taking the input of the ‘DayCycleManager’. And ‘Current Time’ appears to be a user defined variable.

So now for my confusing bits:

  1. Where is this graph located? ( I would assume it would be located in my new object that I am trying to create)
  2. Is ‘DayCycleManager’ a new blueprint or is it a preexisting one?
  3. ‘Current Time’ appears to be a variable of type float (unless it’s secretly a different data type), but I have yet to see how to give it the ‘target’ value.
  4. How did you manage to get ‘Get Day Cycle Manager’ to take a ‘world reference’? When checking inputs I did not have that option.

I’m trying to get a better understanding of how this works and how everything is interconnected. This whole graph system is different than what I’m used to seeing.

Any and all help/insight is greatly appreciated!

Copy and paste the following into your event graph.


Begin Object Class=K2Node_CallFunction Name="K2Node_CallFunction_13494"
   Begin Object Class=EdGraphPin Name="EdGraphPin_30473"
   End Object
   Begin Object Class=EdGraphPin Name="EdGraphPin_30474"
   End Object
   Begin Object Class=EdGraphPin Name="EdGraphPin_30475"
   End Object
   Begin Object Class=EdGraphPin Name="EdGraphPin_30476"
   End Object
   Begin Object Class=EdGraphPin Name="EdGraphPin_30477"
   End Object
   Begin Object Name="EdGraphPin_30473"
      PinName="execute"
      PinType=(PinCategory="exec")
   End Object
   Begin Object Name="EdGraphPin_30474"
      PinName="then"
      Direction=EGPD_Output
      PinType=(PinCategory="exec")
      LinkedTo(0)=EdGraphPin'"K2Node_CallFunction_18316.EdGraphPin_30482"'
   End Object
   Begin Object Name="EdGraphPin_30475"
      PinName="self"
      PinFriendlyName="Target"
      PinToolTip="Target
Primal Globals Reference"
      PinType=(PinCategory="object",PinSubCategoryObject=Class'/Script/ShooterGame.PrimalGlobals')
      DefaultObject=Default__PrimalGlobals
      bHidden=True
   End Object
   Begin Object Name="EdGraphPin_30476"
      PinName="World"
      PinToolTip="World
World Reference"
      PinType=(PinCategory="object",PinSubCategoryObject=Class'/Script/Engine.World')
      LinkedTo(0)=EdGraphPin'"K2Node_CallFunction_17488.EdGraphPin_30479"'
   End Object
   Begin Object Name="EdGraphPin_30477"
      PinName="ReturnValue"
      PinToolTip="Return Value
Day Cycle Manager Reference"
      Direction=EGPD_Output
      PinType=(PinCategory="object",PinSubCategoryObject=Class'/Script/ShooterGame.DayCycleManager')
      LinkedTo(0)=EdGraphPin'"K2Node_VariableGet_1906.EdGraphPin_30481"'
      LinkedTo(1)=EdGraphPin'"K2Node_CallFunction_18316.EdGraphPin_30484"'
   End Object
   FunctionReference=(MemberParentClass=Class'/Script/ShooterGame.PrimalGlobals',MemberName="GetDayCycleManager")
   Pins(0)=EdGraphPin'EdGraphPin_30473'
   Pins(1)=EdGraphPin'EdGraphPin_30474'
   Pins(2)=EdGraphPin'EdGraphPin_30475'
   Pins(3)=EdGraphPin'EdGraphPin_30476'
   Pins(4)=EdGraphPin'EdGraphPin_30477'
   NodePosX=-272
   NodePosY=-400
   NodeGuid=1D3CD341420BFF04E0F8F6BC07159F68
End Object
Begin Object Class=K2Node_CallFunction Name="K2Node_CallFunction_17488"
   Begin Object Class=EdGraphPin Name="EdGraphPin_30478"
   End Object
   Begin Object Class=EdGraphPin Name="EdGraphPin_30479"
   End Object
   Begin Object Name="EdGraphPin_30478"
      PinName="self"
      PinFriendlyName="Target"
      PinToolTip="Target
Actor Reference"
      PinType=(PinCategory="object",PinSubCategoryObject=Class'/Script/Engine.Actor')
   End Object
   Begin Object Name="EdGraphPin_30479"
      PinName="ReturnValue"
      PinToolTip="Return Value
World Reference"
      Direction=EGPD_Output
      PinType=(PinCategory="object",PinSubCategoryObject=Class'/Script/Engine.World')
      LinkedTo(0)=EdGraphPin'"K2Node_CallFunction_13494.EdGraphPin_30476"'
   End Object
   bIsPureFunc=True
   bIsConstFunc=True
   FunctionReference=(MemberName="K2_GetWorld",bSelfContext=True)
   Pins(0)=EdGraphPin'EdGraphPin_30478'
   Pins(1)=EdGraphPin'EdGraphPin_30479'
   NodePosX=-512
   NodePosY=-256
   NodeGuid=143C4B13415C012A1421218E96B2C08C
End Object
Begin Object Class=K2Node_VariableGet Name="K2Node_VariableGet_1906"
   Begin Object Class=EdGraphPin Name="EdGraphPin_30480"
   End Object
   Begin Object Class=EdGraphPin Name="EdGraphPin_30481"
   End Object
   Begin Object Name="EdGraphPin_30480"
      PinName="CurrentTime"
      Direction=EGPD_Output
      PinType=(PinCategory="float")
      DefaultValue="0.0"
      AutogeneratedDefaultValue="0.0"
   End Object
   Begin Object Name="EdGraphPin_30481"
      PinName="self"
      PinFriendlyName="Target"
      PinType=(PinCategory="object",PinSubCategoryObject=Class'/Script/ShooterGame.DayCycleManager')
      LinkedTo(0)=EdGraphPin'"K2Node_CallFunction_13494.EdGraphPin_30477"'
   End Object
   VariableReference=(MemberParentClass=Class'/Script/ShooterGame.DayCycleManager',MemberName="CurrentTime")
   SelfContextInfo=NotSelfContext
   Pins(0)=EdGraphPin'EdGraphPin_30480'
   Pins(1)=EdGraphPin'EdGraphPin_30481'
   NodePosX=-48
   NodePosY=-208
   NodeGuid=3440901B4E308525E0CE0EAF525A00F0
End Object
Begin Object Class=K2Node_CallFunction Name="K2Node_CallFunction_18316"
   Begin Object Class=EdGraphPin Name="EdGraphPin_30482"
   End Object
   Begin Object Class=EdGraphPin Name="EdGraphPin_30483"
   End Object
   Begin Object Class=EdGraphPin Name="EdGraphPin_30484"
   End Object
   Begin Object Class=EdGraphPin Name="EdGraphPin_30485"
   End Object
   Begin Object Name="EdGraphPin_30482"
      PinName="execute"
      PinType=(PinCategory="exec")
      LinkedTo(0)=EdGraphPin'"K2Node_CallFunction_13494.EdGraphPin_30474"'
   End Object
   Begin Object Name="EdGraphPin_30483"
      PinName="then"
      Direction=EGPD_Output
      PinType=(PinCategory="exec")
   End Object
   Begin Object Name="EdGraphPin_30484"
      PinName="self"
      PinFriendlyName="Target"
      PinToolTip="Target
Day Cycle Manager Reference"
      PinType=(PinCategory="object",PinSubCategoryObject=Class'/Script/ShooterGame.DayCycleManager')
      LinkedTo(0)=EdGraphPin'"K2Node_CallFunction_13494.EdGraphPin_30477"'
   End Object
   Begin Object Name="EdGraphPin_30485"
      PinName="ReturnValue"
      PinToolTip="Return Value
Boolean"
      Direction=EGPD_Output
      PinType=(PinCategory="bool")
      DefaultValue="false"
      AutogeneratedDefaultValue="false"
   End Object
   FunctionReference=(MemberParentClass=Class'/Script/ShooterGame.DayCycleManager',MemberName="IsDaytime")
   Pins(0)=EdGraphPin'EdGraphPin_30482'
   Pins(1)=EdGraphPin'EdGraphPin_30483'
   Pins(2)=EdGraphPin'EdGraphPin_30484'
   Pins(3)=EdGraphPin'EdGraphPin_30485'
   NodePosX=-32
   NodePosY=-416
   NodeGuid=38ADD7A34BEE893C6826C3882E928BEF
End Object

See above.

It’s a function/node…?

Not following. You cannot set that variable, if you’re referring to that. If you mean how to turn that float into the readable time, then you would need to ‘print string’ the variable during a test and see what it spits out, then work from there.

I don’t understand this question either, that node can *only *take a world reference.

-WM

Well, I’m apparently much more confused than I thought. XD

I mostly was just confused as to what exactly ‘Day Cycle Manager’ was. If it’s just a defined function/node that makes things easier.

This one my confusion stemmed from the added ‘target’ node on the left. None of the variables I’ve tried creating have that node.

Well, if it’s a built in that only takes a world reference, that makes perfect sense. I, however, was not finding it (probably just looking in the wrong place) and in an attempt to create the function myself, could not find ‘world reference’ in the list of available options.

This I will try when I have a moment. Although I’m not sure when, since I have my reservations of trying to run the devkit through a remote desktop on a 1024x768 monitor…
But, I’m sure it will most likely answer all of my previously confusing questions.

Sorry about the confusion. I thought I was being clear. XD
At any rate, the help and insight is and has been most appreciative.

Also, I’m not able to paste anything directly into the EventGraph. That or I’m clearly doing something wrong…

Because I’m reading that variable from the node it’s attached to.

The Day Cycle Manager is only available by deselecting “Context Sensitive” when right clicking in graphs. Context sensitive hides everything that is not pertinent to the current graph you’re working in, conversely while it is disabled, you cannot access anything that is directly related to the current BP - variables, events, functions even nodes.

Just select it all, right click and at the bottom “Paste here” if CTRL-V doesn’t work for some reason. You must be sure to get from the ‘B’ at the top, all the way to the ‘T’ at the end.

-WM

I’m assuming that lastly I just connect the return value of ‘Isdaytime’ to whatever I want to do with this test. Be it a variable, or some other function. Correct?

I couldn’t say, it’s up to you what you do with the information I’ve provided.

-WM

Well, good sir,
You’re a gentleman and a scholar.

Thank you very much for the insight. It’s definitely given me quite a bit of understanding now that I’ve got something to work with.
Hopefully I’m not mistaken in your perceived identity, otherwise this is really awkward…

As of the new DK version, this is also a possibility.

Not tested, but possibly worth exploring for any interested.

-WM