I'm at work, so I do not have my RPGMAKER XP system handy right now. However, I do not recall ever seeing a 'set_graphic' method within the Game_Actor class. So I would suggest looking for 'def set_graphic' within the default Game_Actor code. Chances are, you will need to do a 'little' bit more with this code.
The 'Interpreter' class does handle the code for changing Game_Event graphics, which even the Player is looked at as an event. The reason is that both the Game_Actor and Game_Event methods link to Game_Character which handles character graphics, speed and animation pattern.
Even so, it would likely NOT take effect immediately. Kid you not. But you were on the right track with $game_player.refresh. But you will need to refresh the Game Map with
$game_map.need_refresh = true... or just
$game_map.refresh
EDIT: Yeah, I re-read the request. You're not complaining about changing the hero or actor, but the EVENT graphic. Oookay.
Normally, you would change an event's graphic with the "MOVE ROUTE" event command. But you want it scripted. Well, events do not have 'Set Graphic' That would be too easy, wouldn't it? Well, the MOVE ROUTE command in the event list goes directly into the Game_Character class.
Ah, the quandry. You'd think you could edit $game_map.events[1] as an example to change the character graphic. But the Game_Character class set up the 'character_name' value to be a bit... stubborn. It can only allow changes within the class itself, and prevents anything like a script call from sending a character name graphic from outside the class. SO....
Add:
Code:
#==============================================================================
# ** Game_Character (part 1)
#------------------------------------------------------------------------------
# This class deals with characters. It's used as a superclass for the
# Game_Player and Game_Event classes.
#==============================================================================
class Game_Character
#--------------------------------------------------------------------------
# * Public Instance Variables
#--------------------------------------------------------------------------
attr_accessor :character_name # character file name
attr_accessor :character_hue # character hue
end
... Setting the character_name and character_hue values to the 'attr_accessor' attribute allows you more access. And since Game_Event is a 'child' class of Game_Character, the change made here will automatically affect Game_Event.
Okay, once that has been edited/added/whatever..... (I prefer not to directly edit the base original code)....
Code:
$game_map.events[1].character_name = "002-Fighter02"
That should work, even in an event's "Script Call". It did for me.