Bug Report: When Certain objects are tapped following code doesn't play


#1

Username: BlastFusion.
Device: iPad Air 2 iOS (the one before 11)

Description of bug: normally one variable can equal another, yes. But when you have a conditional showing this rule it doesn’t work. Variables can only equal numbers. This makes remembering code harder.

Now here is a bug:
Why doesn’t this work:

But this does


@POMTL


#2

I used this code:


Am done got this result:

@blastfusion


#3

Ye but this code doesn’t work:
Set “Pokemon Attack” to “Thunderbolt”


Check once if “Pokemon Attack = Thunderbolt”

Is setting ‘to’ different to ‘equals’?


#4


@BlastFusion


#5

Thanks. But I don’t know why it ain’t working for me: on the other project


#6

Interesting.

Ok, I just used the exact same code and it worked.

Odd.


#7

Hi @BlastFusion

I suggest you move this to Help with Code. I’m sure it’s a bug in your code and not with Hopscotch.


It could be something simple. For example, if you switch the order of the two When (Game Starts) in your example above, it won’t work.

Also, your variable “Thiq” has to be set in a When (Game Starts) before the code you showed, or it won’t work.

(technically it does work because both variables will equal 0, but that defeats the point of setting one equal to the other)

You have to take into account the intra-frame order of code execution.


#8

Weird. Check your project and see if the variables you are talking about changes anywhere else that makes the condition false. If so, that might be the case. If not, there might be a bug with the editor.


#9

Try
When game starts:
Set Var1 to Var2
And then
When game starts:
Wait 100 milliseconds
Check once if Var1 = Var2
Set text “Equals”


#10

It actually was working in that project. But in my other project I don’t think it was working because my check once ifs went to this level:


#11

Even that many nested conditionals shouldn’t, by itself, be a problem.

My Word Scramble project used 27 nested conditionals to display letters from the values. But it’s really difficult to work with, as you know. If you want to temporarily publish, we could try to help you troubleshoot it.


#12

@HopscotchRemixer please don’t change the category because deprecated help with code was not proper and debug my code is the official new category, and its more like find what is improving my code to make it work.

@Thinbuffalo don’t worry about it, I used numbers and everything worked fine.


#13

Now here is a bug:
Why doesn’t this work:

But this does?


@POMTL


#14

Never mind, I just got a complete new text


#15

Now this bug is annoying. Some texts just won’t be tapped.