plixel

@plixel@programming.dev

This profile is from a federated server and may be incomplete. Browse more on the original instance.

plixel,

I really liked Kagi at first, especially since I use it mainly for programming as well, but recently I feel like the quality has gone downhill. Right around the time they integrated the Brave stuff I’ve noticed a significant amount of me having to scroll down past the usual Google-like fluff results before getting to actually relevant information. It’s a little sad to see because when I first used it, it was so good now it basically feels like a skinned Google-lite at this point. I’m still a customer but only because I haven’t found a good alternative yet.

plixel,

Thanks so much for testing that out! That’s very informative and even more thorough than what I was looking for! I wasn’t at my computer when I posted this so I couldn’t test it myself.

I ended up connecting the signal to a secondary function to run on finished to avoid any potential memory errors, but it’s super helpful to know that the performance impact is minimal.

plixel,

Thanks for the explanation! Your explanation led me down a rabbit hole of seeing if there’s a way to cancel an await call, from what I can tell there was no clear way to do so. In my case I ended up connecting the signal to a secondary function instead of utilizing the await command, I’m not entirely sure if there’s an advantage to utilizing one method over the other.

plixel,

I’m emitting in the function that instantiates the tiles so it’s definitely getting called. How do I verify that the connection is going through?

Also thanks for letting me know how to format it I was getting conflicting information regarding the syntax from various different tutorials and resources.

plixel,

Is this the intended purpose for signals? Moving info up and down the tree? If so how are we supposed to send information from one script to another if one is not directly a child of the other? Do we send it to a shared parent node then send the info back down to the secondary script?

plixel,

Thank you! Okay so the tiles are part of a map, and I have a parent node called map with two separate children: hexgrid (where I’m instantiating the scenes) and spawn_objects( where I’m trying to gain access to the index and transform from hexgrid) my intent is to have hexgrid generate the grid and tiles and have spawn_objects instantiate an object within the tile at a certain position within it. Is this perhaps something I should combine into the same script? I typically like to have things modular and keep each component so a single specific task.

plixel,

Hm…I didn’t even consider that the emit might be happening before the connection. I have them both running from separate on_ready methods. Perhaps I should be running connection though _init. Typically in unity I would just use C# actions and use OnEnable to establish the “connections.” It make sense that the code could be emitting before I even have a chance to connect to it, which is why my test fails.

plixel,

I see okay so I understand that the intent is to decouple scenes from each other, however from the tutorials I’ve seen they typically say that to establish the connection you need to run get_node() from the script you are establishing the connection to. So for example if you have:


<span style="color:#323232;">*Parent
</span><span style="color:#323232;">    **Child 1
</span><span style="color:#323232;">    **Child 2
</span>

You would emit from Child1, then establish the connection from Child2 using:


<span style="color:#323232;">var script = get_node("root/Parent/Child1")
</span><span style="color:#323232;">script.some_signal.connect(some_function)
</span>

Is that the correct interpretation? Or am I misunderstanding? Thanks in advance btw I appreciate all the help in understanding this!

plixel,

Interesting!! Yeah that’s exactly what my node structure is. So basically instead of using signals and sending from one Map child to the other, use spawn_object as a child from hexgrid and then just call the spawn object function as needed since the hexgrid script already has a reference to the index and location of each tile. Thanks so much for the advice I’ll give it a shot! I ended up working out the signals issue I was having anyways but it seems like your suggestion is a cleaner solution!

  • All
  • Subscribed
  • Moderated
  • Favorites
  • megavids
  • thenastyranch
  • rosin
  • GTA5RPClips
  • osvaldo12
  • love
  • Youngstown
  • slotface
  • khanakhh
  • everett
  • kavyap
  • mdbf
  • DreamBathrooms
  • ngwrru68w68
  • provamag3
  • magazineikmin
  • InstantRegret
  • normalnudes
  • tacticalgear
  • cubers
  • ethstaker
  • modclub
  • cisconetworking
  • Durango
  • anitta
  • Leos
  • tester
  • JUstTest
  • All magazines