[Thyme] Implicit type conversion: non-string to string

Suggest changes and improvements to Algodoo.

[Thyme] Implicit type conversion: non-string to string

Postby tatt61880 » Sat May 05, 2012 6:39 pm

For example, when I scripted below,
(e) => { e.this.text = e.pos}
21333 ms: - WARNING - Caught Exception: Not a string, source\script\Attributes.hpp:179: void script::TAttrib<util::String>::CalcValueFromObject(bool)
21333 ms: - WARNING - Failed to find name of ClassObject
21333 ms: - WARNING - text was bound to bad type. Restoring to last known value.

I know, "" + foo is a kind of implicit type conversion. (i.e. (e) => { e.this.text = "" + e.pos} works well)

My suggestion is to let (e) => { e.this.text = e.pos} work well.

I know Thyme has the lowest priority of everything. ... but I want this ;)
NOTE: I'm not an Algoryx member.
Hi, Algodoo lovers. Have you read next topic? Featured scenes suggestions
To translators: English.cfg changelog will be useful (even for me).
User avatar
tatt61880
[Most Helpful Person 2010]
 
Posts: 1150
Joined: Mon Aug 31, 2009 5:45 pm
Location: Tokyo, Japan

Re: [Thyme] Implicit type conversion: non-string to string

Postby Kilinich » Sat May 05, 2012 8:47 pm

no no, don't do that.
with no debugger it will be really hard to find invlid type assign...
Dream of Algodoo as game development engine...
User avatar
Kilinich
[Best bug reporter 2010]
 
Posts: 2098
Joined: Mon Aug 31, 2009 8:27 pm
Location: South Russia


Return to Suggestions

Who is online

Users browsing this forum: No registered users and 8 guests

cron