Mr.Trivel Animated Faces (V1.2) Line 97 Argument Error On Level Up

So, I went to test this script to see if it worked in battle(it does!) but when my character leveled up, it crashes. Tried it with numerous levels, 1 to 2, 40 to 41, and 98 to 99...
It says "Script 'Mr. Trivel Animated Faces' line 97: ArgumentError occurred.
wrong number of arguments (0 for 2)"


"Refresh" is line 97. I'm no coder/programmer by any means, but shouldn't there be an 'else' in this somewhere? I have no idea what refresh does... Extreme noob here.
If someone could help me fix this, I would greatly appreciate it!


# )--------------------------------------------------------------------------(
# )-- Alias: update --(
# )--------------------------------------------------------------------------(
def update
finish = Time.now
@elapsed_time += ms(@time_now, finish)
mrts_face_anims_update
if @animated_actors && @elapsed_time >= FRAME_SPEED && Time.now.to_f != @time_now
@actor_hash.each { |k, v|
next unless @actor_hash[k]
@actor_hash[k] += 1
@actor_hash[k] = 0 if @actor_hash[k] > DATA[k][1].size-1
}
refresh
@elapsed_time = 0
end
@time_now = Time.now
end




Edit really fast:
I apologize if this is in the wrong section. It's an issue with a script, so I attempted to get it to the right section of the forums.
I've moved this thread to RGSSx Script Support . Please be sure to post your threads in the correct forum next time. Thank you.
Shameless self-bump.
You should give a link to the script in question. 


The error you got means that the method refresh in that class expects 2 arguments, yet none has been provided.


Either one of your other scripts rewrite that refresh method with 2 arguments, or Mr.Trivel's script misses these arguments.

Spoiler
But why do you bump when not even 10 hours has been passed since you posted the topic? 😳


What is even the point of bumping a topic if it's still on page 1?
You should give a link to the script in question. 


The error you got means that the method refresh in that class expects 2 arguments, yet none has been provided.


Either one of your other scripts rewrite that refresh method with 2 arguments, or Mr.Trivel's script misses these arguments.

Spoiler
But why do you bump when not even 10 hours has been passed since you posted the topic? 😳


What is even the point of bumping a topic if it's still on page 1?

Here's the link:
http://www.rpgmakercentral.com/topic/27001-animated-faces/


My browser messes up a lot(I'm using Edge) and for some reason a lot of my threads don't show up in the forum list for me. That's totally my fault... I apologize.
None of the RTP window classes have a refresh method that takes any arguments.  This means you must have another script that's some kind of window, that has a refresh method that requires two arguments.


Do a global search (open your script list and press Control+Shift+F) for def refresh and see what sorts of window classes come up that have arguments after the method name.
None of the RTP window classes have a refresh method that takes any arguments.  This means you must have another script that's some kind of window, that has a refresh method that requires two arguments.


Do a global search (open your script list and press Control+Shift+F) for def refresh and see what sorts of window classes come up that have arguments after the method name.

These are them.
I have a lot... So I'm not sure if you guys are able to help or not due to the list, but even if you can tell me what to look for, that'd be amazing.


Also, on a somewhat related note, I didn't know that search feature existed.


Screenshot_120.png


Screenshot_121.png


Screenshot_122.png


Screenshot_123.png
It is Yanfly's Victory Aftermath script, the level up windows are the only ones using 2 arguments.


Try this snippet:

Spoiler
class Window_VictoryLevelUp < Window_Base

def refresh(actor=nil, temp_actor=nil)
if actor && @actor != actor
YEA::VICTORY_AFTERMATH::LEVEL_SOUND.play
end
@actor = actor if actor
@temp_actor = temp_actor if temp_actor
contents.clear
reset_font_settings
draw_actor_changes(@actor, @temp_actor)
end

end

class Window_VictorySkills < Window_Selectable

def refresh(actor=nil, temp_actor=nil)
@actor = actor if actor
@temp_actor = temp_actor if temp_actor
contents.clear
if @actor.skills.size == @temp_actor.skills.size
unselect
@data = []
create_contents
return
end
@data = @actor.skills - @temp_actor.skills
if @data.size > 8
select(0)
activate
else
unselect
deactivate
end
create_contents
draw_all_items
end

end



Place it below Yanfly's Victory Aftermath.


It should fix the error you get. 
It is Yanfly's Victory Aftermath script, the level up windows are the only ones using 2 arguments.


Try this snippet:

Spoiler
class Window_VictoryLevelUp < Window_Base

def refresh(actor=nil, temp_actor=nil)
if actor && @actor != actor
YEA::VICTORY_AFTERMATH::LEVEL_SOUND.play
end
@actor = actor if actor
@temp_actor = temp_actor if temp_actor
contents.clear
reset_font_settings
draw_actor_changes(@actor, @temp_actor)
end

end

class Window_VictorySkills < Window_Selectable

def refresh(actor=nil, temp_actor=nil)
@actor = actor if actor
@temp_actor = temp_actor if temp_actor
contents.clear
if @actor.skills.size == @temp_actor.skills.size
unselect
@data = []
create_contents
return
end
@data = @actor.skills - @temp_actor.skills
if @data.size > 8
select(0)
activate
else
unselect
deactivate
end
create_contents
draw_all_items
end

end



Place it below Yanfly's Victory Aftermath.


It should fix the error you get. 

That fixed it. Thank you for this.
No idea how you were able to put that together so quickly with simple screen shots of a list... But that's seriously amazing.

Original thread: https://forums.rpgmakerweb.com/threads/mr-trivel-animated-faces-v1-2-line-97-argument-error-on-level-up.71008/