DERMA : 2 functions not wokring !

So I’m on developping a key configuration window for my bind system, however there are two functions that are disfunctional :

  • PANEL:OnKeyCodePressed(code) -> Returns a panel (userdata) in variable ‘code’ instead of a number !
  • PANEL:OnMousePressed(code) -> WTF !? Function not called !!! So impossible to tell what is not working on this function, because it does not get called !

In the hope of a quick answer,
Yuri6037

A peek at your code would be nice.

You don’t need any code, because when you attach this function to any dframe it does the same as I discribed even if you use DFrame instead of RRP_DFrame !

Then don’t ask for help? If you aren’t going to help us help you, then we can’t resolve your problem.

WTF !? You ask me to remove my topic when I have a problem !!! Are you crazy ?

How can i make you understand the problem is that the parameter keyCOde on the wiki isn’t a number but a panel !? Can you understand that ?!

Show your code. Why are you so defensive about some Derma?

There is no code to show I said !!!

That’s a problem with those functions that’s all !!

What code do you want to get when there isn’t any code to show you. The only code I have is part of a library that you haven’t my permission to see…

The only answer I have is part of a post you haven’t my permission to see…

If the first parameter is a panel then you’re defining your function wrong. You’re probably doing something like:



PANEL.OnKeyCodePressed = function(code) end


Either put self as the first argument or define the function with the object call operator (not sure what this is actually called)



function PANEL:OnKeyCodePressed(code)

end


Also don’t ask for help on your super secret derma thing if you’re not willing to help the people that want to help you understand.

Wow, finaly one who wanted to answer me. Anyway I thank you so much.
Now it’s on the OnMousePressed which is not called, I’m trying a hack workarround !

[editline]11th April 2015[/editline]

So I found a way to make OnMousePressed be working, however because you’re not realy heppy to help me, then for the first time I will not help future people who will read this topic by simply not giving the way…