I was trying to use expression block to try and get a character from where they are to a specific spot for dialogue, however I encountered this:
550 - 30 = 0
and after trying to find out what was happening it suddenly started doing this:
550 - 30 = 550
I’m not quite sure if this is a bug or my own code, so here’s the whole thing:
I tried labelling everything so that it’s easier to read.
This only happens when I interact with the NPC the first time, the expression block works the other times I interact with the NPC.
Yeah, that’s really weird. The only thing I can think of is maybe its A-B, not a-b. It’s probably not case sensitive but worth a shot.
@glowbug @JR_01 @grazer
Also how do you add notes…? Lol, I’ve been on flowlab for 4-6 years and still never knew this was a thing!
Is it working correctly when you test it in game?
This could be a visual thing, if there are multiple copies of that block or other numbers that are being sent the behavior editor doesn’t show whets happening in just one object but all of the same type of objects, basically they conflict with each other. And this is all visual.
That’s the only reason I can think of, of course this might not be the cause but just make sure you don’t have more than one type of the same object.
So basically, if too many things are packed into an object then it could mess up how things work in it? I only have one object for this object type in the game world.
I added a delay for the eval input and it works 100% every time I test it so I’m guessing the eval input was activated before the B could enter?
Well no, If you only have one of that single object then that rules out that possibility.
Also if you say for it to eval constantly it will update so that doesn’t matter.
Also also, If it doesn’t affect things in game then it’s not any type of visual bug.
If you click on this it opens a box where you can put words in! Then after you close the block there’s a speech bubble icon that you can click on that will show the note!
Thank you. I don’t know how I missed that! I always assumed it was the same as the help button.
It would be helpful if I could get a link to look into it further.
Sometimes when objects bug out, it works again if you delete the program block and place it back in. So in this case, delete your calculator block.
The problem is in the “Player” object, “stop during dialogue” bundle.
I labled the expression block as “the problem”
It appears to be working for me, it calculates it correctly, it could be a local problem, or something to do with your side. Maybe you could refresh the page?
If your getting wrong values from the output, it’s most likely that the values aren’t updating correctly before eval gets inputted.
Your asking about the expression on the top, the one without a delay into eval? I suggest adding a timer (like you did with the bottom expression) but set to 0.
Yeah, I added a delay before eval and I think the values are updating before eval now! Thank you! I think half of my problems are because certain things are updated before others which is a bit annoying to try and work around lol
Yeah, getting things to trigger at one time can be tricky.
You could use the bottom number (30) into eval and should work correctly.
If not, using an Always with other x extractor will work with the bottom number (30) into eval.
Yeah I think I’ll try that instead, it’ll makes the whole bundle less crowded. I’m always a bit hesitant to use delay blocks cause I always think that too much over one another would make the game run super slow.
It’s not too bad if you just use a few and set them to 0
I’ll keep that in mind, thank you for helping out!