mirror of
https://github.com/veekun/pokedex.git
synced 2024-08-20 18:16:34 +00:00
Add foreign names to the database.
Most names as ripped from HeartGold or SoulSilver. Gen-III-only names ripped from Emerald and de-allcapsed; for French, I also judged where accents belong on newly-lowercase letters. A couple of them might have mistakes.
This commit is contained in:
parent
12aaf06359
commit
8ef8c3a915
2 changed files with 2820 additions and 0 deletions
2811
pokedex/data/csv/item_names.csv
Normal file
2811
pokedex/data/csv/item_names.csv
Normal file
File diff suppressed because it is too large
Load diff
|
@ -254,6 +254,12 @@ class ItemInternalID(TableBase):
|
||||||
generation_id = Column(Integer, ForeignKey('generations.id'), primary_key=True, autoincrement=False, nullable=False)
|
generation_id = Column(Integer, ForeignKey('generations.id'), primary_key=True, autoincrement=False, nullable=False)
|
||||||
internal_id = Column(Integer, nullable=False)
|
internal_id = Column(Integer, nullable=False)
|
||||||
|
|
||||||
|
class ItemName(TableBase):
|
||||||
|
__tablename__ = 'item_names'
|
||||||
|
item_id = Column(Integer, ForeignKey('items.id'), primary_key=True, nullable=False, autoincrement=False)
|
||||||
|
language_id = Column(Integer, ForeignKey('languages.id'), primary_key=True, nullable=False, autoincrement=False)
|
||||||
|
name = Column(Unicode(16), nullable=False)
|
||||||
|
|
||||||
class ItemPocket(TableBase):
|
class ItemPocket(TableBase):
|
||||||
__tablename__ = 'item_pockets'
|
__tablename__ = 'item_pockets'
|
||||||
id = Column(Integer, primary_key=True, nullable=False)
|
id = Column(Integer, primary_key=True, nullable=False)
|
||||||
|
@ -747,6 +753,7 @@ Item.berry = relation(Berry, uselist=False, backref='item')
|
||||||
Item.flags = relation(ItemFlag, secondary=ItemFlagMap.__table__)
|
Item.flags = relation(ItemFlag, secondary=ItemFlagMap.__table__)
|
||||||
Item.flavor_text = relation(ItemFlavorText, order_by=ItemFlavorText.version_group_id.asc(), backref='item')
|
Item.flavor_text = relation(ItemFlavorText, order_by=ItemFlavorText.version_group_id.asc(), backref='item')
|
||||||
Item.fling_effect = relation(ItemFlingEffect, backref='items')
|
Item.fling_effect = relation(ItemFlingEffect, backref='items')
|
||||||
|
Item.foreign_names = relation(ItemName, backref='item')
|
||||||
Item.machines = relation(Machine, order_by=Machine.version_group_id.asc())
|
Item.machines = relation(Machine, order_by=Machine.version_group_id.asc())
|
||||||
Item.category = relation(ItemCategory)
|
Item.category = relation(ItemCategory)
|
||||||
Item.pocket = association_proxy('category', 'pocket')
|
Item.pocket = association_proxy('category', 'pocket')
|
||||||
|
@ -756,6 +763,8 @@ ItemCategory.pocket = relation(ItemPocket)
|
||||||
|
|
||||||
ItemFlavorText.version_group = relation(VersionGroup)
|
ItemFlavorText.version_group = relation(VersionGroup)
|
||||||
|
|
||||||
|
ItemName.language = relation(Language)
|
||||||
|
|
||||||
ItemPocket.categories = relation(ItemCategory, order_by=ItemCategory.name)
|
ItemPocket.categories = relation(ItemCategory, order_by=ItemCategory.name)
|
||||||
|
|
||||||
Location.region = relation(Region, backref='locations')
|
Location.region = relation(Region, backref='locations')
|
||||||
|
|
Loading…
Reference in a new issue