RE: "Wait" in the script - DerVVulfman - 03-08-2020
Hey, birthday dude... Throw the wolf a bone here.
I'm trying to figure out how to trigger the @od_text condition, so post a sample 'Show Text' message string that would trigger it...
You know, like Show Text : ' \c[2]This is one color.\c[1]And this is another.'
Giving me an example message that is meant to trigger your add-on should help.
RE: "Wait" in the script - Whisper - 04-28-2020
(03-08-2020, 04:08 AM)DerVVulfman Wrote: Hey, birthday dude... Throw the wolf a bone here.
I'm trying to figure out how to trigger the @od_text condition, so post a sample 'Show Text' message string that would trigger it...
You know, like Show Text : ' \c[2]This is one color.\c[1]And this is another.'
Giving me an example message that is meant to trigger your add-on should help.
Wow, sorry, I though that topic is dead. You're just simply starting with "\od" and then whatever you want. Message will just appear is a specific way. Here, I made simple "demo" of that. Like "\dShow this message".
https://send.firefox.com/download/32c706429239e7b6/#_LB0wjYwZc0CRBbEKtQoPg
RE: "Wait" in the script - DerVVulfman - 04-28-2020
Now I gotta find my project (somewhere..... over the rainbowwwww♫♪♫ )
Hm. 73Meg. I should point out that I am still the DIALUP AOL king around here. That will take me ages. ... without going to the library anyway.
EDIT: I kinda got .... something... but....
Let's assume the code you added to the Window_Message was this (copied from your first post):
Code: if @od_text
$game_player.animation_id = 5
@oo_box = Window_MessageOoBox.new(x, y - 16, " Given ")
@oo_box.back.opacity = 0 if $game_system.message_frame == 1
@oo_box.z = self.z
@od_text = nil
end
Mind you, this begins execution when you start the message dialog... And I see you had it in the script, and with an extra $game_switches condition, so I'll use that in my edit...
Now let's assume I did some minor edits like...
Code: if @od_text
if $game_switches[1703] == false
$game_player.animation_id = 5
@meebie_wait = 20
end
@oo_box = Window_MessageOoBox.new(x, y - 16, " Oddano ")
@oo_box.back.opacity = 0 if $game_system.message_frame == 1
@oo_box.z = self.z
@od_text = nil
$game_switches[1703] = false
end
And let's assume I added a bit MORE to the Window_Message class that you edited...
In the below code, made as a standalone... to paste below your "Scrolling MS EXX" script:
Code: class Window_Message < Window_Selectable
alias oooanimdelay_update update
#--------------------------------------------------------------------------
# * Frame Update
#--------------------------------------------------------------------------
def update
# Only perform if we do have a wait
unless @meebie_wait.nil?
# If the wait is greater than 0
if @meebie_wait > 0
# Reduce the count
@meebie_wait -= 1
# Update the graphics count
Graphics.update
# Exit and don't do any more message content until count is done
return
end
end
# Perform the original call
oooanimdelay_update
end
end
Now it DOES create a delay of sorts.
FIRST THING that does happen is that your message window is created. The shape and size is positioned, and the "Oddano" or "Given" box does appear centered along the top. The message itself is not present, but the message window itself is there. This should be expected as the command is created within the message window, and thus the window IS created by the time the animation is triggered.
SECOND THING that happens, is the Animation!!!!! And the creation of a delay of approximately 20 frames!!! Yeah, a variable name of @meebie_wait is odd, but it's just me typing stupid letters fast. BUT... it does create a delay!
THIRD THING that happens is in the UPDATE method I supplied above. IF there is a valid @meebie_wait value, and IF that value is above 0 (Zero), it runs the graphics update and cycles down until the value reaches 0! But as long as the @meebie_wait is above 0, it exits and doesn't perform the rest of the message window's update!
FOURTH THING that happens is that WHEN the @meebie_wait value finally reaches 0, it renders the rest of the message!
So yeah, I got the delay functional. But as long as the command to generate the animation is built into the Message Window, the message window itself will appear when the animation is performed, even though the actual text won't show until the delay is over.
RE: "Wait" in the script - Whisper - 04-28-2020
(04-28-2020, 03:14 AM)DerVVulfman Wrote: Now I gotta find my project (somewhere..... over the rainbowwwww♫♪♫ )
Hm. 73Meg. I should point out that I am still the DIALUP AOL king around here. That will take me ages. ... without going to the library anyway.
EDIT: I kinda got .... something... but....
Let's assume the code you added to the Window_Message was this (copied from your first post):
Code: if @od_text
$game_player.animation_id = 5
@oo_box = Window_MessageOoBox.new(x, y - 16, " Given ")
@oo_box.back.opacity = 0 if $game_system.message_frame == 1
@oo_box.z = self.z
@od_text = nil
end
Mind you, this begins execution when you start the message dialog... And I see you had it in the script, and with an extra $game_switches condition, so I'll use that in my edit...
Now let's assume I did some minor edits like...
Code: if @od_text
if $game_switches[1703] == false
$game_player.animation_id = 5
@meebie_wait = 20
end
@oo_box = Window_MessageOoBox.new(x, y - 16, " Oddano ")
@oo_box.back.opacity = 0 if $game_system.message_frame == 1
@oo_box.z = self.z
@od_text = nil
$game_switches[1703] = false
end
And let's assume I added a bit MORE to the Window_Message class that you edited...
In the below code, made as a standalone... to paste below your "Scrolling MS EXX" script:
Code: class Window_Message < Window_Selectable
alias oooanimdelay_update update
#--------------------------------------------------------------------------
# * Frame Update
#--------------------------------------------------------------------------
def update
# Only perform if we do have a wait
unless @meebie_wait.nil?
# If the wait is greater than 0
if @meebie_wait > 0
# Reduce the count
@meebie_wait -= 1
# Update the graphics count
Graphics.update
# Exit and don't do any more message content until count is done
return
end
end
# Perform the original call
oooanimdelay_update
end
end
Now it DOES create a delay of sorts.
FIRST THING that does happen is that your message window is created. The shape and size is positioned, and the "Oddano" or "Given" box does appear centered along the top. The message itself is not present, but the message window itself is there. This should be expected as the command is created within the message window, and thus the window IS created by the time the animation is triggered.
SECOND THING that happens, is the Animation!!!!! And the creation of a delay of approximately 20 frames!!! Yeah, a variable name of @meebie_wait is odd, but it's just me typing stupid letters fast. BUT... it does create a delay!
THIRD THING that happens is in the UPDATE method I supplied above. IF there is a valid @meebie_wait value, and IF that value is above 0 (Zero), it runs the graphics update and cycles down until the value reaches 0! But as long as the @meebie_wait is above 0, it exits and doesn't perform the rest of the message window's update!
FOURTH THING that happens is that WHEN the @meebie_wait value finally reaches 0, it renders the rest of the message!
So yeah, I got the delay functional. But as long as the command to generate the animation is built into the Message Window, the message window itself will appear when the animation is performed, even though the actual text won't show until the delay is over.
AMAZING! Thank you so much!
|