Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
Y
ygopro-2pick
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Locked Files
Issues
0
Issues
0
List
Boards
Labels
Service Desk
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Security & Compliance
Security & Compliance
Dependency List
License Compliance
Packages
Packages
Container Registry
Analytics
Analytics
CI / CD
Code Review
Insights
Issues
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
MyCard
ygopro-2pick
Commits
b3a4616a
Commit
b3a4616a
authored
Jan 03, 2018
by
nanahira
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
update_pool_load
parent
1e46b661
Changes
3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
4 additions
and
6 deletions
+4
-6
2pick/2pick.cdb
2pick/2pick.cdb
+0
-0
2pick/card_pools/default/sqlite_cmd.txt
2pick/card_pools/default/sqlite_cmd.txt
+0
-3
2pick/pick.lua
2pick/pick.lua
+4
-3
No files found.
2pick/
card_pools/default/card_pool
.cdb
→
2pick/
2pick
.cdb
View file @
b3a4616a
File moved
2pick/card_pools/default/sqlite_cmd.txt
deleted
100644 → 0
View file @
1e46b661
.output card_list_default.txt
select * from datas;
.output stdout
2pick/pick.lua
View file @
b3a4616a
...
...
@@ -26,7 +26,8 @@ function Auxiliary.SplitData(inputstr)
return
t
end
function
Auxiliary
.
LoadDB
(
p
,
pool
)
for
line
in
io.lines
(
"card_list_"
..
pool
..
".txt"
)
do
local
file
=
io.popen
(
"echo .exit | sqlite3 "
..
pool
..
".cdb -cmd \"
select
*
from
datas
\
""
)
for
line
in
file
:
lines
()
do
local
data
=
Auxiliary
.
SplitData
(
line
)
local
code
=
data
[
1
]
local
cat
=
data
[
5
]
...
...
@@ -54,14 +55,14 @@ function Auxiliary.LoadDB(p,pool)
table.insert
(
main
[
p
],
code
)
end
end
file
:
close
()
end
--to do: multi card pools
function
Auxiliary
.
LoadCardPools
()
local
pool_list
=
{}
local
file
=
io.popen
(
"ls 2pick/
card_pools
"
)
local
file
=
io.popen
(
"ls 2pick/
*.cdb
"
)
for
pool
in
file
:
lines
()
do
table.insert
(
pool_list
,
pool
)
os.execute
(
"sqlite3 2pick/card_pools/"
..
pool
..
"/card_pool.cdb < 2pick/card_pools/"
..
pool
..
"/sqlite_cmd.txt"
)
end
file
:
close
()
for
p
=
0
,
1
do
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment