forked from pyfa-org/Pyfa
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'master' into crowdin_master
- Loading branch information
Showing
526 changed files
with
396,629 additions
and
267,274 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
""" | ||
Migration 45 | ||
- Drone mutaplasmid support | ||
""" | ||
|
||
import sqlalchemy | ||
|
||
|
||
def upgrade(saveddata_engine): | ||
try: | ||
saveddata_engine.execute("SELECT baseItemID FROM drones LIMIT 1") | ||
except sqlalchemy.exc.DatabaseError: | ||
saveddata_engine.execute("ALTER TABLE drones ADD COLUMN baseItemID INTEGER;") | ||
try: | ||
saveddata_engine.execute("SELECT mutaplasmidID FROM drones LIMIT 1") | ||
except sqlalchemy.exc.DatabaseError: | ||
saveddata_engine.execute("ALTER TABLE drones ADD COLUMN mutaplasmidID INTEGER;") |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,68 @@ | ||
""" | ||
Migration 46 | ||
- Mining crystal changes | ||
""" | ||
|
||
CONVERSIONS = { | ||
60276: ( # Simple Asteroid Mining Crystal Type A I | ||
18066, # Veldspar Mining Crystal I | ||
18062, # Scordite Mining Crystal I | ||
18060, # Pyroxeres Mining Crystal I | ||
18058, # Plagioclase Mining Crystal I | ||
), | ||
60281: ( # Simple Asteroid Mining Crystal Type A II | ||
18618, # Veldspar Mining Crystal II | ||
18616, # Scordite Mining Crystal II | ||
18614, # Pyroxeres Mining Crystal II | ||
18612, # Plagioclase Mining Crystal II | ||
), | ||
60285: ( # Coherent Asteroid Mining Crystal Type A I | ||
18056, # Omber Mining Crystal I | ||
18052, # Kernite Mining Crystal I | ||
18050, # Jaspet Mining Crystal I | ||
18048, # Hemorphite Mining Crystal I | ||
18046, # Hedbergite Mining Crystal I | ||
), | ||
60288: ( # Coherent Asteroid Mining Crystal Type A II | ||
18610, # Omber Mining Crystal II | ||
18604, # Jaspet Mining Crystal II | ||
18606, # Kernite Mining Crystal II | ||
18600, # Hedbergite Mining Crystal II | ||
18602, # Hemorphite Mining Crystal II | ||
), | ||
60291: ( # Variegated Asteroid Mining Crystal Type A I | ||
18044, # Gneiss Mining Crystal I | ||
18042, # Dark Ochre Mining Crystal I | ||
18040, # Crokite Mining Crystal I | ||
), | ||
60294: ( # Variegated Asteroid Mining Crystal Type A II | ||
18598, # Gneiss Mining Crystal II | ||
18596, # Dark Ochre Mining Crystal II | ||
18594, # Crokite Mining Crystal II | ||
), | ||
60297: ( # Complex Asteroid Mining Crystal Type A I | ||
18038, # Bistot Mining Crystal I | ||
18036, # Arkonor Mining Crystal I | ||
18064, # Spodumain Mining Crystal I | ||
), | ||
60300: ( # Complex Asteroid Mining Crystal Type A II | ||
18592, # Bistot Mining Crystal II | ||
18590, # Arkonor Mining Crystal II | ||
18624, # Spodumain Mining Crystal II | ||
), | ||
} | ||
|
||
|
||
def upgrade(saveddata_engine): | ||
# Convert modules | ||
for replacement_item, list in CONVERSIONS.items(): | ||
for retired_item in list: | ||
saveddata_engine.execute('UPDATE "modules" SET "itemID" = ? WHERE "itemID" = ?', | ||
(replacement_item, retired_item)) | ||
saveddata_engine.execute('UPDATE "modules" SET "baseItemID" = ? WHERE "baseItemID" = ?', | ||
(replacement_item, retired_item)) | ||
saveddata_engine.execute('UPDATE "modules" SET "chargeID" = ? WHERE "chargeID" = ?', | ||
(replacement_item, retired_item)) | ||
saveddata_engine.execute('UPDATE "cargo" SET "itemID" = ? WHERE "itemID" = ?', | ||
(replacement_item, retired_item)) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,8 @@ | ||
__all__ = [ | ||
"character", | ||
"fit", | ||
"mutator", | ||
"mutatorMod", | ||
"mutatorDrone", | ||
"module", | ||
"user", | ||
"skill", | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,36 @@ | ||
# =============================================================================== | ||
# Copyright (C) 2010 Diego Duclos | ||
# | ||
# This file is part of eos. | ||
# | ||
# eos is free software: you can redistribute it and/or modify | ||
# it under the terms of the GNU Lesser General Public License as published by | ||
# the Free Software Foundation, either version 2 of the License, or | ||
# (at your option) any later version. | ||
# | ||
# eos 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 Lesser General Public License for more details. | ||
# | ||
# You should have received a copy of the GNU Lesser General Public License | ||
# along with eos. If not, see <http://www.gnu.org/licenses/>. | ||
# =============================================================================== | ||
|
||
import datetime | ||
|
||
from sqlalchemy import Column, DateTime, Float, ForeignKey, Integer, Table | ||
from sqlalchemy.orm import mapper | ||
|
||
from eos.db import saveddata_meta | ||
from eos.saveddata.mutator import MutatorModule | ||
|
||
mutatorMods_table = Table( | ||
"mutators", saveddata_meta, | ||
Column("moduleID", Integer, ForeignKey("modules.ID"), primary_key=True, index=True), | ||
Column("attrID", Integer, primary_key=True, index=True), | ||
Column("value", Float, nullable=False), | ||
Column("created", DateTime, nullable=True, default=datetime.datetime.now), | ||
Column("modified", DateTime, nullable=True, onupdate=datetime.datetime.now)) | ||
|
||
mapper(MutatorModule, mutatorMods_table) |
Oops, something went wrong.