Are MouseModes hardcoded to specific numbers?

Started by subspark, Sun 14/03/2010 11:43:09

Previous topic - Next topic

subspark

We're having a great deal of trouble with verbs in the events pane being mis-aligned to the verbs in the script.
For instance, in the events pane of a hotspot, if I choose Close hotspot, in the script it will turn up as function hHotspot1_Mode8()
If I chose Open hotspot from the events pane, in the script it will read, function hHotspot1_PickUp()

My mouse modes are preferablly as follows:
0 = WalkTo
1 = LookAt
2 = PickUp
3 = Use
4 = Unused
5 = Open
6 = TalkTo
7 = Push
8 = Close
9 = Give
10 = Pull

Any ideas for what in hark is going on here? ???

Cheers,
Sparky.

Pumaman

Currently the suffixes given to the event handler functions are fixed, and are not based off the name of the mouse cursor mode. I agree that this is a bit confusing, and should probably be changed for a future version.

Dualnames

Quote from: subspark on Sun 14/03/2010 11:43:09
We're having a great deal of trouble with verbs in the events pane being mis-aligned to the verbs in the script.
For instance, in the events pane of a hotspot, if I choose Close hotspot, in the script it will turn up as function hHotspot1_Mode8()
If I chose Open hotspot from the events pane, in the script it will read, function hHotspot1_PickUp()

My mouse modes are preferablly as follows:
0 = WalkTo
1 = LookAt
2 = PickUp
3 = Use
4 = Unused
5 = Open
6 = TalkTo
7 = Push
8 = Close
9 = Give
10 = Pull

Any ideas for what in hark is going on here? ???

Cheers,
Sparky.

I think what you're saying has been encountered, and I'm sure CJ is working on this as well. I've actually found that myself without any problems, but can really create a mess, especially in Cat Lady, because you're like changed the cursor into something that helps you understand what it is, and then inside the script, it's something else. For a newbie this can prove a little weird, and he might just end up spending hours before realizing it's just that the engine is working this way, and he's not doing anything wrong.

A suggestion, because I'm certain that it will be hard to fix this minor annoyance, is to temporarily add a section to the manual on the FAQ.
Worked on Strangeland, Primordia, Hob's Barrow, The Cat Lady, Mage's Initiation, Until I Have You, Downfall, Hunie Pop, and every game in the Wadjet Eye Games catalogue (porting)

monkey0506

Well essentially you can name the cursor mode whatever you want. You can use it via the script however you would like. You can even name the event handler according to your own wishes by typing a name in yourself.

The only real issue here is that in the Events pane the list of available interactions is hard-coded and expects specific mouse modes to correspond to specific IDs. Because of this, you may have to link events in a way that may not visually make sense, though understanding what is happening internally of course it does.

So the problem is really just in relation to the Events pane because anywhere else you can use the names according to your own wishes.

SMF spam blocked by CleanTalk