Error 1180137048
-
Hit a bit of a brick wall with my synth program.
I have it playing a patch(note) each step of the sequencer.
Playnote(0,wave[step],note[step],volume[step],speed[step],pan[step])Working fine so I make the sequence blocks selectable. So it will only play on a selected block.
If selectedblock[step] == true then
Playnote(0,wave[step],note[step],volume[step],speed[step],pan[step])
endifAnd it says error on line 48 (which is a blank line)
In function sequencermain (No where near 48)
Unrecognised type 1180137048Ok sure. So the only code I've changed is the if statement.
So I comment out playnote
If selectedblock[step] == true then
//Playnote(0,wave[step],note[step],volume[step],speed[step],pan[step])
endifAnd the error is gone.
So next I commend out the if statement just to be sure
//If selectedblock[step] == true then
Playnote(0,wave[step],note[step],volume[step],speed[step],pan[step])
//endifNo error. So it's not the if statement and it's not the play note.
So I try
If selectedblock[step] == true then
Playnote(0,2,440,1,1,1)
endifAnd it works...
So the error is the wave[step] BUT ONLY when it's in the if statement.
Can someone smarter than me explain why type cannot be recognised only when in the if statement or this a bug in the compiler?
If one of the devs want to look I've shared the code. It's called Piano synth
Have commented in the block that's erroring. Touch some sequencer blocks then press down on dpad to play the sequencer and cause errorUpdate: have got a work around. Instead doing playnote inside the if statement I call a function that only contains playnote and it works. So seems like a bug to me
-
To me this looks like a bug and should be re-posted to the bugs section. If you're re-posting this into the bugs section you should include the full working/non-working code snippet, i.e selectedblock and wave variables declaration and how you iterate over it, i.e what step is and how it's used (I assume some for-loop?)
-
It does sound like a bug. If you can post a small sample of code that exhibits it I can try it with the first patch
-
@mixaal yes step just held an integer. This was not the actual code but have uploaded the source to their server. Pretty obscure bug if it is one.
-
@pianofire I don't think it's going be reproduced by a snippet As it's looping through a populated 9x17 2d array. Have shared the project. If you need my friend code let me know.
I have done the workaround. But left the suspect code commented out. I am unsure how the sharing works. Did it a share a snapshot or does upload each time I save
-
Unfortunately I can't transfer code between my retail and dev switch so I would have to re-key it!
Please report it on the bugs page for now