Home › Forums › General Questions › “When called from JS as [function-name].”
Tagged: called from JS puzzleblock
- This topic has 3 replies, 2 voices, and was last updated 4 days, 11 hours ago by
GlifTek.
- AuthorPosts
- 2021-01-12 at 9:54 pm #37323
sjors
NewbieHey guys,
So I know there used to be a puzzleblock that was called “When called from JS as [function-name], do [something].
I can no longer find it in the puzzlepieces, is there a different method of how to do the same thing?
The goal of the method I want to use is to have own html buttons and as soon as I click a button (which will call a function), the material of a certain object will change to the next item in the list.
Anyone here that know where to find the puzzleblock or an alternative method?
I added an image to clearify what I’m trying to do. This is a screenshot from a tutorial from Youtube.
Thanks in advance
Attachments:
You must be logged in to view attached files.2021-01-13 at 3:39 am #37325GlifTek
LicenseeHi,
The easiest approach now to do this is use the exec script puzzleTo use it more flexibly,
You can also write your script in a multi line text puzzleAnd set a variable to that, then plug your variable into the exec script puzzle wherever you need it, so you can edit every use of it from one source.
The call JS puzzles are being deprecated.
I’m having trouble finding them in the user manual too lol.
EDIT: they’re right under the exec script puzzle lol.Just remember to learn how to transfer your puzzle variables into your script using the VARS keyword.
- This reply was modified 4 days, 11 hours ago by
GlifTek.
2021-01-13 at 3:15 pm #37341sjors
Newbie2021-01-14 at 5:50 am #37369GlifTek
LicenseeNice!
- This reply was modified 4 days, 11 hours ago by
- AuthorPosts
- You must be logged in to reply to this topic.