edited August 11 in ORK Support
Unfortunately got trouble again with converting to the way ORK 3 handles player object. I don't actually spawn the prefabs through ORK, since I have custom system.

In ORK 2, I just had to attach 'Add Combatant' script to any object I planned to use as that combatant object, select there e.g. Player and it would always reference it in all events under Actor - Player.

ORK 3 can't find the object under 'Player', I have to use direct object reference. For everything, including formulas. This basically means that I can't use that reference and in case of situation where I don't have that object in the scene, I guess I can't use formulas or any reference to 'Player'.

At the start of the game, I just user 'Join Group' node for first combatant and the 'Leave Battle Group' since I won't use this combatant in battles. Just as I did in ORK 2.

I can store him in Selected Data, but as far as I know, that gets wiped upon reload.

I thought that first combatant is always a 'Player' reference, as it was before. How is it now? And how do you deal with game reloads that wipe the character and you need stored e.g. Player stats in a menu outside of that scene?

Also, when I want to view the 'Add Combatant' script during a runtime in Unity to see, whether player got the stats I gave him, 2020.3.37 with Maki 2.6.1 version, it crashes Unity.
Post edited by Machal on
  • edited August 12
    Ok, so after hours of try hard, I was able to find the actor 'ORK Player' which is exactly what I was looking for...

    Anyway, I do keep having issues whenever I swtich my 'Change Status Value' node to be added by a formula value. Doesn't matter if it's simple value or anything else, this errors always pops. There is no negative number and max value is 70, while I add simple 10.

    ArgumentOutOfRangeException: Index was out of range. Must be non-negative and less than the size of the collection.
    Parameter name: index
    System.ThrowHelper.ThrowArgumentOutOfRangeException (System.ExceptionArgument argument, System.ExceptionResource resource) (at <695d1cc93cca45069c528c15c9fdd749>:0)
    System.ThrowHelper.ThrowArgumentOutOfRangeException () (at <695d1cc93cca45069c528c15c9fdd749>:0)
    GamingIsLove.Makinom.Schematics.SchematicObjectSelection.ActorToObject (GamingIsLove.Makinom.Schematics.SchematicRuntimeActor actor, GamingIsLove.Makinom.Schematics.Schematic schematic) (at <130ada825d394dd8ab9c8756a223ccce>:0)
    GamingIsLove.Makinom.Schematics.SchematicObjectSelection.GetFormulaObject (GamingIsLove.Makinom.Schematics.Schematic schematic) (at <130ada825d394dd8ab9c8756a223ccce>:0)
    GamingIsLove.Makinom.Schematics.SchematicObjectSelection.GetFormulaObject (GamingIsLove.Makinom.IDataCall call) (at <130ada825d394dd8ab9c8756a223ccce>:0)
    GamingIsLove.Makinom.FloatValue_FormulaType`1[T].GetValue (GamingIsLove.Makinom.IDataCall call) (at <130ada825d394dd8ab9c8756a223ccce>:0)
    GamingIsLove.Makinom.FloatValue`1[T].GetValue (GamingIsLove.Makinom.IDataCall call) (at <130ada825d394dd8ab9c8756a223ccce>:0)
    GamingIsLove.ORKFramework.Schematics.Nodes.ChangeStatusValueNode.Change (GamingIsLove.ORKFramework.Combatant c, GamingIsLove.Makinom.Schematics.Schematic schematic) (at :0)
    GamingIsLove.ORKFramework.Schematics.Nodes.ChangeStatusValueNode.Execute (GamingIsLove.Makinom.Schematics.Schematic schematic) (at :0)
    GamingIsLove.Makinom.Schematics.Schematic.ExecuteNextNode () (at <130ada825d394dd8ab9c8756a223ccce>:0)
    GamingIsLove.Makinom.Schematics.Schematic.NodeFinished (System.Int32 next) (at <130ada825d394dd8ab9c8756a223ccce>:0)
    GamingIsLove.Makinom.Schematics.Nodes.ChanceNode.Execute (GamingIsLove.Makinom.Schematics.Schematic schematic) (at <130ada825d394dd8ab9c8756a223ccce>:0)
    GamingIsLove.Makinom.Schematics.Schematic.ExecuteNextNode () (at <130ada825d394dd8ab9c8756a223ccce>:0)
    GamingIsLove.Makinom.Schematics.Schematic.NodeFinished (System.Int32 next) (at <130ada825d394dd8ab9c8756a223ccce>:0)
    GamingIsLove.Makinom.Schematics.Nodes.FindActorObjectsNode.Execute (GamingIsLove.Makinom.Schematics.Schematic schematic) (at <130ada825d394dd8ab9c8756a223ccce>:0)
    GamingIsLove.Makinom.Schematics.Schematic.ExecuteNextNode () (at <130ada825d394dd8ab9c8756a223ccce>:0)
    GamingIsLove.Makinom.Schematics.Schematic.NodeFinished (System.Int32 next) (at <130ada825d394dd8ab9c8756a223ccce>:0)
    GamingIsLove.ORKFramework.Schematics.Nodes.StoreStatusValueNode.Execute (GamingIsLove.Makinom.Schematics.Schematic schematic) (at :0)
    GamingIsLove.Makinom.Schematics.Schematic.ExecuteNextNode () (at <130ada825d394dd8ab9c8756a223ccce>:0)
    GamingIsLove.Makinom.Schematics.Schematic.NodeFinished (System.Int32 next) (at <130ada825d394dd8ab9c8756a223ccce>:0)
    GamingIsLove.ORKFramework.Schematics.Nodes.CheckStatusNode.Execute (GamingIsLove.Makinom.Schematics.Schematic schematic) (at :0)
    GamingIsLove.Makinom.Schematics.Schematic.ExecuteNextNode () (at <130ada825d394dd8ab9c8756a223ccce>:0)
    GamingIsLove.Makinom.Schematics.Schematic.NodeFinished (System.Int32 next) (at <130ada825d394dd8ab9c8756a223ccce>:0)
    GamingIsLove.ORKFramework.Schematics.Nodes.StoreStatusValueNode.Execute (GamingIsLove.Makinom.Schematics.Schematic schematic) (at :0)
    GamingIsLove.Makinom.Schematics.Schematic.ExecuteNextNode () (at <130ada825d394dd8ab9c8756a223ccce>:0)
    GamingIsLove.Makinom.Schematics.Schematic.NodeFinished (System.Int32 next) (at <130ada825d394dd8ab9c8756a223ccce>:0)
    GamingIsLove.ORKFramework.Schematics.Nodes.ChangeStatusValueNode.Execute (GamingIsLove.Makinom.Schematics.Schematic schematic) (at :0)
    GamingIsLove.Makinom.Schematics.Schematic.ExecuteNextNode () (at <130ada825d394dd8ab9c8756a223ccce>:0)
    GamingIsLove.Makinom.Schematics.Schematic.NodeFinished (System.Int32 next) (at <130ada825d394dd8ab9c8756a223ccce>:0)
    GamingIsLove.Makinom.Schematics.Nodes.SpawnPrefabNode+Runtime..ctor (GamingIsLove.Makinom.Schematics.Nodes.SpawnPrefabNode settings, GamingIsLove.Makinom.Schematics.Schematic schematic) (at <130ada825d394dd8ab9c8756a223ccce>:0)
    GamingIsLove.Makinom.Schematics.Nodes.SpawnPrefabNode.Execute (GamingIsLove.Makinom.Schematics.Schematic schematic) (at <130ada825d394dd8ab9c8756a223ccce>:0)
    GamingIsLove.Makinom.Schematics.Schematic.ExecuteNextNode () (at <130ada825d394dd8ab9c8756a223ccce>:0)
    GamingIsLove.Makinom.Schematics.Schematic.NodeFinished (System.Int32 next) (at <130ada825d394dd8ab9c8756a223ccce>:0)
    GamingIsLove.Makinom.Schematics.Nodes.SpawnPrefabNode+Runtime..ctor (GamingIsLove.Makinom.Schematics.Nodes.SpawnPrefabNode settings, GamingIsLove.Makinom.Schematics.Schematic schematic) (at <130ada825d394dd8ab9c8756a223ccce>:0)
    GamingIsLove.Makinom.Schematics.Nodes.SpawnPrefabNode.Execute (GamingIsLove.Makinom.Schematics.Schematic schematic) (at <130ada825d394dd8ab9c8756a223ccce>:0)
    GamingIsLove.Makinom.Schematics.Schematic.ExecuteNextNode () (at <130ada825d394dd8ab9c8756a223ccce>:0)
    GamingIsLove.Makinom.Schematics.Schematic.NodeFinished (System.Int32 next) (at <130ada825d394dd8ab9c8756a223ccce>:0)
    GamingIsLove.Makinom.Schematics.Nodes.SpawnPrefabNode+Runtime..ctor (GamingIsLove.Makinom.Schematics.Nodes.SpawnPrefabNode settings, GamingIsLove.Makinom.Schematics.Schematic schematic) (at <130ada825d394dd8ab9c8756a223ccce>:0)
    GamingIsLove.Makinom.Schematics.Nodes.SpawnPrefabNode.Execute (GamingIsLove.Makinom.Schematics.Schematic schematic) (at <130ada825d394dd8ab9c8756a223ccce>:0)
    GamingIsLove.Makinom.Schematics.Schematic.ExecuteNextNode () (at <130ada825d394dd8ab9c8756a223ccce>:0)
    GamingIsLove.Makinom.Schematics.Schematic.NodeFinished (System.Int32 next) (at <130ada825d394dd8ab9c8756a223ccce>:0)
    GamingIsLove.Makinom.Schematics.Nodes.PlaySoundChannelNode.Execute (GamingIsLove.Makinom.Schematics.Schematic schematic) (at <130ada825d394dd8ab9c8756a223ccce>:0)
    GamingIsLove.Makinom.Schematics.Schematic.ExecuteNextNode () (at <130ada825d394dd8ab9c8756a223ccce>:0)
    GamingIsLove.Makinom.Schematics.Schematic.NodeFinished (System.Int32 next) (at <130ada825d394dd8ab9c8756a223ccce>:0)
    GamingIsLove.Makinom.Schematics.Nodes.CheckVariablesNode.Execute (GamingIsLove.Makinom.Schematics.Schematic schematic) (at <130ada825d394dd8ab9c8756a223ccce>:0)
    GamingIsLove.Makinom.Schematics.Schematic.ExecuteNextNode () (at <130ada825d394dd8ab9c8756a223ccce>:0)
    GamingIsLove.Makinom.Schematics.Schematic.NodeFinished (System.Int32 next) (at <130ada825d394dd8ab9c8756a223ccce>:0)
    GamingIsLove.Makinom.Schematics.Nodes.ChangeVariablesNode.Execute (GamingIsLove.Makinom.Schematics.Schematic schematic) (at <130ada825d394dd8ab9c8756a223ccce>:0)
    GamingIsLove.Makinom.Schematics.Schematic.ExecuteNextNode () (at <130ada825d394dd8ab9c8756a223ccce>:0)
    GamingIsLove.Makinom.Schematics.Schematic.NodeFinished (System.Int32 next) (at <130ada825d394dd8ab9c8756a223ccce>:0)
    GamingIsLove.ORKFramework.Schematics.Nodes.ChangeStatusEffectNode.Execute (GamingIsLove.Makinom.Schematics.Schematic schematic) (at :0)
    GamingIsLove.Makinom.Schematics.Schematic.ExecuteNextNode () (at <130ada825d394dd8ab9c8756a223ccce>:0)
    GamingIsLove.Makinom.Schematics.Schematic.NodeFinished (System.Int32 next) (at <130ada825d394dd8ab9c8756a223ccce>:0)
    GamingIsLove.ORKFramework.Schematics.Nodes.RemoveFromInventoryNode.Execute (GamingIsLove.Makinom.Schematics.Schematic schematic) (at :0)
    GamingIsLove.Makinom.Schematics.Schematic.ExecuteNextNode () (at <130ada825d394dd8ab9c8756a223ccce>:0)
    GamingIsLove.Makinom.Schematics.Schematic.NodeFinished (System.Int32 next) (at <130ada825d394dd8ab9c8756a223ccce>:0)
    GamingIsLove.ORKFramework.Schematics.Nodes.HasInInventoryNode.Execute (GamingIsLove.Makinom.Schematics.Schematic schematic) (at :0)
    GamingIsLove.Makinom.Schematics.Schematic.ExecuteNextNode () (at <130ada825d394dd8ab9c8756a223ccce>:0)
    GamingIsLove.Makinom.Schematics.Schematic.NodeFinished (System.Int32 next) (at <130ada825d394dd8ab9c8756a223ccce>:0)
    GamingIsLove.Makinom.Schematics.Schematic.Tick () (at <130ada825d394dd8ab9c8756a223ccce>:0)
    GamingIsLove.Makinom.MachineHandler+MachineUpdate.Tick () (at <130ada825d394dd8ab9c8756a223ccce>:0)
    GamingIsLove.Makinom.Maki.FireTick () (at <130ada825d394dd8ab9c8756a223ccce>:0)
    GamingIsLove.Makinom.MakinomHandler.Update () (at <130ada825d394dd8ab9c8756a223ccce>:0)
    Post edited by Machal on
  • The Add Combatant component (in both ORK 2 and 3) just added a combatant to the game object, using it as the player always required setting it as the player.
    In ORK 3 e.g. via the Set ORK Player node, or by joining the combatant to the player's group. Though, if you keep doing this, you'll end up with a bunch of unused combatants in the player group.

    I'll check out the error - can you give me some details on the settings of the schematic node that calls the formula?
    Please consider rating/reviewing my products on the Asset Store (hopefully positively), as that helps tremendously with getting found.
    If you're enjoying my products, updates and support, please consider supporting me on patreon.com!
  • edited August 13
    I think I've found the issue with the formula. With status values I was using custom format 0%, which actually multiplied my values by 100.
    For some reason thought that % sign is recognized normally, forgot it's '%' lol.
    Post edited by Machal on
  • The custom format texts use C# number formatting, so it can get a bit strange if you don't know what you're doing :D
    Please consider rating/reviewing my products on the Asset Store (hopefully positively), as that helps tremendously with getting found.
    If you're enjoying my products, updates and support, please consider supporting me on patreon.com!
Sign In or Register to comment.