View Single Post
  #1  
Old 09-08-2017, 07:55 PM
maximus_asinus maximus_asinus is offline
RIP DarkCloud_PK
Join Date: Oct 2001
Location: Canada
Posts: 3,743
maximus_asinus has a reputation beyond reputemaximus_asinus has a reputation beyond reputemaximus_asinus has a reputation beyond reputemaximus_asinus has a reputation beyond reputemaximus_asinus has a reputation beyond reputemaximus_asinus has a reputation beyond reputemaximus_asinus has a reputation beyond reputemaximus_asinus has a reputation beyond reputemaximus_asinus has a reputation beyond reputemaximus_asinus has a reputation beyond repute
properly destroying GUI controls?

I'm currently having issues with a custom sign system I am creating. I think the bug exists because the GUI controls aren't being destroyed properly (working theory for right now). This is how I am destroying the controls:

PHP Code:
function DestroyGUI() {
  
hideimg(200);
  
first_object.destroy();
  
second_object.destroy(); 

Both are GuiBitmapCtrl controls which contain other controls. And this seems to work fine when you interact with one sign, but once you touch a second sign the F2 log starts throwing errors.

Quote:
Script: Function first_object.destroy not found in function DestroyGUI of maximus_debug in script of Sign (in level maximus_asinus_test_03.nw at pos (44, 14))

Script: Function second_object.destroy not found in function DestroyGUI of maximus_debug in script of Sign (in level maximus_asinus_test_03.nw at pos (41, 14))
Once this starts to happen the sign starts pulling text from the other sign. I've read through the wiki about a dozen times now, and I still don't understand what I'm doing wrong.
__________________
Save Classic!
Reply With Quote