Omnimaga

Calculator Community => Other Calc-Related Projects and Ideas => TI-Nspire => Topic started by: DebboR on March 27, 2014, 01:00:16 pm

Title: Strange behavior of Lua drawString
Post by: DebboR on March 27, 2014, 01:00:16 pm
Hello,


I have a little question concerning Lua's drawString on my nspire. I have OS 3.1 cas running (nlaunch) on my non-cas touchpad nspire.
It works great, except for one little issue: when I open Lua files that print numbers on the screen using drawString, the numbers get all messed up. For example: when I write 2, it turns into: 6.132164321546e-227 or something similar.


I think the fault happens when I call gc:tostring(theNumberToGetStringified), because if I draw "2", it works fine.


Is this a bug with nLaunch? Can I do something to prevent this from happening?


Thank you!
DebboR
Title: Re: Strange behavior of Lua drawString
Post by: Jim Bauwens on March 27, 2014, 06:53:02 pm
Wel, considering that drawString just draws string and doesn't manipulate strings I suppose some calculation in your code must have a little bug :) Try checking what you're actually drawing to the screen.

Edit: wait, maybe it is an Nlaunch problem: http://www.omnimaga.org/general-calculator-help/(bug)-mathematical-errors-while-nlaunched-into-cas-os-on-a-cx/. Are you running the latest versions of Ndless 3.1 and Nlaunch? This bug should have been fixed.

Title: Re: Strange behavior of Lua drawString
Post by: DebboR on March 30, 2014, 02:22:38 pm
Thanks, updating to nLaunchy indeed solved the problem :-)


DebboR