Changed Label Properties aren't Spawn Compatible
-
In behaviours, set a label's textual value to something.
Then use a behaviour to set a label's colour to something other than default
Now Spawn a "copy" of it.
The spawned label reverts to the default textual content of the label and its default colour.
This isn't a spawn of the label, it's a spawn of what the label once was.
-
@Deeeds Yeah when objects are spawned they do not take on any of the current state of the parent, just the state it was in from the editor. You’d have to do it manually.
-
@Aidan-Oxley Do what manually? I don't see how I can create a bunch of labels with different text.
-
@Deeeds If I understand right, you wanna spawn an object with the same state as the object that spawned it?
-
@Aidan-Oxley Yes, that might be successful. But I don't know how to think in hyperPad's limited world of spawning.
I want to spawn a lap time, and present it.
Then, a little later, another lap time is completed, and I want to spawn and present that.
etc... down the side of the screen, a bunch of lap times in a list grows as each lap is completed.
Each lap time has a unique number, obviously. And I thought this should be as easy as changing the master/parent to the lap time, then spawning a copy and positioning it on the list.
-
@Deeeds I personally wouldn’t bother trying to make a system to dynamically spawn a list (w/ each different text), at least not until HyperPad gets a better way to spawn an object and apply unique manipulation to it.
One way I was experimenting with it, was using the broadcast and receive behaviours is to create a unique Callback ID for each spawned object, based on their spawned location.
Once all objects are spawned, I reloop the array for broadcasting each individual object their needed unique information as an array, (text, in this case), using the unique Callback ID as the broadcast key, so the broadcast won’t conflict with other spawned objects.
This works for me, but I find it extremely horrible to do it this way.
TD;LR: It’s possible, but kind of messy and unconvinent and if you don’t need to make it right now, I’d wait for HyperPad to get a better way to do this.
-
@Kamdroid They should just give an option to either copy the original state of the spawned object, or the current state.
-
@Kamdroid Couldn't agree more with you. At all.
But must get lap timer done... and with a bit of a scoreboard, so doing it anyways... and it's ridiculous. IN EVERY SINGLE WAY.
-
-
@Deeeds You could also just use the “Combine Text” behaviour to make one label object, and just keep adding text to it. However, in most cases, this limits you too much.
-
@Kamdroid I didn't even know about that "feature". Will look into it!
Cheers!!!
-
@Kamdroid THIS: https://forum.hyperpad.com/post/3687
Sorry, it's boring. And so am I.
-
@Deeeds Also, this is a way you could add to the list, simply do a broadcast to “+label_timescore” (or whatever your broadcast key is)
NOTE: whoops, don’t forget to add the set label to apply the combine text result to the label.
I just like this, since it’s like a function,
(You could also number the label using a label or attribute keeping track of the list number, and using another combine text) -
@Kamdroid This is a very cool cheat!