HomeUser Control Panel (unavailable in archive)ForumsTutorialsArt GalleryResourcesMaps

Some Questions about Dialogs

10-22-2007, 02:46 PM#1
Deaod
Hi there,

i wanted to ask you some things concerning dialogs:

Is there a way to get the player clicking on a button in a dialog?

I found an eventid named "dialogevent", but the only events used are 90 and 91, so what are the others for?

Thanks in advance,

Deaod
10-22-2007, 04:57 PM#2
TaintedReality
GetTriggerPlayer?
10-22-2007, 05:03 PM#3
Deaod
I am not sure if this will work.
Besides I don't like that one, any other idea?
10-22-2007, 06:26 PM#4
Alexander244
Quote:
Originally Posted by Deaod
I found an eventid named "dialogevent", but the only events used are 90 and 91, so what are the others for?

Those are the only two dialog events. They are a subset of "Game, Player and Unit Events", which is why they are 91 and 92 and not 0 and 1.

Quote:
Originally Posted by Deaod
Besides I don't like that one, any other idea?

What is wrong with GetTriggerPlayer()?
10-22-2007, 06:43 PM#5
cohadar
Quote:
Originally Posted by Deaod
I am not sure if this will work.
Besides I don't like that one, any other idea?

I have one:
Collapse JASS:
function GetPlayerWhoClickedOnDialogBJ takes nothing returns player
    return GetTriggerPlayer()
endfunction

...but you must give me credit if you use it in your map.
10-22-2007, 06:48 PM#6
Deaod
maybe I mixed that up with GetTriggerUnit()
i doubt this will work because there because there is no sign, of a player detected in the Register function.

Edit: Thanks for that great help, cohadar. Be asure I'll mention you in the credits if I use it.
10-22-2007, 07:32 PM#7
cohadar
I think I will submit that function to resource section,
there might be other people who need it.
10-22-2007, 08:05 PM#8
Deaod
yes, please do so. I think this will help a _lot_. ;)
10-22-2007, 10:30 PM#9
Ammorth
I'm not sure if he is being sarcastic or not...
10-22-2007, 10:34 PM#10
TaintedReality
He gave me some rep, so I think he is :). I was going to cry if he was serious.