| 09-12-2009, 12:24 PM | #1 |
This is the problem: JASS:struct door method open takes nothing returns nothing // opens the door endmethod endstruct struct room door frontdoor door backdoor method someGuyEntersOrLeavesTheRoom takes nothing returns nothing /* I need to know when any of those doors are opened; I need to know when either frontdoor.open() or backdoor.open() is called. */ endmethod endstruct I need to do some stuff in that open method that somehow get that someGuyEntersOrLeavesTheRoom thingy called in correct room instance. Can someone help me with this problem? |
| 09-12-2009, 12:29 PM | #2 |
Add a room member in struct door, so the door knows which room it is part of... |
| 09-12-2009, 12:45 PM | #3 |
Awesome, I try it, thanks |
