Page 10 of 13
Re: My Github Repository
Posted: Sun Apr 01, 2012 4:53 am
by Vadi
Started with this @
https://github.com/vadi2/remember-mapper
I wonder if Qt signals support collecting return statuses, that way a single 'save' signal could grab the data needed to save. Otherwise, have to link everything to the host.
Re: My Github Repository
Posted: Thu May 17, 2012 11:36 pm
by Vadi
Module setting funcs got merged into sf so I'm documenting them on the wiki now, noticed this:
Code: Select all
if (mpHost->mModulePriorities.contains(moduleName))
mpHost->mModulePriorities[moduleName] = modulePriority;
else{
lua_pushstring(L, "setModulePriority: Module doesn't exist");
lua_error(L);
return 1;
}
It should not error out, should return nil and the error msg instead per Lua convention. Makes it more pleasant to work with - because getting a module name wrong is not a usage contract error.
Re: My Github Repository
Posted: Thu May 17, 2012 11:45 pm
by Vadi
Having listModules() couldn't hurt as well.
Re: My Github Repository
Posted: Fri May 18, 2012 2:09 am
by chris
To me getting a module name wrong is a usage contract error, that module can be a needed dependency of something it is being prioritized over.
A module list is trivial to add, but I don't think really needed with the UI.
Re: My Github Repository
Posted: Fri May 18, 2012 3:39 am
by Vadi
No, the contract is the proper use of the API - you pass a string and a number. But getting it right whenever a module is installed or not at runtime isn't doing the contract wrong, that's too harsh... other functions in Mudlet don't crash either (or shouldn't) when you give it something at runtime that doesn't exist.
Re: My Github Repository
Posted: Fri May 18, 2012 5:30 am
by Vadi
Doing this seems to cause an error:
addMapEvent("room a", "onFavorite")
local s,m = pcall(getMapEvents) if not s then display(m) end --> 'attempt to index a string value'
Same deal with getMapMenus().
Re: My Github Repository
Posted: Fri May 18, 2012 12:07 pm
by chris
Oh that's the result of having a variable number of arguments for events now. I need to adjust the calls in the lua stack to reflect that. Good catch.
Re: My Github Repository
Posted: Sat May 19, 2012 3:07 pm
by chris
That error is fixed now Vadi. I also put in custom options with respect to the mapper controls. You can now choose to pan by default, and what keys will enable enhanced mapper functionality. For the time being, the selections are just shift/alt/control but it can be opened up in the future when the bugs are worked out.
Re: My Github Repository
Posted: Sat May 19, 2012 11:00 pm
by Vadi
Alright. Could you sync the Qt 4.8 glu include fix from main? Qt 4.8 no longer embeds it and it needs to be included and linked to explicitly.
glwidget.cpp:29:24: fatal error: gl/GLU.h: No such file or directory
Re: My Github Repository
Posted: Sun May 20, 2012 1:45 pm
by Daagar
Does this mean main (and probably soon, chris' fork) should be built using Qt 4.8? I still compile on Windows, and main still seems to function fine with Qt 4.7.3. Curious what impact this has, as getting a windows compile going was such a pain for a long time and I prefer to not tinker with it too much if possible