Game Development Reference
In-Depth Information
10. Then, we call
element.show()
and increase
messageIndex
for the next
message.
11. The second method we create is
removeMessage
. It takes a string called
id
as
the input.
12. Inside this, we use
screen.findElementByName
to find the message, and
call
hide
.
13. While doing this, we supply a new
EndNotify
object, which in its
perform
message should call
markForRemoval()
on the message and also
lay-
outElements()
on the parent
messageQueue
control.