Class: UI::QuestInformer

Inherits:
SpriteStack show all
Defined in:
docs/01450_Systems_08000_Quest.rb

Overview

UI element shown on the screen to inform the player a quest was started, failed or finished

Constant Summary collapse

ME_TO_PLAY =

Name of the ME to play

'audio/me/rosa_keyitemobtained'
BASE_Y =

Base Y of the informer

34
OFFSET_Y =

Offset Y between each informer

24
OFFSET_TEXT_X =

Offset X between the two textes

4
TRANSITION_LENGHT =

Lenght of a transition

30
TEXT_MOVE_LENGHT =

Lenght of the text move

30
TEXT_REMAIN_LENGHT =

Time the player has to read the text

90

Constants inherited from SpriteStack

SpriteStack::NO_INITIAL_IMAGE

Instance Attribute Summary

Attributes inherited from SpriteStack

#animated, #data, #moving, #stack, #viewport, #x, #y

Instance Method Summary collapse

Methods inherited from SpriteStack

#[], #add_background, #add_line, #add_text, #anime, #anime_delta_set, #dispose, #each, #execute_anime, #move, #move_to, #opacity, #opacity=, #push, #push_sprite, #set_origin, #set_position, #simple_mouse_in?, #size, #stop_animation, #translate_mouse_coords, #update_animation, #update_position, #visible, #visible=, #with_cache, #with_font, #with_surface, #z, #z=

Constructor Details

#initialize(viewport, name, quest_status, index) ⇒ QuestInformer

Create a new quest informer UI

Parameters:

  • viewport (Viewport)
  • name (String)

    Name of the quest

  • quest_status (Symbol)

    status of quest (:new, :completed, :failed)

  • index (Integer)

    index of the quest



800
801
# File 'docs/01450_Systems_08000_Quest.rb', line 800

def initialize(viewport, name, quest_status, index)
end

Instance Method Details

#done?Boolean

Tell if the animation is finished

Returns:

  • (Boolean)


806
807
# File 'docs/01450_Systems_08000_Quest.rb', line 806

def done?
end

#update

Update the animation for the quest informer



803
804
# File 'docs/01450_Systems_08000_Quest.rb', line 803

def update
end