-
Notifications
You must be signed in to change notification settings - Fork 53
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Added support for Epitaph Road endgame content. - Implemented the personal quest to enter "Heroic Spirit Sleeping Path: Rathnite Foothills". - Implemented Section 1 for Rathnite Foothills - Implemented Section 2 for Rathnite Foothills - Created new epitaph assets which describe the different paths, sections and trials. - Implemented multiple packet handlers for different season dungeon packets.
- Loading branch information
1 parent
ef817d2
commit 3f2e4af
Showing
192 changed files
with
82,106 additions
and
79,846 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
13 changes: 13 additions & 0 deletions
13
Arrowgene.Ddon.Database/Files/Database/Script/migration_epitaph_road.sql
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,13 @@ | ||
CREATE TABLE ddon_epitaph_road_unlocks ( | ||
"character_id" INTEGER NOT NULL, | ||
"epitaph_id" INTEGER NOT NULL, | ||
CONSTRAINT "pk_ddon_epitaph_road_unlocks" PRIMARY KEY ("character_id", "epitaph_id"), | ||
CONSTRAINT "fk_ddon_epitaph_road_unlocks_character_id" FOREIGN KEY ("character_id") REFERENCES "ddon_character"("character_id") ON DELETE CASCADE | ||
); | ||
|
||
CREATE TABLE ddon_epitaph_claimed_weekly_rewards ( | ||
"character_id" INTEGER NOT NULL, | ||
"epitaph_id" INTEGER NOT NULL, | ||
CONSTRAINT "pk_ddon_epitaph_claimed_weekly_rewards" PRIMARY KEY ("character_id", "epitaph_id"), | ||
CONSTRAINT "fk_ddon_epitaph_claimed_weekly_rewards_character_id" FOREIGN KEY ("character_id") REFERENCES "ddon_character"("character_id") ON DELETE CASCADE | ||
); |
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
60 changes: 60 additions & 0 deletions
60
Arrowgene.Ddon.Database/Sql/Core/DdonSqlDbEpitaphRoadClaimedWeeklyRewards.cs
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,60 @@ | ||
using System.Collections.Generic; | ||
using System.Data.Common; | ||
|
||
namespace Arrowgene.Ddon.Database.Sql.Core | ||
{ | ||
public abstract partial class DdonSqlDb<TCon, TCom, TReader> : SqlDb<TCon, TCom, TReader> | ||
where TCon : DbConnection | ||
where TCom : DbCommand | ||
where TReader : DbDataReader | ||
{ | ||
/* ddon_epitaph_claimed_weekly_rewards */ | ||
protected static readonly string[] EpitaphRoadClaimedWeeklyRewardsFields = new string[] | ||
{ | ||
"character_id", "epitaph_id" | ||
}; | ||
|
||
private readonly string SqlSelectEpitaphClaimedWeeklyRewards = $"SELECT {BuildQueryField(EpitaphRoadClaimedWeeklyRewardsFields)} FROM \"ddon_epitaph_claimed_weekly_rewards\" WHERE \"character_id\"=@character_id;"; | ||
private readonly string SqlInsertEpitaphClaimedWeeklyRewards = $"INSERT INTO \"ddon_epitaph_claimed_weekly_rewards\" ({BuildQueryField(EpitaphRoadClaimedWeeklyRewardsFields)}) VALUES ({BuildQueryInsert(EpitaphRoadClaimedWeeklyRewardsFields)});"; | ||
private readonly string SqlDeleteWeeklyRewards = $"DELETE FROM ddon_epitaph_claimed_weekly_rewards;"; | ||
|
||
public bool InsertEpitaphWeeklyReward(uint characterId, uint epitaphId, DbConnection? connectionIn = null) | ||
{ | ||
return ExecuteQuerySafe<bool>(connectionIn, (connection) => | ||
{ | ||
return ExecuteNonQuery(connection, SqlInsertEpitaphClaimedWeeklyRewards, command => | ||
{ | ||
AddParameter(command, "character_id", characterId); | ||
AddParameter(command, "epitaph_id", epitaphId); | ||
}) == 1; | ||
}); | ||
} | ||
|
||
public HashSet<uint> GetEpitaphClaimedWeeklyRewards(uint characterId, DbConnection? connectionIn = null) | ||
{ | ||
var results = new HashSet<uint>(); | ||
ExecuteQuerySafe(connectionIn, (connection) => | ||
{ | ||
ExecuteReader(connection, SqlSelectEpitaphClaimedWeeklyRewards, command => | ||
{ | ||
AddParameter(command, "character_id", characterId); | ||
}, reader => | ||
{ | ||
while (reader.Read()) | ||
{ | ||
results.Add(GetUInt32(reader, "epitaph_id")); | ||
} | ||
}); | ||
}); | ||
return results; | ||
} | ||
|
||
public void DeleteWeeklyRewards(DbConnection? connectionIn = null) | ||
{ | ||
ExecuteQuerySafe(connectionIn, (connection) => | ||
{ | ||
ExecuteNonQuery(connection, SqlDeleteWeeklyRewards, command => { }); | ||
}); | ||
} | ||
} | ||
} |
51 changes: 51 additions & 0 deletions
51
Arrowgene.Ddon.Database/Sql/Core/DdonSqlDbEpitaphRoadUnlocks.cs
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,51 @@ | ||
using System.Collections.Generic; | ||
using System.Data.Common; | ||
|
||
namespace Arrowgene.Ddon.Database.Sql.Core | ||
{ | ||
public abstract partial class DdonSqlDb<TCon, TCom, TReader> : SqlDb<TCon, TCom, TReader> | ||
where TCon : DbConnection | ||
where TCom : DbCommand | ||
where TReader : DbDataReader | ||
{ | ||
/* ddon_epitaph_road_unlocks */ | ||
protected static readonly string[] EpitaphRoadUnlocksFields = new string[] | ||
{ | ||
"character_id", "epitaph_id" | ||
}; | ||
|
||
private readonly string SqlSelectEpitaphUnlocks = $"SELECT {BuildQueryField(EpitaphRoadUnlocksFields)} FROM \"ddon_epitaph_road_unlocks\" WHERE \"character_id\"=@character_id;"; | ||
private readonly string SqlInsertEpitaphUnlocks = $"INSERT INTO \"ddon_epitaph_road_unlocks\" ({BuildQueryField(EpitaphRoadUnlocksFields)}) VALUES ({BuildQueryInsert(EpitaphRoadUnlocksFields)});"; | ||
|
||
public bool InsertEpitaphRoadUnlock(uint characterId, uint epitaphId, DbConnection? connectionIn = null) | ||
{ | ||
return ExecuteQuerySafe<bool>(connectionIn, (connection) => | ||
{ | ||
return ExecuteNonQuery(connection, SqlInsertEpitaphUnlocks, command => | ||
{ | ||
AddParameter(command, "character_id", characterId); | ||
AddParameter(command, "epitaph_id", epitaphId); | ||
}) == 1; | ||
}); | ||
} | ||
|
||
public HashSet<uint> GetEpitaphRoadUnlocks(uint characterId, DbConnection? connectionIn = null) | ||
{ | ||
var results = new HashSet<uint>(); | ||
ExecuteQuerySafe(connectionIn, (connection) => | ||
{ | ||
ExecuteReader(connection, SqlSelectEpitaphUnlocks, command => | ||
{ | ||
AddParameter(command, "character_id", characterId); | ||
}, reader => | ||
{ | ||
while (reader.Read()) | ||
{ | ||
results.Add(GetUInt32(reader, "epitaph_id")); | ||
} | ||
}); | ||
}); | ||
return results; | ||
} | ||
} | ||
} |
24 changes: 24 additions & 0 deletions
24
Arrowgene.Ddon.Database/Sql/Core/Migration/00000024_EpitaphRoadMigration.cs
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,24 @@ | ||
using System.Data.Common; | ||
|
||
namespace Arrowgene.Ddon.Database.Sql.Core.Migration | ||
{ | ||
public class EpitaphRoadMigration : IMigrationStrategy | ||
{ | ||
public uint From => 23; | ||
public uint To => 24; | ||
|
||
private readonly DatabaseSetting DatabaseSetting; | ||
|
||
public EpitaphRoadMigration(DatabaseSetting databaseSetting) | ||
{ | ||
DatabaseSetting = databaseSetting; | ||
} | ||
|
||
public bool Migrate(IDatabase db, DbConnection conn) | ||
{ | ||
string adaptedSchema = DdonDatabaseBuilder.GetAdaptedSchema(DatabaseSetting, "Script/migration_epitaph_road.sql"); | ||
db.Execute(conn, adaptedSchema); | ||
return true; | ||
} | ||
} | ||
} |
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
Oops, something went wrong.