Skip to content

Commit

Permalink
Merge pull request #21 from ko4life-net/release/1.0.0
Browse files Browse the repository at this point in the history
Initial release 1.0.0.
  • Loading branch information
stevewgr committed Apr 30, 2024
2 parents 2c22624 + a8a6b46 commit 4bf1b11
Show file tree
Hide file tree
Showing 100 changed files with 458 additions and 2,564 deletions.
1 change: 0 additions & 1 deletion src/data/BK_FRI_USERDATA.sql

This file was deleted.

1 change: 0 additions & 1 deletion src/data/BK_FRI_WAREHOUSE.sql

This file was deleted.

1 change: 0 additions & 1 deletion src/data/BK_MON_USERDATA.sql

This file was deleted.

1 change: 0 additions & 1 deletion src/data/BK_MON_WAREHOUSE.sql

This file was deleted.

1 change: 0 additions & 1 deletion src/data/BK_SAT_USERDATA.sql

This file was deleted.

1 change: 0 additions & 1 deletion src/data/BK_SAT_WAREHOUSE.sql

This file was deleted.

1 change: 0 additions & 1 deletion src/data/BK_SUN_USERDATA.sql

This file was deleted.

1 change: 0 additions & 1 deletion src/data/BK_SUN_WAREHOUSE.sql

This file was deleted.

1 change: 0 additions & 1 deletion src/data/BK_THU_USERDATA.sql

This file was deleted.

1 change: 0 additions & 1 deletion src/data/BK_THU_WAREHOUSE.sql

This file was deleted.

1 change: 0 additions & 1 deletion src/data/BK_TUE_USERDATA.sql

This file was deleted.

1 change: 0 additions & 1 deletion src/data/BK_TUE_WAREHOUSE.sql

This file was deleted.

1 change: 0 additions & 1 deletion src/data/BK_WED_USERDATA.sql

This file was deleted.

1 change: 0 additions & 1 deletion src/data/BK_WED_WAREHOUSE.sql

This file was deleted.

1 change: 0 additions & 1 deletion src/data/BLOCKED_USERDATA.sql

This file was deleted.

1 change: 0 additions & 1 deletion src/data/BLOCKED_WAREHOUSE.sql

This file was deleted.

250 changes: 125 additions & 125 deletions src/data/K_MONSTER.sql

Large diffs are not rendered by default.

344 changes: 172 additions & 172 deletions src/data/K_NPC.sql

Large diffs are not rendered by default.

1 change: 0 additions & 1 deletion src/data/K_NPCPOS_BACK.sql

This file was deleted.

1 change: 0 additions & 1 deletion src/data/K_NPCPOS_SORT.sql

This file was deleted.

1 change: 0 additions & 1 deletion src/data/MONSTER_ITEM_TEST.sql

This file was deleted.

2 changes: 1 addition & 1 deletion src/data/TB_USER.sql
Original file line number Diff line number Diff line change
@@ -1 +1 @@

INSERT [dbo].[TB_USER] ([strAccountID], [strPasswd], [strSocNo]) VALUES (N'steve', N'1', N'1 ')
5 changes: 3 additions & 2 deletions src/migration/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,13 +13,14 @@ Couple of rules and notes when writing migration scripts:
## Creating a new release

Below are instructions for the release engineer in order to create a new db release:
- Create a new release branch following the db new release version according version semantics (`git checkout release/1.0.1`)
- Create a new release branch following the db new release version according version semantics (`git checkout -b release/1.0.1`)
- Run the import script skipping the migration scripts (`.\import.ps1 -run_migration_scripts $false`)
- Run the export script, to be sure that no diff is produced (`.\export.ps1` and then `git status`)
- If there are local changes, something is probably off. Repeat the steps above
- If you're sure all in order, best is if you create a new separate PR with the changes, in case empty spaces and such were added
- Run the import script again without the migration scripts and produce diffs (`.\import.ps1 -generate_diffs $true`)
- Run the import script again with the migration scripts and produce diffs (`.\import.ps1 -generate_diffs $true`)
- Move all migration scripts and its `*.diff` files to the `archived` directory
- Lastly run the export script once more, but this time you'll have the actual changes from the migration scripts affecting the actual schema
- Git commit all the changes (`Bump version from 1.0.0 to 1.0.1`)
- Check the final diff that all looks in order
- Create a PR and merge after approval
Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
37 changes: 9 additions & 28 deletions src/procedure/ACCOUNT_LOGIN.sql
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
SET ANSI_NULLS OFF
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
SET QUOTED_IDENTIFIER OFF
GO
CREATE PROCEDURE [dbo].[ACCOUNT_LOGIN]
@AccountID varchar(21),
Expand All @@ -9,46 +9,27 @@ CREATE PROCEDURE [dbo].[ACCOUNT_LOGIN]

AS


DECLARE @Nation tinyint, @CharNum smallint
SET @Nation = 0
SET @CharNum = 0

DECLARE @pwd varchar(13)

SET @pwd = NULL

SELECT @pwd = strPasswd FROM [dbo].[TB_USER] WHERE strAccountID = @AccountID
IF @pwd IS NULL
BEGIN
SET @nRet = 0
BEGIN TRAN
INSERT INTO TB_USER (strAccountID, strPasswd, strSocNo)
VALUES (@AccountID, @Password, 1)
COMMIT TRAN
SET @nRet = 1
RETURN
END

ELSE IF @pwd != @Password
BEGIN
SET @nRet = 0
SET @nRet = 3
RETURN
END

SELECT
@Nation = bNation,
@CharNum = bCharNum
FROM ACCOUNT_CHAR WHERE strAccountID = @AccountID
IF @@ROWCOUNT = 0
BEGIN
SET @nRet = 1
RETURN
END
IF @CharNum = 0
BEGIN
SET @nRet = 1
RETURN
END
ELSE
BEGIN
SET @nRet = @Nation + 1
RETURN
END
SET @nRet = 1 -- success

GO
206 changes: 0 additions & 206 deletions src/procedure/BACKUP_FRI.sql

This file was deleted.

Loading

0 comments on commit 4bf1b11

Please sign in to comment.