MagicTurtle v1.38 - Pathfinding! Mapping! Exploration!
#21
Posted 26 August 2012 - 06:08 AM
#22
Posted 29 August 2012 - 02:59 PM
funkey100, on 26 August 2012 - 06:08 AM, said:
I've been poking at this API recently and have found quite a few improvements to make. I'm not quite ready to bring it to the two authors yet, but the code is being continually worked on!
#23
Posted 04 September 2012 - 06:40 AM
I was hopping you could tell me what functions in your code handles this kind of events so I can get some ideas how to move the turtle to get unstuck.
thanks
linuxpro
#24
Posted 04 September 2012 - 09:36 PM
#25
Posted 05 September 2012 - 12:47 AM
#26
Posted 16 September 2012 - 03:52 PM
#27
Posted 29 September 2012 - 05:11 AM
The reason is that functions can't share the same name as any variables. (i.e. you can't have a function named version because you already have a variable by that name)
(yeah I know it's not a huge bug but I thought it might be worth knowing)
Oh, and hi all. Love the mod, API looks cool too.
#28
Posted 29 September 2012 - 11:00 PM
Starwaster, on 29 September 2012 - 05:11 AM, said:
The reason is that functions can't share the same name as any variables. (i.e. you can't have a function named version because you already have a variable by that name)
(yeah I know it's not a huge bug but I thought it might be worth knowing)
Oh, and hi all. Love the mod, API looks cool too.
#29
Posted 05 October 2012 - 09:16 AM
MysticT, on 29 September 2012 - 11:00 PM, said:
Starwaster, on 29 September 2012 - 05:11 AM, said:
The reason is that functions can't share the same name as any variables. (i.e. you can't have a function named version because you already have a variable by that name)
(yeah I know it's not a huge bug but I thought it might be worth knowing)
Oh, and hi all. Love the mod, API looks cool too.
Doesn't matter whether it's global or local. It's a naming restriction. Names (or identifiers in lua) are used for the same purpose in variables OR functions. Once it's declared for something, you can't then turn around and reuse the name for something else.
Renaming the variable eliminates the issue. (which, understand, it's not a huge issue; I doubt anyone out there was depending on the version function for something critical, I only posted as an FYI to the OP and to anyone else who might come across this post)
#30
Posted 06 October 2012 - 01:09 AM
Starwaster, on 05 October 2012 - 09:16 AM, said:
MysticT, on 29 September 2012 - 11:00 PM, said:
Starwaster, on 29 September 2012 - 05:11 AM, said:
The reason is that functions can't share the same name as any variables. (i.e. you can't have a function named version because you already have a variable by that name)
(yeah I know it's not a huge bug but I thought it might be worth knowing)
Oh, and hi all. Love the mod, API looks cool too.
Doesn't matter whether it's global or local. It's a naming restriction. Names (or identifiers in lua) are used for the same purpose in variables OR functions. Once it's declared for something, you can't then turn around and reuse the name for something else.
Renaming the variable eliminates the issue. (which, understand, it's not a huge issue; I doubt anyone out there was depending on the version function for something critical, I only posted as an FYI to the OP and to anyone else who might come across this post)
Anyway, not a big deal, it's just a version check that most people probably won't use />
#31
Posted 09 October 2012 - 07:54 PM
#33
Posted 13 October 2012 - 04:09 PM
#35
Posted 15 October 2012 - 05:22 AM
#36
Posted 16 October 2012 - 12:06 AM
ChunLing, on 15 October 2012 - 05:22 AM, said:
#37
Posted 16 October 2012 - 06:56 PM
The fact that nobody could deny that I had indeed been subjected to unjustified use of lethal force sorta worked in my favor, I guess. Though the lethal force itself is not something I'm ready to put in my 'fun times' column. It was actually most unpleasant.
#38
Posted 18 October 2012 - 11:22 PM
MysticT, on 06 October 2012 - 01:09 AM, said:
Starwaster, on 05 October 2012 - 09:16 AM, said:
MysticT, on 29 September 2012 - 11:00 PM, said:
Starwaster, on 29 September 2012 - 05:11 AM, said:
The reason is that functions can't share the same name as any variables. (i.e. you can't have a function named version because you already have a variable by that name)
(yeah I know it's not a huge bug but I thought it might be worth knowing)
Oh, and hi all. Love the mod, API looks cool too.
Doesn't matter whether it's global or local. It's a naming restriction. Names (or identifiers in lua) are used for the same purpose in variables OR functions. Once it's declared for something, you can't then turn around and reuse the name for something else.
Renaming the variable eliminates the issue. (which, understand, it's not a huge issue; I doubt anyone out there was depending on the version function for something critical, I only posted as an FYI to the OP and to anyone else who might come across this post)
Yes, ok, you can have variables with the same name in different scopes, but that's not relevant here because that's not what's happening.
Regarding the locality and its effect on the function, that doesn't happen when you don't reuse a name that you've used elsewhere. What do you think would happen if it WEREN'T local? You'd end up with a function that returns its own table entry instead of a value that had previously been assigned to that name as a variable. Same problem with different symptoms. I apologize if this comes across as argumentative because that's not my intent. Just trying to be helpful.
#39
Posted 19 October 2012 - 01:43 AM
#40
Posted 23 October 2012 - 09:54 PM
Thanks for letting me use it!
1 user(s) are reading this topic
0 members, 1 guests, 0 anonymous users