|
Progonoi Magician
Joined: 28 Jan 2007 Posts: 430
|
Posted: Fri Aug 01, 2008 8:25 pm
[CMudPro 3.0] Room look-up with %mapfilter. |
I figured I'd try CMud out now too, with all the major re-writes coming up
However, stumped into something weird that I don't really know how to address.
Code: |
#va RoomSearch {A dark alley}
#call %mapfilter(%null)
#call %mapfilter(%concat("Name"," LIKE ","'%",%replace(@RoomSearch,"'","''"),"%'"," AND ","ZoneID"," = ",%zonenum))
#loop %numrooms {#addkey RoomDB {%roomvnum( %i)} {%i}}
|
Thats the gist of a larger piece of script which makes Room Name look ups. The code above is how I tried if the major part works.
Which unfortunately doesn't.
I do the mapfilter call. Check that mapfilter is called how it should be. Then I do #loop %numrooms but nothing gets added to
RoomDB. Even doing just #loop %numrooms and waiting info to appear on main screen doesn't yield any result.
Needless to say, all this works 100% in ZMud.
There's most likely something I've overlooked myself because the lack of time at the moment I haven't gone through all the "script
conversion" steps I ought to under CMud. I did, however, run comp. report and even though it came up with some cosmetic things
I should change, this script nor the part above wasn't mentioned.
So I'm at total loss here.
Thanks in advance,
Prog |
|
|
|
Vijilante SubAdmin
Joined: 18 Nov 2001 Posts: 5182
|
Posted: Fri Aug 01, 2008 8:50 pm |
Hrm, look like %mapfilter broke somewhere along the way. I would suggest grabbing my Toolbox package from the library and using some of the searches it has in the MappingWidgets class instead.
|
|
_________________ The only good questions are the ones we have never answered before.
Search the Forums |
|
|
|
Tech GURU
Joined: 18 Oct 2000 Posts: 2733 Location: Atlanta, USA
|
Posted: Fri Aug 01, 2008 8:51 pm |
Have you tried this is 2.35? CMUDPro 3.0 is the first cut of the mapper rewrite and the mapper database associate has been changed. Knowing that difference will probably be useful to Zugg in trying to debug the problem. I haven't gotten my hands on it yet myself. But will later today. Good luck.
|
|
_________________ Asati di tempari! |
|
|
|
Progonoi Magician
Joined: 28 Jan 2007 Posts: 430
|
Posted: Fri Aug 01, 2008 8:59 pm |
Hrm, unfortunately nope. I wanted to see how things work with first re-write draft, so I installed 2.35 and on the top of that 3.0 as Zugg instructed in the thread he wrote about releasing it.
Unsure whether I can install 2.35 somewhere separately though. I'm still running on evaluation period and haven't bought the product yet.
Glad to hear it not being the fault of my code's somehow. I'm not in any rush with it either way, it was just literally something I tried
as a very first thing right after map conversion to 3.0 had finished.
I really hope it to get figured out though
If there's a way in can install 2.35 somewhere separately even while being under evaluation period, I'm more than glad to help out, too.
Prog |
|
|
|
Seb Wizard
Joined: 14 Aug 2004 Posts: 1269
|
Posted: Sat Aug 02, 2008 12:00 am |
Zugg didn't say you needed to install 3.0 on top of 2.35: he said it uses the same files, i.e. everything except for the map database file is the same, and if you have your data files located not in the install directory, they will be used by 3.0, so BACK them up!
So, yes, there shouldn't any problem installing 2.35 somewhere else, even if you are on a trial period. If you are on Vista, Zugg says don't put your _data_ files in Program Files, although I don't know why: 32-bit versions of Vista have a compability layer that should handle this (but I haven't tried it). |
|
|
|
Progonoi Magician
Joined: 28 Jan 2007 Posts: 430
|
Posted: Sat Aug 02, 2008 12:37 pm |
Nods, I was just using the wrong wording, I suppose.
Anyway, I installed CMud 2.35 into a separate folder and tried out same script - and it Worked!
I'm more than happy to provide Zugg with complete script in case he needs it for debugging (though "test case" I provided should be enough for seeing what isn't working).
I won't be around few days until middle of next week though so this has to hold until then.
Thanks for quick responses,
Prog |
|
_________________ The Proud new owner of CMud.
--------------------------------
Intel Core i5-650 3,2GHz
4 DD3 RAM
GTX 460 768MB
Win 7 Home Premium 64x
-------------------------------- |
|
|
|
|
|