04.11.2011, 11:12
For real...
I'll explain you the logic behind this
OnDialogResponse already exists in this script, so I don't have to check for its validity.
Edit:
* BigETI kisses on your forehead
This will indeed make the check faster!
I'll explain you the logic behind this
OnDialogResponse already exists in this script, so I don't have to check for its validity.
- IF any "dial_" callbacks doesnt't exists or returns 0 so Dial_OnDialogResponse will be called
- IF the Dial_OnDialogResponse exists and it returns 1, this callback won't get called in another scripts.
- IF Dial_OnDialogResponse doesn't exists, funcidx will return -1 and our callback is missing. returns zero also and will be called in another scripts to keep checking for any dialog response.
- Same for if Dial_OnDialogResponse exists and it returns simply 0, then it will be ofc called (same as above) in another scripts
Edit:
Quote:
Edit: Oh i didn't notice you have (DIAL_ODR != -1) there.
Anyway I think a better way to do it would save it in a boolean. pawn Код:
|
This will indeed make the check faster!