# Path: scene_info.py
# class SceneInfo():
#   def __init__(self,
#                file_id    = -1,
#                speaker    = -1,
#                speaking   = False,
#                sprite     = SpriteId(),
#                voice      = VoiceId(),
#                bgm        = -1,
#                headshot   = -1,
#                mode       = None,
#                special    = None,
#                box_color  = common.BOX_COLORS.orange,
#                box_type   = common.BOX_TYPES.normal,
#                ammo       = -1,
#                bgd        = -1,
#                cutin      = -1,
#                flash      = -1,
#                movie      = -1,
#                img_filter = IMG_FILTERS.unfiltered,
#                chapter    = -1,
#                scene      = -1,
#                room       = -1,
#                extra_val  = -1
#               ):
#     self.file_id    = file_id
#     
#     self.speaker    = speaker
#     self.speaking   = speaking
#     self.sprite     = sprite
#     self.voice      = voice
#     self.bgm        = bgm
#     
#     self.headshot   = headshot
#     
#     self.mode       = mode
#     self.special    = special
#     self.box_color  = box_color
#     self.box_type   = box_type
#     
#     self.ammo       = ammo
#     self.bgd        = bgd
#     self.cutin      = cutin
#     self.flash      = flash
#     self.movie      = movie
#     
#     self.img_filter = img_filter
#     
#     self.chapter    = chapter
#     self.scene      = scene
#     self.room       = room
#     
#     self.extra_val  = extra_val
# 
# Path: text_printer.py
# IMG_FILTERS  = Enum("unfiltered", "sepia", "inverted")
# 
# Path: voice.py
# class VoiceId():
#   def __init__(
#     self,
#     char_id = -1,
#     chapter = -1,
#     voice_id = -1
#   ):
#     self.char_id  = char_id
#     self.chapter  = chapter
#     self.voice_id = voice_id


import common
from scene_info import SceneInfo
from sprite import SpriteId, SPRITE_TYPE
from text_printer import IMG_FILTERS
from voice import VoiceId
from wrd.ops import *
### Copyright © 2012-2013 BlackDragonHunt
### 
### This file is part of the Super Duper Script Editor.
### 
### The Super Duper Script Editor is free software: you can redistribute it
### and/or modify it under the terms of the GNU General Public License as
### published by the Free Software Foundation, either version 3 of the License,
### or (at your option) any later version.
### 
### The Super Duper Script Editor is distributed in the hope that it will be
### useful, but WITHOUT ANY WARRANTY; without even the implied warranty of
### MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
### GNU General Public License for more details.
### 
### You should have received a copy of the GNU General Public License
### along with the Super Duper Script Editor.
### If not, see <http://www.gnu.org/licenses/>.
################################################################################



##############################################################################
### Converts the parsed wrd file into a list of SceneInfo objects for use
### in the editor
##############################################################################
def to_scene_info(commands):
  
  cur_speaker     = 0x1F
  cur_sprite      = SpriteId()
  last_sprite     = -1

# Path: scene_info.py
# class SceneInfo():
#   def __init__(self,
#                file_id    = -1,
#                speaker    = -1,
#                speaking   = False,
#                sprite     = SpriteId(),
#                voice      = VoiceId(),
#                bgm        = -1,
#                headshot   = -1,
#                mode       = None,
#                special    = None,
#                box_color  = common.BOX_COLORS.orange,
#                box_type   = common.BOX_TYPES.normal,
#                ammo       = -1,
#                bgd        = -1,
#                cutin      = -1,
#                flash      = -1,
#                movie      = -1,
#                img_filter = IMG_FILTERS.unfiltered,
#                chapter    = -1,
#                scene      = -1,
#                room       = -1,
#                extra_val  = -1
#               ):
#     self.file_id    = file_id
#     
#     self.speaker    = speaker
#     self.speaking   = speaking
#     self.sprite     = sprite
#     self.voice      = voice
#     self.bgm        = bgm
#     
#     self.headshot   = headshot
#     
#     self.mode       = mode
#     self.special    = special
#     self.box_color  = box_color
#     self.box_type   = box_type
#     
#     self.ammo       = ammo
#     self.bgd        = bgd
#     self.cutin      = cutin
#     self.flash      = flash
#     self.movie      = movie
#     
#     self.img_filter = img_filter
#     
#     self.chapter    = chapter
#     self.scene      = scene
#     self.room       = room
#     
#     self.extra_val  = extra_val
# 
# Path: text_printer.py
# IMG_FILTERS  = Enum("unfiltered", "sepia", "inverted")
# 
# Path: voice.py
# class VoiceId():
#   def __init__(
#     self,
#     char_id = -1,
#     chapter = -1,
#     voice_id = -1
#   ):
#     self.char_id  = char_id
#     self.chapter  = chapter
#     self.voice_id = voice_id


# Path: wrd/scene.py
import common
from scene_info import SceneInfo
from sprite import SpriteId, SPRITE_TYPE
from text_printer import IMG_FILTERS
from voice import VoiceId
from wrd.ops import *

### Copyright © 2012-2013 BlackDragonHunt
### 
### This file is part of the Super Duper Script Editor.
### 
### The Super Duper Script Editor is free software: you can redistribute it
### and/or modify it under the terms of the GNU General Public License as
### published by the Free Software Foundation, either version 3 of the License,
### or (at your option) any later version.
### 
### The Super Duper Script Editor is distributed in the hope that it will be
### useful, but WITHOUT ANY WARRANTY; without even the implied warranty of
### MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
### GNU General Public License for more details.
### 
### You should have received a copy of the GNU General Public License
### along with the Super Duper Script Editor.
### If not, see <http://www.gnu.org/licenses/>.
################################################################################



##############################################################################
### Converts the parsed wrd file into a list of SceneInfo objects for use
### in the editor
##############################################################################
def to_scene_info(commands):
  
  cur_speaker     = 0x1F
  cur_sprite      = SpriteId()
  last_sprite     = -1

  cur_voice       = VoiceId()