Kaenguruu24
Kaenguruu24
CC#
Created by Kaenguruu24 on 7/31/2024 in #help
Determine the positions of nodes inside of a graph
Unfortunately I don't know any good references for this, I'm mostly just trying stuff. If you take a look at the links I provided, you'll probably find that the authors of these articles/papers used a similar data structure
28 replies
CC#
Created by Kaenguruu24 on 7/31/2024 in #help
Determine the positions of nodes inside of a graph
The graph structure comes through how you build the references between instances of these classes. So your "On Component Begin Overlap (Box)" would be a ProductionStep instance that has in it's Children list the == and the "Branch" node as instances of ProductionStep. The == has in their Parents list the "On Component Begin Overlap (Box)" and "Get Player Pawn" and the "Branch" node as child and so on and so forth
28 replies
CC#
Created by Kaenguruu24 on 7/31/2024 in #help
Determine the positions of nodes inside of a graph
So in my code, the FactoryTree class looks like this:
public class FactoryTree
{
ProductionStep root;
Recipe recipe;

public FactoryTree(Recipe recipe)
{
this.recipe = recipe;
root = new ProductionStep(recipe, 1);
}
}
public class FactoryTree
{
ProductionStep root;
Recipe recipe;

public FactoryTree(Recipe recipe)
{
this.recipe = recipe;
root = new ProductionStep(recipe, 1);
}
}
And then the ProductionStep class looks like this (there are some more specific parts removed, but for the basic understanding this should be enough):
public class ProductionStep
{
public Recipe Recipe;
public List<ProductionStep> Children;
public ProductionStep Parent;

public ProductionStep(Recipe recipe, float count)
{
Recipe = recipe;
Children = new List<ProductionStep>();
}
}
public class ProductionStep
{
public Recipe Recipe;
public List<ProductionStep> Children;
public ProductionStep Parent;

public ProductionStep(Recipe recipe, float count)
{
Recipe = recipe;
Children = new List<ProductionStep>();
}
}
This is basically enough. If you have multiple inputs (so multiple parent nodes) you would replace ProductionStep Parent with List<ProductionStep> Parents etc.
28 replies
CC#
Created by Kaenguruu24 on 7/31/2024 in #help
Determine the positions of nodes inside of a graph
Could you elaborate on what you mean with that exactly? The code I use to generate the graph looks like this:
28 replies
CC#
Created by Kaenguruu24 on 7/31/2024 in #help
Determine the positions of nodes inside of a graph
No description
28 replies
CC#
Created by Kaenguruu24 on 7/31/2024 in #help
Determine the positions of nodes inside of a graph
I've found this blog post here: https://rachel53461.wordpress.com/2014/04/20/algorithm-for-drawing-trees/ Which seems to be enough for my understanding. I'm looking through the code right now and it looks like I can relatively easily adapt my current code to work with this implementation
28 replies
CC#
Created by Kaenguruu24 on 7/31/2024 in #help
Determine the positions of nodes inside of a graph
I'll look into that one, also if you could have a quick check since the following one also seems to be quite fitting for my purpose and not too complicated: https://www.cs.unc.edu/techreports/89-034.pdf
28 replies
CC#
Created by Kaenguruu24 on 7/31/2024 in #help
Determine the positions of nodes inside of a graph
Assuming I figure out anything cause right now I'm a bit lost
28 replies
CC#
Created by Kaenguruu24 on 7/31/2024 in #help
Determine the positions of nodes inside of a graph
I'm not 100% sure. In the current implementation I think it is not possible since this is recursively iterating through the childs which would make that impossible. However, one thing I considered was combining for example resource extraction steps (the ones that only have an item and quantity on the right side of the node) of the same type together in which case they would then have multiple parent nodes right?
28 replies
CC#
Created by Kaenguruu24 on 3/21/2024 in #help
Converting Regex to a DFA
Currently reading this: https://deniskyashif.com/2019/02/17/implementing-a-regular-expression-engine/ Which seems fairly promising
4 replies
CC#
Created by Kaenguruu24 on 3/10/2024 in #help
Sending key presses to other applications without Windows Forms
Kinda sad im gonna be honest. Have a good day then
44 replies
CC#
Created by Kaenguruu24 on 3/10/2024 in #help
Sending key presses to other applications without Windows Forms
So you are not sure whether I'm trying to cheat is basically what you are saying?
44 replies
CC#
Created by Kaenguruu24 on 3/10/2024 in #help
Sending key presses to other applications without Windows Forms
I have not experienced even the slightest drop in fps while the application was running. It's a personal use project only so nobody else is impacted by this
44 replies
CC#
Created by Kaenguruu24 on 3/10/2024 in #help
Sending key presses to other applications without Windows Forms
honestly I don't care about that little performance impact
44 replies
CC#
Created by Kaenguruu24 on 3/10/2024 in #help
Sending key presses to other applications without Windows Forms
See the previous conversation. I know how to use it, it provides a quick way to set up a graphical user interface and my experience with winforms was horrible
44 replies
CC#
Created by Kaenguruu24 on 3/10/2024 in #help
Sending key presses to other applications without Windows Forms
I'm aware, thank you
44 replies
CC#
Created by Kaenguruu24 on 3/10/2024 in #help
Sending key presses to other applications without Windows Forms
yes
44 replies
CC#
Created by Kaenguruu24 on 3/10/2024 in #help
Sending key presses to other applications without Windows Forms
all sorts of applications. Discord, Firefox, games like DCS or ETS 2
44 replies
CC#
Created by Kaenguruu24 on 3/10/2024 in #help
Sending key presses to other applications without Windows Forms
Yes and as I mentioned it's for personal use only and I'm on Windows so thats not a problem
44 replies
CC#
Created by Kaenguruu24 on 3/10/2024 in #help
Sending key presses to other applications without Windows Forms
Yes. Imagine it as a sort of digital stream deck where pressing a button should execute a key combination (or just a single key) on another program
44 replies