Please login or register.

Login with username, password and session length
Advanced search  

News:

Latest WME version: WME 1.9.1 (January 1st, 2010) - download

Author Topic: Question - LeftClick sensitive cursor  (Read 2865 times)

0 Members and 1 Guest are viewing this topic.

BlueNomad

  • Lurker
  • *
  • Karma: 0
  • Offline Offline
  • Posts: 8
    • View Profile
Question - LeftClick sensitive cursor
« on: July 29, 2009, 12:06:14 PM »

Hi,

can you help me with some advice to, how to write code for LeftClick sensitive cursor.

Exploration:

1. I have normal cursor sprite
2. I need change cursor sprite when I press down LeftClick on some object, area (table, ..)
3. when I pull up LeftClick, than set normal cursor sprite, how before
3. through "Game.SetCursor();" isn`t  work   <---- this change cursor permanently

Example:
I have a horse and when I click on it with normal cursor (whip), I need change this cursor over whip with slap animated cursor. When I stop  LeftClick, than back normal cursor.

Thank you for advice!
Logged

Jyujinkai

  • Global Moderator
  • Frequent poster
  • *
  • Karma: 1
  • Offline Offline
  • Posts: 352
    • View Profile
    • Jyujinkai's WME Development Blog
Re: Question - LeftClick sensitive cursor
« Reply #1 on: July 29, 2009, 01:55:50 PM »

Exploration:

1. I have normal cursor sprite
2. I need change cursor sprite when I press down LeftClick on some object, area (table, ..)
3. when I pull up LeftClick, than set normal cursor sprite, how before
3. through "Game.SetCursor();" isn`t  work   <---- this change cursor permanently

Example:
I have a horse and when I click on it with normal cursor (whip), I need change this cursor over whip with slap animated cursor. When I stop  LeftClick, than back normal cursor.

context sensitive cursors are built into the default way the cursors.

If I understand you correctly you can set any object or region or w/e in wme to load a new cursor when you hover over it.....

So you have a horse... when you hover over it it changes to animated cursor, when you un hover it changes to non-animated.
You hover over the horse whip... the cursor changes to a animated "grab" icon" you un-hover back to normal pointer, left click to pick up the horse whip.

This is all done in the scene editor each element or layer or w/e the fuck they are called has a option for a cursor override. Where on hover a new cursor will be shown.. this of course can be a scripted to load many cursors if you like context sensitive.. like say hover over the horse... and you get a icon to pat it, but if you have a whip in your inventory (the script checks this) it shows the animated whipping icon.... if that makes sense.

So if you do your context sensitive stuff right you should get a way withy doing this as you want... assuming I understand you...

hmmm

Ok I just re-read your post again .....

If you change your icons with left click, (eg: talk, push, walk, molest) you can use the scripting on the layers in scene edit to change them into animated versions as they go over the hotspot...
Logged
<Antoine de Saint-Exupéry> In any thing at all, perfection is finally attained not when there is no longer anything to add, but when there is no longer anything to take away...
<Carl Sagan> If you want to make a apple pie from scratch. You must first... invent the universe
 

Page created in 0.036 seconds with 20 queries.