Sync triggers may be a bit broken

Sync triggers may be a bit broken

Postby jeje52 » 22 October 2018, 14:18

If you have a variable that is set to a number and you sync it, any values added to it will be added to the end.
If the variable value is 3, it goes like this:
Before syncing: 3 + 1 = 4
After syncing: 3 + 1 = 31
This is what happens on jeje52-test3, where I found the bug. I hope I'm not just doing it wrong.

Edit:
I would like to see this bug get fixed, I reported this more than a month ago.
I think the variable value type turns to string when synced, just change that to integer if it's only a number and it's fixed. But I don't know much about how the game works so I could also be completely wrong.
User avatar
jeje52
Civil Security Lite [100]
 
Posts: 146
Joined: 13 April 2018, 19:52

Re: Sync triggers may be a bit broken

Postby Eric Gurt » 2 January 2019, 00:23

Yes, it seems like it converts to string. Until it is fixed you can multiply value of variable by 1, so it converts it back to number.
Work it harder
Make it better
Do it faster
Makes us stronger
More than ever hour
After our work is never over.
User avatar
Eric Gurt
PB2 Developer
 
Posts: 409
Joined: 14 July 2013, 16:46
Location: dn.ua

Re: Sync triggers may be a bit broken

Postby jeje52 » 6 January 2019, 18:51

Multiplying by 1 fixed it, I don't know how I missed such an easy solution. There's still a small inconvenience as you can't multiply it right after syncing it because there's a second delay in syncing, so you can't sync and multiply in the same place.
User avatar
jeje52
Civil Security Lite [100]
 
Posts: 146
Joined: 13 April 2018, 19:52


Return to Bug Reporting Archive

Who is online

Users browsing this forum: No registered users