mirror of
https://github.com/SamueleLorefice/isleBot.git
synced 2026-01-14 21:55:49 +00:00
Converted the project in C#, added Entity Framework Core.
This commit is contained in:
513
.gitignore
vendored
513
.gitignore
vendored
@@ -1,192 +1,397 @@
|
|||||||
### PythonVanilla template
|
### Csharp ###
|
||||||
# Byte-compiled / optimized / DLL files
|
## Ignore Visual Studio temporary files, build results, and
|
||||||
__pycache__/
|
## files generated by popular Visual Studio add-ons.
|
||||||
*.py[cod]
|
##
|
||||||
*$py.class
|
## Get latest from https://github.com/github/gitignore/blob/main/VisualStudio.gitignore
|
||||||
|
|
||||||
# C extensions
|
# User-specific files
|
||||||
*.so
|
*.rsuser
|
||||||
|
*.suo
|
||||||
|
*.user
|
||||||
|
*.userosscache
|
||||||
|
*.sln.docstates
|
||||||
|
|
||||||
# Distribution / packaging
|
# User-specific files (MonoDevelop/Xamarin Studio)
|
||||||
.Python
|
*.userprefs
|
||||||
build/
|
|
||||||
develop-eggs/
|
|
||||||
dist/
|
|
||||||
downloads/
|
|
||||||
eggs/
|
|
||||||
.eggs/
|
|
||||||
lib/
|
|
||||||
lib64/
|
|
||||||
parts/
|
|
||||||
sdist/
|
|
||||||
var/
|
|
||||||
wheels/
|
|
||||||
share/python-wheels/
|
|
||||||
*.egg-info/
|
|
||||||
.installed.cfg
|
|
||||||
*.egg
|
|
||||||
MANIFEST
|
|
||||||
|
|
||||||
# Installer logs
|
# Mono auto generated files
|
||||||
pip-log.txt
|
mono_crash.*
|
||||||
pip-delete-this-directory.txt
|
|
||||||
|
|
||||||
# Unit test / coverage reports
|
# Build results
|
||||||
htmlcov/
|
[Dd]ebug/
|
||||||
.tox/
|
[Dd]ebugPublic/
|
||||||
.nox/
|
[Rr]elease/
|
||||||
.coverage
|
[Rr]eleases/
|
||||||
.coverage.*
|
x64/
|
||||||
.cache
|
x86/
|
||||||
nosetests.xml
|
[Ww][Ii][Nn]32/
|
||||||
coverage.xml
|
[Aa][Rr][Mm]/
|
||||||
*.cover
|
[Aa][Rr][Mm]64/
|
||||||
*.py,cover
|
bld/
|
||||||
.hypothesis/
|
[Bb]in/
|
||||||
.pytest_cache/
|
[Oo]bj/
|
||||||
cover/
|
[Ll]og/
|
||||||
|
[Ll]ogs/
|
||||||
|
|
||||||
# Translations
|
# Visual Studio 2015/2017 cache/options directory
|
||||||
*.mo
|
.vs/
|
||||||
*.pot
|
# Uncomment if you have tasks that create the project's static files in wwwroot
|
||||||
|
#wwwroot/
|
||||||
|
|
||||||
# pyenv
|
# Visual Studio 2017 auto generated files
|
||||||
# For a library or package, you might want to ignore these files since the code is
|
Generated\ Files/
|
||||||
# intended to run in multiple environments; otherwise, check them in:
|
|
||||||
# .python-version
|
|
||||||
|
|
||||||
# pipenv
|
# MSTest test Results
|
||||||
# According to pypa/pipenv#598, it is recommended to include Pipfile.lock in version control.
|
[Tt]est[Rr]esult*/
|
||||||
# However, in case of collaboration, if having platform-specific dependencies or dependencies
|
[Bb]uild[Ll]og.*
|
||||||
# having no cross-platform support, pipenv may install dependencies that don't work, or not
|
|
||||||
# install all needed dependencies.
|
|
||||||
#Pipfile.lock
|
|
||||||
|
|
||||||
# PEP 582; used by e.g. github.com/David-OConnor/pyflow
|
# NUnit
|
||||||
__pypackages__/
|
*.VisualState.xml
|
||||||
|
TestResult.xml
|
||||||
|
nunit-*.xml
|
||||||
|
|
||||||
|
# Build Results of an ATL Project
|
||||||
|
[Dd]ebugPS/
|
||||||
|
[Rr]eleasePS/
|
||||||
|
dlldata.c
|
||||||
|
|
||||||
### Python template
|
# Benchmark Results
|
||||||
# Byte-compiled / optimized / DLL files
|
BenchmarkDotNet.Artifacts/
|
||||||
|
|
||||||
# C extensions
|
# .NET Core
|
||||||
|
project.lock.json
|
||||||
|
project.fragment.lock.json
|
||||||
|
artifacts/
|
||||||
|
|
||||||
# Distribution / packaging
|
# ASP.NET Scaffolding
|
||||||
|
ScaffoldingReadMe.txt
|
||||||
|
|
||||||
# PyInstaller
|
# StyleCop
|
||||||
# Usually these files are written by a python script from a template
|
StyleCopReport.xml
|
||||||
# before PyInstaller builds the exe, so as to inject date/other infos into it.
|
|
||||||
*.manifest
|
|
||||||
*.spec
|
|
||||||
|
|
||||||
# Installer logs
|
# Files built by Visual Studio
|
||||||
|
*_i.c
|
||||||
# Unit test / coverage reports
|
*_p.c
|
||||||
|
*_h.h
|
||||||
# Translations
|
*.ilk
|
||||||
|
*.meta
|
||||||
# Django stuff:
|
*.obj
|
||||||
|
*.iobj
|
||||||
|
*.pch
|
||||||
|
*.pdb
|
||||||
|
*.ipdb
|
||||||
|
*.pgc
|
||||||
|
*.pgd
|
||||||
|
*.rsp
|
||||||
|
*.sbr
|
||||||
|
*.tlb
|
||||||
|
*.tli
|
||||||
|
*.tlh
|
||||||
|
*.tmp
|
||||||
|
*.tmp_proj
|
||||||
|
*_wpftmp.csproj
|
||||||
*.log
|
*.log
|
||||||
local_settings.py
|
*.tlog
|
||||||
db.sqlite3
|
*.vspscc
|
||||||
db.sqlite3-journal
|
*.vssscc
|
||||||
|
.builds
|
||||||
|
*.pidb
|
||||||
|
*.svclog
|
||||||
|
*.scc
|
||||||
|
|
||||||
# Flask stuff:
|
# Chutzpah Test files
|
||||||
instance/
|
_Chutzpah*
|
||||||
.webassets-cache
|
|
||||||
|
|
||||||
# Scrapy stuff:
|
# Visual C++ cache files
|
||||||
.scrapy
|
ipch/
|
||||||
|
*.aps
|
||||||
|
*.ncb
|
||||||
|
*.opendb
|
||||||
|
*.opensdf
|
||||||
|
*.sdf
|
||||||
|
*.cachefile
|
||||||
|
*.VC.db
|
||||||
|
*.VC.VC.opendb
|
||||||
|
|
||||||
# Sphinx documentation
|
# Visual Studio profiler
|
||||||
docs/_build/
|
*.psess
|
||||||
|
*.vsp
|
||||||
|
*.vspx
|
||||||
|
*.sap
|
||||||
|
|
||||||
# PyBuilder
|
# Visual Studio Trace Files
|
||||||
.pybuilder/
|
*.e2e
|
||||||
target/
|
|
||||||
|
|
||||||
# Jupyter Notebook
|
# TFS 2012 Local Workspace
|
||||||
.ipynb_checkpoints
|
$tf/
|
||||||
|
|
||||||
# IPython
|
# Guidance Automation Toolkit
|
||||||
profile_default/
|
*.gpState
|
||||||
ipython_config.py
|
|
||||||
|
|
||||||
# pyenv
|
# ReSharper is a .NET coding add-in
|
||||||
# For a library or package, you might want to ignore these files since the code is
|
_ReSharper*/
|
||||||
# intended to run in multiple environments; otherwise, check them in:
|
*.[Rr]e[Ss]harper
|
||||||
# .python-version
|
*.DotSettings.user
|
||||||
|
|
||||||
# pipenv
|
# TeamCity is a build add-in
|
||||||
# According to pypa/pipenv#598, it is recommended to include Pipfile.lock in version control.
|
_TeamCity*
|
||||||
# However, in case of collaboration, if having platform-specific dependencies or dependencies
|
|
||||||
# having no cross-platform support, pipenv may install dependencies that don't work, or not
|
|
||||||
# install all needed dependencies.
|
|
||||||
#Pipfile.lock
|
|
||||||
|
|
||||||
# poetry
|
# DotCover is a Code Coverage Tool
|
||||||
# Similar to Pipfile.lock, it is generally recommended to include poetry.lock in version control.
|
*.dotCover
|
||||||
# This is especially recommended for binary packages to ensure reproducibility, and is more
|
|
||||||
# commonly ignored for libraries.
|
|
||||||
# https://python-poetry.org/docs/basic-usage/#commit-your-poetrylock-file-to-version-control
|
|
||||||
#poetry.lock
|
|
||||||
|
|
||||||
# pdm
|
# AxoCover is a Code Coverage Tool
|
||||||
# Similar to Pipfile.lock, it is generally recommended to include pdm.lock in version control.
|
.axoCover/*
|
||||||
#pdm.lock
|
!.axoCover/settings.json
|
||||||
# pdm stores project-wide configurations in .pdm.toml, but it is recommended to not include it
|
|
||||||
# in version control.
|
|
||||||
# https://pdm.fming.dev/#use-with-ide
|
|
||||||
.pdm.toml
|
|
||||||
|
|
||||||
# PEP 582; used by e.g. github.com/David-OConnor/pyflow and github.com/pdm-project/pdm
|
# Coverlet is a free, cross platform Code Coverage Tool
|
||||||
|
coverage*.json
|
||||||
|
coverage*.xml
|
||||||
|
coverage*.info
|
||||||
|
|
||||||
# Celery stuff
|
# Visual Studio code coverage results
|
||||||
celerybeat-schedule
|
*.coverage
|
||||||
celerybeat.pid
|
*.coveragexml
|
||||||
|
|
||||||
# SageMath parsed files
|
# NCrunch
|
||||||
*.sage.py
|
_NCrunch_*
|
||||||
|
.*crunch*.local.xml
|
||||||
|
nCrunchTemp_*
|
||||||
|
|
||||||
# Environments
|
# MightyMoose
|
||||||
.env
|
*.mm.*
|
||||||
.venv
|
AutoTest.Net/
|
||||||
env/
|
|
||||||
venv/
|
|
||||||
ENV/
|
|
||||||
env.bak/
|
|
||||||
venv.bak/
|
|
||||||
|
|
||||||
# Spyder project settings
|
# Web workbench (sass)
|
||||||
.spyderproject
|
.sass-cache/
|
||||||
.spyproject
|
|
||||||
|
|
||||||
# Rope project settings
|
# Installshield output folder
|
||||||
.ropeproject
|
[Ee]xpress/
|
||||||
|
|
||||||
# mkdocs documentation
|
# DocProject is a documentation generator add-in
|
||||||
/site
|
DocProject/buildhelp/
|
||||||
|
DocProject/Help/*.HxT
|
||||||
|
DocProject/Help/*.HxC
|
||||||
|
DocProject/Help/*.hhc
|
||||||
|
DocProject/Help/*.hhk
|
||||||
|
DocProject/Help/*.hhp
|
||||||
|
DocProject/Help/Html2
|
||||||
|
DocProject/Help/html
|
||||||
|
|
||||||
# mypy
|
# Click-Once directory
|
||||||
.mypy_cache/
|
publish/
|
||||||
.dmypy.json
|
|
||||||
dmypy.json
|
|
||||||
|
|
||||||
# Pyre type checker
|
# Publish Web Output
|
||||||
.pyre/
|
*.[Pp]ublish.xml
|
||||||
|
*.azurePubxml
|
||||||
|
# Note: Comment the next line if you want to checkin your web deploy settings,
|
||||||
|
# but database connection strings (with potential passwords) will be unencrypted
|
||||||
|
*.pubxml
|
||||||
|
*.publishproj
|
||||||
|
|
||||||
# pytype static type analyzer
|
# Microsoft Azure Web App publish settings. Comment the next line if you want to
|
||||||
.pytype/
|
# checkin your Azure Web App publish settings, but sensitive information contained
|
||||||
|
# in these scripts will be unencrypted
|
||||||
|
PublishScripts/
|
||||||
|
|
||||||
# Cython debug symbols
|
# NuGet Packages
|
||||||
cython_debug/
|
*.nupkg
|
||||||
|
# NuGet Symbol Packages
|
||||||
|
*.snupkg
|
||||||
|
# The packages folder can be ignored because of Package Restore
|
||||||
|
**/[Pp]ackages/*
|
||||||
|
# except build/, which is used as an MSBuild target.
|
||||||
|
!**/[Pp]ackages/build/
|
||||||
|
# Uncomment if necessary however generally it will be regenerated when needed
|
||||||
|
#!**/[Pp]ackages/repositories.config
|
||||||
|
# NuGet v3's project.json files produces more ignorable files
|
||||||
|
*.nuget.props
|
||||||
|
*.nuget.targets
|
||||||
|
|
||||||
# PyCharm
|
# Microsoft Azure Build Output
|
||||||
# JetBrains specific template is maintained in a separate JetBrains.gitignore that can
|
csx/
|
||||||
# be found at https://github.com/github/gitignore/blob/main/Global/JetBrains.gitignore
|
*.build.csdef
|
||||||
# and can be added to the global gitignore or merged into this file. For a more nuclear
|
|
||||||
# option (not recommended) you can uncomment the following to ignore the entire idea folder.
|
|
||||||
#.idea/
|
|
||||||
|
|
||||||
#ignore .env
|
# Microsoft Azure Emulator
|
||||||
.env
|
ecf/
|
||||||
|
rcf/
|
||||||
|
|
||||||
|
# Windows Store app package directories and files
|
||||||
|
AppPackages/
|
||||||
|
BundleArtifacts/
|
||||||
|
Package.StoreAssociation.xml
|
||||||
|
_pkginfo.txt
|
||||||
|
*.appx
|
||||||
|
*.appxbundle
|
||||||
|
*.appxupload
|
||||||
|
|
||||||
|
# Visual Studio cache files
|
||||||
|
# files ending in .cache can be ignored
|
||||||
|
*.[Cc]ache
|
||||||
|
# but keep track of directories ending in .cache
|
||||||
|
!?*.[Cc]ache/
|
||||||
|
|
||||||
|
# Others
|
||||||
|
ClientBin/
|
||||||
|
~$*
|
||||||
|
*~
|
||||||
|
*.dbmdl
|
||||||
|
*.dbproj.schemaview
|
||||||
|
*.jfm
|
||||||
|
*.pfx
|
||||||
|
*.publishsettings
|
||||||
|
orleans.codegen.cs
|
||||||
|
|
||||||
|
# Including strong name files can present a security risk
|
||||||
|
# (https://github.com/github/gitignore/pull/2483#issue-259490424)
|
||||||
|
#*.snk
|
||||||
|
|
||||||
|
# Since there are multiple workflows, uncomment next line to ignore bower_components
|
||||||
|
# (https://github.com/github/gitignore/pull/1529#issuecomment-104372622)
|
||||||
|
#bower_components/
|
||||||
|
|
||||||
|
# RIA/Silverlight projects
|
||||||
|
Generated_Code/
|
||||||
|
|
||||||
|
# Backup & report files from converting an old project file
|
||||||
|
# to a newer Visual Studio version. Backup files are not needed,
|
||||||
|
# because we have git ;-)
|
||||||
|
_UpgradeReport_Files/
|
||||||
|
Backup*/
|
||||||
|
UpgradeLog*.XML
|
||||||
|
UpgradeLog*.htm
|
||||||
|
ServiceFabricBackup/
|
||||||
|
*.rptproj.bak
|
||||||
|
|
||||||
|
# SQL Server files
|
||||||
|
*.mdf
|
||||||
|
*.ldf
|
||||||
|
*.ndf
|
||||||
|
|
||||||
|
# Business Intelligence projects
|
||||||
|
*.rdl.data
|
||||||
|
*.bim.layout
|
||||||
|
*.bim_*.settings
|
||||||
|
*.rptproj.rsuser
|
||||||
|
*- [Bb]ackup.rdl
|
||||||
|
*- [Bb]ackup ([0-9]).rdl
|
||||||
|
*- [Bb]ackup ([0-9][0-9]).rdl
|
||||||
|
|
||||||
|
# Microsoft Fakes
|
||||||
|
FakesAssemblies/
|
||||||
|
|
||||||
|
# GhostDoc plugin setting file
|
||||||
|
*.GhostDoc.xml
|
||||||
|
|
||||||
|
# Node.js Tools for Visual Studio
|
||||||
|
.ntvs_analysis.dat
|
||||||
|
node_modules/
|
||||||
|
|
||||||
|
# Visual Studio 6 build log
|
||||||
|
*.plg
|
||||||
|
|
||||||
|
# Visual Studio 6 workspace options file
|
||||||
|
*.opt
|
||||||
|
|
||||||
|
# Visual Studio 6 auto-generated workspace file (contains which files were open etc.)
|
||||||
|
*.vbw
|
||||||
|
|
||||||
|
# Visual Studio 6 auto-generated project file (contains which files were open etc.)
|
||||||
|
*.vbp
|
||||||
|
|
||||||
|
# Visual Studio 6 workspace and project file (working project files containing files to include in project)
|
||||||
|
*.dsw
|
||||||
|
*.dsp
|
||||||
|
|
||||||
|
# Visual Studio 6 technical files
|
||||||
|
|
||||||
|
# Visual Studio LightSwitch build output
|
||||||
|
**/*.HTMLClient/GeneratedArtifacts
|
||||||
|
**/*.DesktopClient/GeneratedArtifacts
|
||||||
|
**/*.DesktopClient/ModelManifest.xml
|
||||||
|
**/*.Server/GeneratedArtifacts
|
||||||
|
**/*.Server/ModelManifest.xml
|
||||||
|
_Pvt_Extensions
|
||||||
|
|
||||||
|
# Paket dependency manager
|
||||||
|
.paket/paket.exe
|
||||||
|
paket-files/
|
||||||
|
|
||||||
|
# FAKE - F# Make
|
||||||
|
.fake/
|
||||||
|
|
||||||
|
# CodeRush personal settings
|
||||||
|
.cr/personal
|
||||||
|
|
||||||
|
# Python Tools for Visual Studio (PTVS)
|
||||||
|
__pycache__/
|
||||||
|
*.pyc
|
||||||
|
|
||||||
|
# Cake - Uncomment if you are using it
|
||||||
|
# tools/**
|
||||||
|
# !tools/packages.config
|
||||||
|
|
||||||
|
# Tabs Studio
|
||||||
|
*.tss
|
||||||
|
|
||||||
|
# Telerik's JustMock configuration file
|
||||||
|
*.jmconfig
|
||||||
|
|
||||||
|
# BizTalk build output
|
||||||
|
*.btp.cs
|
||||||
|
*.btm.cs
|
||||||
|
*.odx.cs
|
||||||
|
*.xsd.cs
|
||||||
|
|
||||||
|
# OpenCover UI analysis results
|
||||||
|
OpenCover/
|
||||||
|
|
||||||
|
# Azure Stream Analytics local run output
|
||||||
|
ASALocalRun/
|
||||||
|
|
||||||
|
# MSBuild Binary and Structured Log
|
||||||
|
*.binlog
|
||||||
|
|
||||||
|
# NVidia Nsight GPU debugger configuration file
|
||||||
|
*.nvuser
|
||||||
|
|
||||||
|
# MFractors (Xamarin productivity tool) working folder
|
||||||
|
.mfractor/
|
||||||
|
|
||||||
|
# Local History for Visual Studio
|
||||||
|
.localhistory/
|
||||||
|
|
||||||
|
# Visual Studio History (VSHistory) files
|
||||||
|
.vshistory/
|
||||||
|
|
||||||
|
# BeatPulse healthcheck temp database
|
||||||
|
healthchecksdb
|
||||||
|
|
||||||
|
# Backup folder for Package Reference Convert tool in Visual Studio 2017
|
||||||
|
MigrationBackup/
|
||||||
|
|
||||||
|
# Ionide (cross platform F# VS Code tools) working folder
|
||||||
|
.ionide/
|
||||||
|
|
||||||
|
# Fody - auto-generated XML schema
|
||||||
|
FodyWeavers.xsd
|
||||||
|
|
||||||
|
# VS Code files for those working on multiple tools
|
||||||
|
.vscode/*
|
||||||
|
!.vscode/settings.json
|
||||||
|
!.vscode/tasks.json
|
||||||
|
!.vscode/launch.json
|
||||||
|
!.vscode/extensions.json
|
||||||
|
*.code-workspace
|
||||||
|
|
||||||
|
# Local History for Visual Studio Code
|
||||||
|
.history/
|
||||||
|
|
||||||
|
# Windows Installer files from build outputs
|
||||||
|
*.cab
|
||||||
|
*.msi
|
||||||
|
*.msix
|
||||||
|
*.msm
|
||||||
|
*.msp
|
||||||
|
|
||||||
|
# JetBrains Rider
|
||||||
|
*.sln.iml
|
||||||
7
.idea/.gitignore → .idea/.idea.IsleBot/.idea/.gitignore
generated
vendored
7
.idea/.gitignore → .idea/.idea.IsleBot/.idea/.gitignore
generated
vendored
@@ -1,6 +1,11 @@
|
|||||||
# Default ignored files
|
# Default ignored files
|
||||||
/shelf/
|
/shelf/
|
||||||
/workspace.xml
|
/workspace.xml
|
||||||
|
# Rider ignored files
|
||||||
|
/modules.xml
|
||||||
|
/projectSettingsUpdater.xml
|
||||||
|
/.idea.IsleBotSharp.iml
|
||||||
|
/contentModel.xml
|
||||||
# Editor-based HTTP Client requests
|
# Editor-based HTTP Client requests
|
||||||
/httpRequests/
|
/httpRequests/
|
||||||
# Datasource local storage ignored files
|
# Datasource local storage ignored files
|
||||||
4
.idea/.idea.IsleBot/.idea/encodings.xml
generated
Normal file
4
.idea/.idea.IsleBot/.idea/encodings.xml
generated
Normal file
@@ -0,0 +1,4 @@
|
|||||||
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
|
<project version="4">
|
||||||
|
<component name="Encoding" addBOMForNewFiles="with BOM under Windows, with no BOM otherwise" />
|
||||||
|
</project>
|
||||||
8
.idea/.idea.IsleBot/.idea/indexLayout.xml
generated
Normal file
8
.idea/.idea.IsleBot/.idea/indexLayout.xml
generated
Normal file
@@ -0,0 +1,8 @@
|
|||||||
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
|
<project version="4">
|
||||||
|
<component name="UserContentModel">
|
||||||
|
<attachedFolders />
|
||||||
|
<explicitIncludes />
|
||||||
|
<explicitExcludes />
|
||||||
|
</component>
|
||||||
|
</project>
|
||||||
@@ -1,6 +1,6 @@
|
|||||||
<?xml version="1.0" encoding="UTF-8"?>
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
<project version="4">
|
<project version="4">
|
||||||
<component name="VcsDirectoryMappings">
|
<component name="VcsDirectoryMappings">
|
||||||
<mapping directory="$PROJECT_DIR$" vcs="Git" />
|
<mapping directory="" vcs="Git" />
|
||||||
</component>
|
</component>
|
||||||
</project>
|
</project>
|
||||||
135
.idea/.idea.IsleBotSharp/.idea/workspace.xml
generated
Normal file
135
.idea/.idea.IsleBotSharp/.idea/workspace.xml
generated
Normal file
@@ -0,0 +1,135 @@
|
|||||||
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
|
<project version="4">
|
||||||
|
<component name="AutoGeneratedRunConfigurationManager">
|
||||||
|
<projectFile>IsleBotSharp.csproj</projectFile>
|
||||||
|
</component>
|
||||||
|
<component name="AutoImportSettings">
|
||||||
|
<option name="autoReloadType" value="SELECTIVE" />
|
||||||
|
</component>
|
||||||
|
<component name="ChangeListManager">
|
||||||
|
<list default="true" id="79ad02fc-d6b5-4413-931b-52fb76129e49" name="Changes" comment="">
|
||||||
|
<change afterPath="$PROJECT_DIR$/.idea/.idea.IsleBot/.idea/encodings.xml" afterDir="false" />
|
||||||
|
<change afterPath="$PROJECT_DIR$/.idea/.idea.IsleBot/.idea/indexLayout.xml" afterDir="false" />
|
||||||
|
<change afterPath="$PROJECT_DIR$/.idea/.idea.IsleBotSharp/.idea/workspace.xml" afterDir="false" />
|
||||||
|
<change afterPath="$PROJECT_DIR$/Card.cs" afterDir="false" />
|
||||||
|
<change afterPath="$PROJECT_DIR$/Config.cs" afterDir="false" />
|
||||||
|
<change afterPath="$PROJECT_DIR$/DbManager.cs" afterDir="false" />
|
||||||
|
<change afterPath="$PROJECT_DIR$/EStatus.cs" afterDir="false" />
|
||||||
|
<change afterPath="$PROJECT_DIR$/IsleBot.csproj" afterDir="false" />
|
||||||
|
<change afterPath="$PROJECT_DIR$/IsleBot.sln" afterDir="false" />
|
||||||
|
<change afterPath="$PROJECT_DIR$/Match.cs" afterDir="false" />
|
||||||
|
<change afterPath="$PROJECT_DIR$/Program.cs" afterDir="false" />
|
||||||
|
<change afterPath="$PROJECT_DIR$/User.cs" afterDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/.gitignore" beforeDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/.idea/.gitignore" beforeDir="false" afterPath="$PROJECT_DIR$/.idea/.idea.IsleBot/.idea/.gitignore" afterDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/.idea/IsleBot.iml" beforeDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/.idea/dbnavigator.xml" beforeDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/.idea/inspectionProfiles/Project_Default.xml" beforeDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/.idea/inspectionProfiles/profiles_settings.xml" beforeDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/.idea/misc.xml" beforeDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/.idea/modules.xml" beforeDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/.idea/vcs.xml" beforeDir="false" afterPath="$PROJECT_DIR$/.idea/.idea.IsleBot/.idea/vcs.xml" afterDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/Card.py" beforeDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/Player.py" beforeDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/main.py" beforeDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/requirements.txt" beforeDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/start.ps1" beforeDir="false" />
|
||||||
|
</list>
|
||||||
|
<option name="SHOW_DIALOG" value="false" />
|
||||||
|
<option name="HIGHLIGHT_CONFLICTS" value="true" />
|
||||||
|
<option name="HIGHLIGHT_NON_ACTIVE_CHANGELIST" value="false" />
|
||||||
|
<option name="LAST_RESOLUTION" value="IGNORE" />
|
||||||
|
</component>
|
||||||
|
<component name="Git.Settings">
|
||||||
|
<option name="RECENT_GIT_ROOT_PATH" value="$PROJECT_DIR$" />
|
||||||
|
</component>
|
||||||
|
<component name="HighlightingSettingsPerFile">
|
||||||
|
<setting file="file://$APPLICATION_CONFIG_DIR$/resharper-host/SourcesCache/3d5314c4b5f391de6f26e7ce0d430d6d2aa1d7a44530b874fdbb1a4a97374/File.cs" root0="SKIP_HIGHLIGHTING" />
|
||||||
|
<setting file="file://$APPLICATION_CONFIG_DIR$/resharper-host/SourcesCache/bd1d5c50194fea68ff3559c160230b0ab50f5acf4ce3061bffd6d62958e2182/ExceptionDispatchInfo.cs" root0="SKIP_HIGHLIGHTING" />
|
||||||
|
<setting file="file://$PROJECT_DIR$/DbManager.cs" root0="FORCE_HIGHLIGHTING" />
|
||||||
|
<setting file="file://$PROJECT_DIR$/EStatus.cs" root0="FORCE_HIGHLIGHTING" />
|
||||||
|
<setting file="file://$PROJECT_DIR$/Match.cs" root0="FORCE_HIGHLIGHTING" />
|
||||||
|
<setting file="file://$PROJECT_DIR$/Program.cs" root0="FORCE_HIGHLIGHTING" />
|
||||||
|
</component>
|
||||||
|
<component name="ProjectColorInfo">{
|
||||||
|
"associatedIndex": 8
|
||||||
|
}</component>
|
||||||
|
<component name="ProjectId" id="2XlSZhdO6OtLGbtDTHRVgKGj55t" />
|
||||||
|
<component name="ProjectViewState">
|
||||||
|
<option name="hideEmptyMiddlePackages" value="true" />
|
||||||
|
<option name="showLibraryContents" value="true" />
|
||||||
|
</component>
|
||||||
|
<component name="PropertiesComponent"><![CDATA[{
|
||||||
|
"keyToString": {
|
||||||
|
"ASKED_SHARE_PROJECT_CONFIGURATION_FILES": "true",
|
||||||
|
"RunOnceActivity.OpenProjectViewOnStart": "true",
|
||||||
|
"RunOnceActivity.ShowReadmeOnStart": "true",
|
||||||
|
"SHARE_PROJECT_CONFIGURATION_FILES": "true",
|
||||||
|
"WebServerToolWindowFactoryState": "false",
|
||||||
|
"git-widget-placeholder": "feature/dbImpl",
|
||||||
|
"node.js.detected.package.eslint": "true",
|
||||||
|
"node.js.detected.package.tslint": "true",
|
||||||
|
"node.js.selected.package.eslint": "(autodetect)",
|
||||||
|
"node.js.selected.package.tslint": "(autodetect)",
|
||||||
|
"settings.editor.selected.configurable": "preferences.sourceCode.C#",
|
||||||
|
"vue.rearranger.settings.migration": "true"
|
||||||
|
},
|
||||||
|
"keyToStringList": {
|
||||||
|
"rider.external.source.directories": [
|
||||||
|
"C:\\Users\\airon\\AppData\\Roaming\\JetBrains\\Rider2023.2\\resharper-host\\DecompilerCache",
|
||||||
|
"C:\\Users\\airon\\AppData\\Roaming\\JetBrains\\Rider2023.2\\resharper-host\\SourcesCache",
|
||||||
|
"C:\\Users\\airon\\AppData\\Local\\Symbols\\src"
|
||||||
|
]
|
||||||
|
}
|
||||||
|
}]]></component>
|
||||||
|
<component name="RunManager">
|
||||||
|
<configuration name="IsleBotSharp" type="DotNetProject" factoryName=".NET Project">
|
||||||
|
<option name="EXE_PATH" value="" />
|
||||||
|
<option name="PROGRAM_PARAMETERS" value="" />
|
||||||
|
<option name="WORKING_DIRECTORY" value="" />
|
||||||
|
<option name="PASS_PARENT_ENVS" value="1" />
|
||||||
|
<option name="USE_EXTERNAL_CONSOLE" value="0" />
|
||||||
|
<option name="USE_MONO" value="0" />
|
||||||
|
<option name="RUNTIME_ARGUMENTS" value="" />
|
||||||
|
<option name="PROJECT_PATH" value="$PROJECT_DIR$/IsleBot.csproj" />
|
||||||
|
<option name="PROJECT_EXE_PATH_TRACKING" value="1" />
|
||||||
|
<option name="PROJECT_ARGUMENTS_TRACKING" value="1" />
|
||||||
|
<option name="PROJECT_WORKING_DIRECTORY_TRACKING" value="1" />
|
||||||
|
<option name="PROJECT_KIND" value="DotNetCore" />
|
||||||
|
<option name="PROJECT_TFM" value="" />
|
||||||
|
<method v="2">
|
||||||
|
<option name="Build" />
|
||||||
|
</method>
|
||||||
|
</configuration>
|
||||||
|
</component>
|
||||||
|
<component name="SpellCheckerSettings" RuntimeDictionaries="0" Folders="0" CustomDictionaries="0" DefaultDictionary="application-level" UseSingleDictionary="true" transferred="true" />
|
||||||
|
<component name="TaskManager">
|
||||||
|
<task active="true" id="Default" summary="Default task">
|
||||||
|
<changelist id="79ad02fc-d6b5-4413-931b-52fb76129e49" name="Changes" comment="" />
|
||||||
|
<created>1699202233917</created>
|
||||||
|
<option name="number" value="Default" />
|
||||||
|
<option name="presentableId" value="Default" />
|
||||||
|
<updated>1699202233917</updated>
|
||||||
|
<workItem from="1699202234933" duration="14451000" />
|
||||||
|
<workItem from="1699298781898" duration="466000" />
|
||||||
|
</task>
|
||||||
|
<servers />
|
||||||
|
</component>
|
||||||
|
<component name="TypeScriptGeneratedFilesManager">
|
||||||
|
<option name="version" value="3" />
|
||||||
|
</component>
|
||||||
|
<component name="Vcs.Log.Tabs.Properties">
|
||||||
|
<option name="TAB_STATES">
|
||||||
|
<map>
|
||||||
|
<entry key="MAIN">
|
||||||
|
<value>
|
||||||
|
<State />
|
||||||
|
</value>
|
||||||
|
</entry>
|
||||||
|
</map>
|
||||||
|
</option>
|
||||||
|
</component>
|
||||||
|
<component name="VcsManagerConfiguration">
|
||||||
|
<option name="CLEAR_INITIAL_COMMIT_MESSAGE" value="true" />
|
||||||
|
</component>
|
||||||
|
</project>
|
||||||
10
.idea/IsleBot.iml
generated
10
.idea/IsleBot.iml
generated
@@ -1,10 +0,0 @@
|
|||||||
<?xml version="1.0" encoding="UTF-8"?>
|
|
||||||
<module type="PYTHON_MODULE" version="4">
|
|
||||||
<component name="NewModuleRootManager">
|
|
||||||
<content url="file://$MODULE_DIR$">
|
|
||||||
<excludeFolder url="file://$MODULE_DIR$/venv" />
|
|
||||||
</content>
|
|
||||||
<orderEntry type="inheritedJdk" />
|
|
||||||
<orderEntry type="sourceFolder" forTests="false" />
|
|
||||||
</component>
|
|
||||||
</module>
|
|
||||||
409
.idea/dbnavigator.xml
generated
409
.idea/dbnavigator.xml
generated
@@ -1,409 +0,0 @@
|
|||||||
<?xml version="1.0" encoding="UTF-8"?>
|
|
||||||
<project version="4">
|
|
||||||
<component name="DBNavigator.Project.DatabaseBrowserManager">
|
|
||||||
<autoscroll-to-editor value="false" />
|
|
||||||
<autoscroll-from-editor value="true" />
|
|
||||||
<show-object-properties value="true" />
|
|
||||||
<loaded-nodes />
|
|
||||||
</component>
|
|
||||||
<component name="DBNavigator.Project.DatabaseFileManager">
|
|
||||||
<open-files />
|
|
||||||
</component>
|
|
||||||
<component name="DBNavigator.Project.Settings">
|
|
||||||
<connections />
|
|
||||||
<browser-settings>
|
|
||||||
<general>
|
|
||||||
<display-mode value="TABBED" />
|
|
||||||
<navigation-history-size value="100" />
|
|
||||||
<show-object-details value="false" />
|
|
||||||
</general>
|
|
||||||
<filters>
|
|
||||||
<object-type-filter>
|
|
||||||
<object-type name="SCHEMA" enabled="true" />
|
|
||||||
<object-type name="USER" enabled="true" />
|
|
||||||
<object-type name="ROLE" enabled="true" />
|
|
||||||
<object-type name="PRIVILEGE" enabled="true" />
|
|
||||||
<object-type name="CHARSET" enabled="true" />
|
|
||||||
<object-type name="TABLE" enabled="true" />
|
|
||||||
<object-type name="VIEW" enabled="true" />
|
|
||||||
<object-type name="MATERIALIZED_VIEW" enabled="true" />
|
|
||||||
<object-type name="NESTED_TABLE" enabled="true" />
|
|
||||||
<object-type name="COLUMN" enabled="true" />
|
|
||||||
<object-type name="INDEX" enabled="true" />
|
|
||||||
<object-type name="CONSTRAINT" enabled="true" />
|
|
||||||
<object-type name="DATASET_TRIGGER" enabled="true" />
|
|
||||||
<object-type name="DATABASE_TRIGGER" enabled="true" />
|
|
||||||
<object-type name="SYNONYM" enabled="true" />
|
|
||||||
<object-type name="SEQUENCE" enabled="true" />
|
|
||||||
<object-type name="PROCEDURE" enabled="true" />
|
|
||||||
<object-type name="FUNCTION" enabled="true" />
|
|
||||||
<object-type name="PACKAGE" enabled="true" />
|
|
||||||
<object-type name="TYPE" enabled="true" />
|
|
||||||
<object-type name="TYPE_ATTRIBUTE" enabled="true" />
|
|
||||||
<object-type name="ARGUMENT" enabled="true" />
|
|
||||||
<object-type name="DIMENSION" enabled="true" />
|
|
||||||
<object-type name="CLUSTER" enabled="true" />
|
|
||||||
<object-type name="DBLINK" enabled="true" />
|
|
||||||
</object-type-filter>
|
|
||||||
</filters>
|
|
||||||
<sorting>
|
|
||||||
<object-type name="COLUMN" sorting-type="NAME" />
|
|
||||||
<object-type name="FUNCTION" sorting-type="NAME" />
|
|
||||||
<object-type name="PROCEDURE" sorting-type="NAME" />
|
|
||||||
<object-type name="ARGUMENT" sorting-type="POSITION" />
|
|
||||||
<object-type name="TYPE ATTRIBUTE" sorting-type="POSITION" />
|
|
||||||
</sorting>
|
|
||||||
<default-editors>
|
|
||||||
<object-type name="VIEW" editor-type="SELECTION" />
|
|
||||||
<object-type name="PACKAGE" editor-type="SELECTION" />
|
|
||||||
<object-type name="TYPE" editor-type="SELECTION" />
|
|
||||||
</default-editors>
|
|
||||||
</browser-settings>
|
|
||||||
<navigation-settings>
|
|
||||||
<lookup-filters>
|
|
||||||
<lookup-objects>
|
|
||||||
<object-type name="SCHEMA" enabled="true" />
|
|
||||||
<object-type name="USER" enabled="false" />
|
|
||||||
<object-type name="ROLE" enabled="false" />
|
|
||||||
<object-type name="PRIVILEGE" enabled="false" />
|
|
||||||
<object-type name="CHARSET" enabled="false" />
|
|
||||||
<object-type name="TABLE" enabled="true" />
|
|
||||||
<object-type name="VIEW" enabled="true" />
|
|
||||||
<object-type name="MATERIALIZED VIEW" enabled="true" />
|
|
||||||
<object-type name="INDEX" enabled="true" />
|
|
||||||
<object-type name="CONSTRAINT" enabled="true" />
|
|
||||||
<object-type name="DATASET TRIGGER" enabled="true" />
|
|
||||||
<object-type name="DATABASE TRIGGER" enabled="true" />
|
|
||||||
<object-type name="SYNONYM" enabled="false" />
|
|
||||||
<object-type name="SEQUENCE" enabled="true" />
|
|
||||||
<object-type name="PROCEDURE" enabled="true" />
|
|
||||||
<object-type name="FUNCTION" enabled="true" />
|
|
||||||
<object-type name="PACKAGE" enabled="true" />
|
|
||||||
<object-type name="TYPE" enabled="true" />
|
|
||||||
<object-type name="DIMENSION" enabled="false" />
|
|
||||||
<object-type name="CLUSTER" enabled="false" />
|
|
||||||
<object-type name="DBLINK" enabled="true" />
|
|
||||||
</lookup-objects>
|
|
||||||
<force-database-load value="false" />
|
|
||||||
<prompt-connection-selection value="true" />
|
|
||||||
<prompt-schema-selection value="true" />
|
|
||||||
</lookup-filters>
|
|
||||||
</navigation-settings>
|
|
||||||
<dataset-grid-settings>
|
|
||||||
<general>
|
|
||||||
<enable-zooming value="true" />
|
|
||||||
<enable-column-tooltip value="true" />
|
|
||||||
</general>
|
|
||||||
<sorting>
|
|
||||||
<nulls-first value="true" />
|
|
||||||
<max-sorting-columns value="4" />
|
|
||||||
</sorting>
|
|
||||||
<audit-columns>
|
|
||||||
<column-names value="" />
|
|
||||||
<visible value="true" />
|
|
||||||
<editable value="false" />
|
|
||||||
</audit-columns>
|
|
||||||
</dataset-grid-settings>
|
|
||||||
<dataset-editor-settings>
|
|
||||||
<text-editor-popup>
|
|
||||||
<active value="false" />
|
|
||||||
<active-if-empty value="false" />
|
|
||||||
<data-length-threshold value="100" />
|
|
||||||
<popup-delay value="1000" />
|
|
||||||
</text-editor-popup>
|
|
||||||
<values-actions-popup>
|
|
||||||
<show-popup-button value="true" />
|
|
||||||
<element-count-threshold value="1000" />
|
|
||||||
<data-length-threshold value="250" />
|
|
||||||
</values-actions-popup>
|
|
||||||
<general>
|
|
||||||
<fetch-block-size value="100" />
|
|
||||||
<fetch-timeout value="30" />
|
|
||||||
<trim-whitespaces value="true" />
|
|
||||||
<convert-empty-strings-to-null value="true" />
|
|
||||||
<select-content-on-cell-edit value="true" />
|
|
||||||
<large-value-preview-active value="true" />
|
|
||||||
</general>
|
|
||||||
<filters>
|
|
||||||
<prompt-filter-dialog value="true" />
|
|
||||||
<default-filter-type value="BASIC" />
|
|
||||||
</filters>
|
|
||||||
<qualified-text-editor text-length-threshold="300">
|
|
||||||
<content-types>
|
|
||||||
<content-type name="Text" enabled="true" />
|
|
||||||
<content-type name="Properties" enabled="true" />
|
|
||||||
<content-type name="XML" enabled="true" />
|
|
||||||
<content-type name="DTD" enabled="true" />
|
|
||||||
<content-type name="HTML" enabled="true" />
|
|
||||||
<content-type name="XHTML" enabled="true" />
|
|
||||||
<content-type name="CSS" enabled="true" />
|
|
||||||
<content-type name="SQL" enabled="true" />
|
|
||||||
<content-type name="PL/SQL" enabled="true" />
|
|
||||||
<content-type name="JavaScript" enabled="true" />
|
|
||||||
<content-type name="JSON" enabled="true" />
|
|
||||||
<content-type name="JSON5" enabled="true" />
|
|
||||||
<content-type name="YAML" enabled="true" />
|
|
||||||
</content-types>
|
|
||||||
</qualified-text-editor>
|
|
||||||
<record-navigation>
|
|
||||||
<navigation-target value="VIEWER" />
|
|
||||||
</record-navigation>
|
|
||||||
</dataset-editor-settings>
|
|
||||||
<code-editor-settings>
|
|
||||||
<general>
|
|
||||||
<show-object-navigation-gutter value="false" />
|
|
||||||
<show-spec-declaration-navigation-gutter value="true" />
|
|
||||||
<enable-spellchecking value="true" />
|
|
||||||
<enable-reference-spellchecking value="false" />
|
|
||||||
</general>
|
|
||||||
<confirmations>
|
|
||||||
<save-changes value="false" />
|
|
||||||
<revert-changes value="true" />
|
|
||||||
</confirmations>
|
|
||||||
</code-editor-settings>
|
|
||||||
<code-completion-settings>
|
|
||||||
<filters>
|
|
||||||
<basic-filter>
|
|
||||||
<filter-element type="RESERVED_WORD" id="keyword" selected="true" />
|
|
||||||
<filter-element type="RESERVED_WORD" id="function" selected="true" />
|
|
||||||
<filter-element type="RESERVED_WORD" id="parameter" selected="true" />
|
|
||||||
<filter-element type="RESERVED_WORD" id="datatype" selected="true" />
|
|
||||||
<filter-element type="RESERVED_WORD" id="exception" selected="true" />
|
|
||||||
<filter-element type="OBJECT" id="schema" selected="true" />
|
|
||||||
<filter-element type="OBJECT" id="role" selected="true" />
|
|
||||||
<filter-element type="OBJECT" id="user" selected="true" />
|
|
||||||
<filter-element type="OBJECT" id="privilege" selected="true" />
|
|
||||||
<user-schema>
|
|
||||||
<filter-element type="OBJECT" id="table" selected="true" />
|
|
||||||
<filter-element type="OBJECT" id="view" selected="true" />
|
|
||||||
<filter-element type="OBJECT" id="materialized view" selected="true" />
|
|
||||||
<filter-element type="OBJECT" id="index" selected="true" />
|
|
||||||
<filter-element type="OBJECT" id="constraint" selected="true" />
|
|
||||||
<filter-element type="OBJECT" id="trigger" selected="true" />
|
|
||||||
<filter-element type="OBJECT" id="synonym" selected="false" />
|
|
||||||
<filter-element type="OBJECT" id="sequence" selected="true" />
|
|
||||||
<filter-element type="OBJECT" id="procedure" selected="true" />
|
|
||||||
<filter-element type="OBJECT" id="function" selected="true" />
|
|
||||||
<filter-element type="OBJECT" id="package" selected="true" />
|
|
||||||
<filter-element type="OBJECT" id="type" selected="true" />
|
|
||||||
<filter-element type="OBJECT" id="dimension" selected="true" />
|
|
||||||
<filter-element type="OBJECT" id="cluster" selected="true" />
|
|
||||||
<filter-element type="OBJECT" id="dblink" selected="true" />
|
|
||||||
</user-schema>
|
|
||||||
<public-schema>
|
|
||||||
<filter-element type="OBJECT" id="table" selected="false" />
|
|
||||||
<filter-element type="OBJECT" id="view" selected="false" />
|
|
||||||
<filter-element type="OBJECT" id="materialized view" selected="false" />
|
|
||||||
<filter-element type="OBJECT" id="index" selected="false" />
|
|
||||||
<filter-element type="OBJECT" id="constraint" selected="false" />
|
|
||||||
<filter-element type="OBJECT" id="trigger" selected="false" />
|
|
||||||
<filter-element type="OBJECT" id="synonym" selected="false" />
|
|
||||||
<filter-element type="OBJECT" id="sequence" selected="false" />
|
|
||||||
<filter-element type="OBJECT" id="procedure" selected="false" />
|
|
||||||
<filter-element type="OBJECT" id="function" selected="false" />
|
|
||||||
<filter-element type="OBJECT" id="package" selected="false" />
|
|
||||||
<filter-element type="OBJECT" id="type" selected="false" />
|
|
||||||
<filter-element type="OBJECT" id="dimension" selected="false" />
|
|
||||||
<filter-element type="OBJECT" id="cluster" selected="false" />
|
|
||||||
<filter-element type="OBJECT" id="dblink" selected="false" />
|
|
||||||
</public-schema>
|
|
||||||
<any-schema>
|
|
||||||
<filter-element type="OBJECT" id="table" selected="true" />
|
|
||||||
<filter-element type="OBJECT" id="view" selected="true" />
|
|
||||||
<filter-element type="OBJECT" id="materialized view" selected="true" />
|
|
||||||
<filter-element type="OBJECT" id="index" selected="true" />
|
|
||||||
<filter-element type="OBJECT" id="constraint" selected="true" />
|
|
||||||
<filter-element type="OBJECT" id="trigger" selected="true" />
|
|
||||||
<filter-element type="OBJECT" id="synonym" selected="true" />
|
|
||||||
<filter-element type="OBJECT" id="sequence" selected="true" />
|
|
||||||
<filter-element type="OBJECT" id="procedure" selected="true" />
|
|
||||||
<filter-element type="OBJECT" id="function" selected="true" />
|
|
||||||
<filter-element type="OBJECT" id="package" selected="true" />
|
|
||||||
<filter-element type="OBJECT" id="type" selected="true" />
|
|
||||||
<filter-element type="OBJECT" id="dimension" selected="true" />
|
|
||||||
<filter-element type="OBJECT" id="cluster" selected="true" />
|
|
||||||
<filter-element type="OBJECT" id="dblink" selected="true" />
|
|
||||||
</any-schema>
|
|
||||||
</basic-filter>
|
|
||||||
<extended-filter>
|
|
||||||
<filter-element type="RESERVED_WORD" id="keyword" selected="true" />
|
|
||||||
<filter-element type="RESERVED_WORD" id="function" selected="true" />
|
|
||||||
<filter-element type="RESERVED_WORD" id="parameter" selected="true" />
|
|
||||||
<filter-element type="RESERVED_WORD" id="datatype" selected="true" />
|
|
||||||
<filter-element type="RESERVED_WORD" id="exception" selected="true" />
|
|
||||||
<filter-element type="OBJECT" id="schema" selected="true" />
|
|
||||||
<filter-element type="OBJECT" id="user" selected="true" />
|
|
||||||
<filter-element type="OBJECT" id="role" selected="true" />
|
|
||||||
<filter-element type="OBJECT" id="privilege" selected="true" />
|
|
||||||
<user-schema>
|
|
||||||
<filter-element type="OBJECT" id="table" selected="true" />
|
|
||||||
<filter-element type="OBJECT" id="view" selected="true" />
|
|
||||||
<filter-element type="OBJECT" id="materialized view" selected="true" />
|
|
||||||
<filter-element type="OBJECT" id="index" selected="true" />
|
|
||||||
<filter-element type="OBJECT" id="constraint" selected="true" />
|
|
||||||
<filter-element type="OBJECT" id="trigger" selected="true" />
|
|
||||||
<filter-element type="OBJECT" id="synonym" selected="true" />
|
|
||||||
<filter-element type="OBJECT" id="sequence" selected="true" />
|
|
||||||
<filter-element type="OBJECT" id="procedure" selected="true" />
|
|
||||||
<filter-element type="OBJECT" id="function" selected="true" />
|
|
||||||
<filter-element type="OBJECT" id="package" selected="true" />
|
|
||||||
<filter-element type="OBJECT" id="type" selected="true" />
|
|
||||||
<filter-element type="OBJECT" id="dimension" selected="true" />
|
|
||||||
<filter-element type="OBJECT" id="cluster" selected="true" />
|
|
||||||
<filter-element type="OBJECT" id="dblink" selected="true" />
|
|
||||||
</user-schema>
|
|
||||||
<public-schema>
|
|
||||||
<filter-element type="OBJECT" id="table" selected="true" />
|
|
||||||
<filter-element type="OBJECT" id="view" selected="true" />
|
|
||||||
<filter-element type="OBJECT" id="materialized view" selected="true" />
|
|
||||||
<filter-element type="OBJECT" id="index" selected="true" />
|
|
||||||
<filter-element type="OBJECT" id="constraint" selected="true" />
|
|
||||||
<filter-element type="OBJECT" id="trigger" selected="true" />
|
|
||||||
<filter-element type="OBJECT" id="synonym" selected="true" />
|
|
||||||
<filter-element type="OBJECT" id="sequence" selected="true" />
|
|
||||||
<filter-element type="OBJECT" id="procedure" selected="true" />
|
|
||||||
<filter-element type="OBJECT" id="function" selected="true" />
|
|
||||||
<filter-element type="OBJECT" id="package" selected="true" />
|
|
||||||
<filter-element type="OBJECT" id="type" selected="true" />
|
|
||||||
<filter-element type="OBJECT" id="dimension" selected="true" />
|
|
||||||
<filter-element type="OBJECT" id="cluster" selected="true" />
|
|
||||||
<filter-element type="OBJECT" id="dblink" selected="true" />
|
|
||||||
</public-schema>
|
|
||||||
<any-schema>
|
|
||||||
<filter-element type="OBJECT" id="table" selected="true" />
|
|
||||||
<filter-element type="OBJECT" id="view" selected="true" />
|
|
||||||
<filter-element type="OBJECT" id="materialized view" selected="true" />
|
|
||||||
<filter-element type="OBJECT" id="index" selected="true" />
|
|
||||||
<filter-element type="OBJECT" id="constraint" selected="true" />
|
|
||||||
<filter-element type="OBJECT" id="trigger" selected="true" />
|
|
||||||
<filter-element type="OBJECT" id="synonym" selected="true" />
|
|
||||||
<filter-element type="OBJECT" id="sequence" selected="true" />
|
|
||||||
<filter-element type="OBJECT" id="procedure" selected="true" />
|
|
||||||
<filter-element type="OBJECT" id="function" selected="true" />
|
|
||||||
<filter-element type="OBJECT" id="package" selected="true" />
|
|
||||||
<filter-element type="OBJECT" id="type" selected="true" />
|
|
||||||
<filter-element type="OBJECT" id="dimension" selected="true" />
|
|
||||||
<filter-element type="OBJECT" id="cluster" selected="true" />
|
|
||||||
<filter-element type="OBJECT" id="dblink" selected="true" />
|
|
||||||
</any-schema>
|
|
||||||
</extended-filter>
|
|
||||||
</filters>
|
|
||||||
<sorting enabled="true">
|
|
||||||
<sorting-element type="RESERVED_WORD" id="keyword" />
|
|
||||||
<sorting-element type="RESERVED_WORD" id="datatype" />
|
|
||||||
<sorting-element type="OBJECT" id="column" />
|
|
||||||
<sorting-element type="OBJECT" id="table" />
|
|
||||||
<sorting-element type="OBJECT" id="view" />
|
|
||||||
<sorting-element type="OBJECT" id="materialized view" />
|
|
||||||
<sorting-element type="OBJECT" id="index" />
|
|
||||||
<sorting-element type="OBJECT" id="constraint" />
|
|
||||||
<sorting-element type="OBJECT" id="trigger" />
|
|
||||||
<sorting-element type="OBJECT" id="synonym" />
|
|
||||||
<sorting-element type="OBJECT" id="sequence" />
|
|
||||||
<sorting-element type="OBJECT" id="procedure" />
|
|
||||||
<sorting-element type="OBJECT" id="function" />
|
|
||||||
<sorting-element type="OBJECT" id="package" />
|
|
||||||
<sorting-element type="OBJECT" id="type" />
|
|
||||||
<sorting-element type="OBJECT" id="dimension" />
|
|
||||||
<sorting-element type="OBJECT" id="cluster" />
|
|
||||||
<sorting-element type="OBJECT" id="dblink" />
|
|
||||||
<sorting-element type="OBJECT" id="schema" />
|
|
||||||
<sorting-element type="OBJECT" id="role" />
|
|
||||||
<sorting-element type="OBJECT" id="user" />
|
|
||||||
<sorting-element type="RESERVED_WORD" id="function" />
|
|
||||||
<sorting-element type="RESERVED_WORD" id="parameter" />
|
|
||||||
</sorting>
|
|
||||||
<format>
|
|
||||||
<enforce-code-style-case value="true" />
|
|
||||||
</format>
|
|
||||||
</code-completion-settings>
|
|
||||||
<execution-engine-settings>
|
|
||||||
<statement-execution>
|
|
||||||
<fetch-block-size value="100" />
|
|
||||||
<execution-timeout value="20" />
|
|
||||||
<debug-execution-timeout value="600" />
|
|
||||||
<focus-result value="false" />
|
|
||||||
<prompt-execution value="false" />
|
|
||||||
</statement-execution>
|
|
||||||
<script-execution>
|
|
||||||
<command-line-interfaces />
|
|
||||||
<execution-timeout value="300" />
|
|
||||||
</script-execution>
|
|
||||||
<method-execution>
|
|
||||||
<execution-timeout value="30" />
|
|
||||||
<debug-execution-timeout value="600" />
|
|
||||||
<parameter-history-size value="10" />
|
|
||||||
</method-execution>
|
|
||||||
</execution-engine-settings>
|
|
||||||
<operation-settings>
|
|
||||||
<transactions>
|
|
||||||
<uncommitted-changes>
|
|
||||||
<on-project-close value="ASK" />
|
|
||||||
<on-disconnect value="ASK" />
|
|
||||||
<on-autocommit-toggle value="ASK" />
|
|
||||||
</uncommitted-changes>
|
|
||||||
<multiple-uncommitted-changes>
|
|
||||||
<on-commit value="ASK" />
|
|
||||||
<on-rollback value="ASK" />
|
|
||||||
</multiple-uncommitted-changes>
|
|
||||||
</transactions>
|
|
||||||
<session-browser>
|
|
||||||
<disconnect-session value="ASK" />
|
|
||||||
<kill-session value="ASK" />
|
|
||||||
<reload-on-filter-change value="false" />
|
|
||||||
</session-browser>
|
|
||||||
<compiler>
|
|
||||||
<compile-type value="KEEP" />
|
|
||||||
<compile-dependencies value="ASK" />
|
|
||||||
<always-show-controls value="false" />
|
|
||||||
</compiler>
|
|
||||||
<debugger>
|
|
||||||
<debugger-type value="JDBC" />
|
|
||||||
</debugger>
|
|
||||||
</operation-settings>
|
|
||||||
<ddl-file-settings>
|
|
||||||
<extensions>
|
|
||||||
<mapping file-type-id="VIEW" extensions="vw" />
|
|
||||||
<mapping file-type-id="TRIGGER" extensions="trg" />
|
|
||||||
<mapping file-type-id="PROCEDURE" extensions="prc" />
|
|
||||||
<mapping file-type-id="FUNCTION" extensions="fnc" />
|
|
||||||
<mapping file-type-id="PACKAGE" extensions="pkg" />
|
|
||||||
<mapping file-type-id="PACKAGE_SPEC" extensions="pks" />
|
|
||||||
<mapping file-type-id="PACKAGE_BODY" extensions="pkb" />
|
|
||||||
<mapping file-type-id="TYPE" extensions="tpe" />
|
|
||||||
<mapping file-type-id="TYPE_SPEC" extensions="tps" />
|
|
||||||
<mapping file-type-id="TYPE_BODY" extensions="tpb" />
|
|
||||||
</extensions>
|
|
||||||
<general>
|
|
||||||
<lookup-ddl-files value="true" />
|
|
||||||
<create-ddl-files value="false" />
|
|
||||||
<synchronize-ddl-files value="true" />
|
|
||||||
<use-qualified-names value="false" />
|
|
||||||
<make-scripts-rerunnable value="true" />
|
|
||||||
</general>
|
|
||||||
</ddl-file-settings>
|
|
||||||
<general-settings>
|
|
||||||
<regional-settings>
|
|
||||||
<date-format value="MEDIUM" />
|
|
||||||
<number-format value="UNGROUPED" />
|
|
||||||
<locale value="SYSTEM_DEFAULT" />
|
|
||||||
<use-custom-formats value="false" />
|
|
||||||
</regional-settings>
|
|
||||||
<environment>
|
|
||||||
<environment-types>
|
|
||||||
<environment-type id="development" name="Development" description="Development environment" color="-2430209/-12296320" readonly-code="false" readonly-data="false" />
|
|
||||||
<environment-type id="integration" name="Integration" description="Integration environment" color="-2621494/-12163514" readonly-code="true" readonly-data="false" />
|
|
||||||
<environment-type id="production" name="Production" description="Productive environment" color="-11574/-10271420" readonly-code="true" readonly-data="true" />
|
|
||||||
<environment-type id="other" name="Other" description="" color="-1576/-10724543" readonly-code="false" readonly-data="false" />
|
|
||||||
</environment-types>
|
|
||||||
<visibility-settings>
|
|
||||||
<connection-tabs value="true" />
|
|
||||||
<dialog-headers value="true" />
|
|
||||||
<object-editor-tabs value="true" />
|
|
||||||
<script-editor-tabs value="false" />
|
|
||||||
<execution-result-tabs value="true" />
|
|
||||||
</visibility-settings>
|
|
||||||
</environment>
|
|
||||||
</general-settings>
|
|
||||||
</component>
|
|
||||||
</project>
|
|
||||||
54
.idea/inspectionProfiles/Project_Default.xml
generated
54
.idea/inspectionProfiles/Project_Default.xml
generated
@@ -1,54 +0,0 @@
|
|||||||
<component name="InspectionProjectProfileManager">
|
|
||||||
<profile version="1.0">
|
|
||||||
<option name="myName" value="Project Default" />
|
|
||||||
<inspection_tool class="PyPackageRequirementsInspection" enabled="true" level="WARNING" enabled_by_default="true">
|
|
||||||
<option name="ignoredPackages">
|
|
||||||
<value>
|
|
||||||
<list size="33">
|
|
||||||
<item index="0" class="java.lang.String" itemvalue="alembic" />
|
|
||||||
<item index="1" class="java.lang.String" itemvalue="greenlet" />
|
|
||||||
<item index="2" class="java.lang.String" itemvalue="networkx" />
|
|
||||||
<item index="3" class="java.lang.String" itemvalue="async-timeout" />
|
|
||||||
<item index="4" class="java.lang.String" itemvalue="SQLAlchemy" />
|
|
||||||
<item index="5" class="java.lang.String" itemvalue="imageio-ffmpeg" />
|
|
||||||
<item index="6" class="java.lang.String" itemvalue="python-dotenv" />
|
|
||||||
<item index="7" class="java.lang.String" itemvalue="MarkupSafe" />
|
|
||||||
<item index="8" class="java.lang.String" itemvalue="numpy" />
|
|
||||||
<item index="9" class="java.lang.String" itemvalue="requests" />
|
|
||||||
<item index="10" class="java.lang.String" itemvalue="torchvision" />
|
|
||||||
<item index="11" class="java.lang.String" itemvalue="Jinja2" />
|
|
||||||
<item index="12" class="java.lang.String" itemvalue="frozenlist" />
|
|
||||||
<item index="13" class="java.lang.String" itemvalue="filelock" />
|
|
||||||
<item index="14" class="java.lang.String" itemvalue="certifi" />
|
|
||||||
<item index="15" class="java.lang.String" itemvalue="urllib3" />
|
|
||||||
<item index="16" class="java.lang.String" itemvalue="sympy" />
|
|
||||||
<item index="17" class="java.lang.String" itemvalue="torchaudio" />
|
|
||||||
<item index="18" class="java.lang.String" itemvalue="ffmpeg-python" />
|
|
||||||
<item index="19" class="java.lang.String" itemvalue="torch" />
|
|
||||||
<item index="20" class="java.lang.String" itemvalue="attrs" />
|
|
||||||
<item index="21" class="java.lang.String" itemvalue="future" />
|
|
||||||
<item index="22" class="java.lang.String" itemvalue="mpmath" />
|
|
||||||
<item index="23" class="java.lang.String" itemvalue="typing_extensions" />
|
|
||||||
<item index="24" class="java.lang.String" itemvalue="charset-normalizer" />
|
|
||||||
<item index="25" class="java.lang.String" itemvalue="aiohttp" />
|
|
||||||
<item index="26" class="java.lang.String" itemvalue="multidict" />
|
|
||||||
<item index="27" class="java.lang.String" itemvalue="yarl" />
|
|
||||||
<item index="28" class="java.lang.String" itemvalue="Mako" />
|
|
||||||
<item index="29" class="java.lang.String" itemvalue="aiosignal" />
|
|
||||||
<item index="30" class="java.lang.String" itemvalue="idna" />
|
|
||||||
<item index="31" class="java.lang.String" itemvalue="Pillow" />
|
|
||||||
<item index="32" class="java.lang.String" itemvalue="py-cord" />
|
|
||||||
</list>
|
|
||||||
</value>
|
|
||||||
</option>
|
|
||||||
</inspection_tool>
|
|
||||||
<inspection_tool class="PyPep8NamingInspection" enabled="false" level="WEAK WARNING" enabled_by_default="false" />
|
|
||||||
<inspection_tool class="PyUnresolvedReferencesInspection" enabled="true" level="WARNING" enabled_by_default="true">
|
|
||||||
<option name="ignoredIdentifiers">
|
|
||||||
<list>
|
|
||||||
<option value="intents" />
|
|
||||||
</list>
|
|
||||||
</option>
|
|
||||||
</inspection_tool>
|
|
||||||
</profile>
|
|
||||||
</component>
|
|
||||||
6
.idea/inspectionProfiles/profiles_settings.xml
generated
6
.idea/inspectionProfiles/profiles_settings.xml
generated
@@ -1,6 +0,0 @@
|
|||||||
<component name="InspectionProjectProfileManager">
|
|
||||||
<settings>
|
|
||||||
<option name="USE_PROJECT_PROFILE" value="false" />
|
|
||||||
<version value="1.0" />
|
|
||||||
</settings>
|
|
||||||
</component>
|
|
||||||
7
.idea/misc.xml
generated
7
.idea/misc.xml
generated
@@ -1,7 +0,0 @@
|
|||||||
<?xml version="1.0" encoding="UTF-8"?>
|
|
||||||
<project version="4">
|
|
||||||
<component name="Black">
|
|
||||||
<option name="sdkName" value="Python 3.11 (IsleBot)" />
|
|
||||||
</component>
|
|
||||||
<component name="ProjectRootManager" version="2" project-jdk-name="Python 3.11 (IsleBot)" project-jdk-type="Python SDK" />
|
|
||||||
</project>
|
|
||||||
8
.idea/modules.xml
generated
8
.idea/modules.xml
generated
@@ -1,8 +0,0 @@
|
|||||||
<?xml version="1.0" encoding="UTF-8"?>
|
|
||||||
<project version="4">
|
|
||||||
<component name="ProjectModuleManager">
|
|
||||||
<modules>
|
|
||||||
<module fileurl="file://$PROJECT_DIR$/.idea/IsleBot.iml" filepath="$PROJECT_DIR$/.idea/IsleBot.iml" />
|
|
||||||
</modules>
|
|
||||||
</component>
|
|
||||||
</project>
|
|
||||||
23
Card.cs
Normal file
23
Card.cs
Normal file
@@ -0,0 +1,23 @@
|
|||||||
|
namespace IsleBot;
|
||||||
|
|
||||||
|
public class Card
|
||||||
|
{
|
||||||
|
public string Name { get; set; }
|
||||||
|
public int Attack { get; set; }
|
||||||
|
public int Defense { get; set; }
|
||||||
|
public int MaxHealth { get; set; }
|
||||||
|
public int CurrentHealth { get; set; }
|
||||||
|
|
||||||
|
public override string ToString() {
|
||||||
|
return $"{Name} ATK: {Attack} DEF: {Defense} HP: {CurrentHealth}/{MaxHealth}";
|
||||||
|
}
|
||||||
|
|
||||||
|
public Card(string name, int attack, int defense, int maxHealth) {
|
||||||
|
Name = name;
|
||||||
|
Attack = attack;
|
||||||
|
Defense = defense;
|
||||||
|
MaxHealth = maxHealth;
|
||||||
|
CurrentHealth = maxHealth;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
25
Card.py
25
Card.py
@@ -1,25 +0,0 @@
|
|||||||
import string
|
|
||||||
|
|
||||||
|
|
||||||
class Card:
|
|
||||||
id: int = 0
|
|
||||||
name: string = ""
|
|
||||||
attack: int = 0
|
|
||||||
defence: int = 0
|
|
||||||
currHp: int = 0
|
|
||||||
maxHp: int = 0
|
|
||||||
|
|
||||||
def __init__(self, id: int, name: string, attack: int, defense: int):
|
|
||||||
self.id = id
|
|
||||||
self.name = name
|
|
||||||
self.attack = attack
|
|
||||||
self.defense = defense
|
|
||||||
|
|
||||||
def __str__(self):
|
|
||||||
return f"Card: {self.name} - Attack: {self.attack} - Defense: {self.defense}"
|
|
||||||
|
|
||||||
def Attack(self, card):
|
|
||||||
# current formula being sustained damage = attack - own card defence
|
|
||||||
card.currHp -= (self.attack-card.defense)
|
|
||||||
# might want to expand with crits and dice rolls to make it more fun
|
|
||||||
|
|
||||||
11
Config.cs
Normal file
11
Config.cs
Normal file
@@ -0,0 +1,11 @@
|
|||||||
|
namespace IsleBot;
|
||||||
|
|
||||||
|
public class Config
|
||||||
|
{
|
||||||
|
public string DiscordToken { get; set; }
|
||||||
|
|
||||||
|
public Config(string discordToken)
|
||||||
|
{
|
||||||
|
DiscordToken = discordToken;
|
||||||
|
}
|
||||||
|
}
|
||||||
21
DbManager.cs
Normal file
21
DbManager.cs
Normal file
@@ -0,0 +1,21 @@
|
|||||||
|
using Microsoft.EntityFrameworkCore;
|
||||||
|
using System;
|
||||||
|
using System.Collections.Generic;
|
||||||
|
|
||||||
|
namespace IsleBot;
|
||||||
|
|
||||||
|
public class DbManager : DbContext {
|
||||||
|
public DbSet<User> Players { get; set; }
|
||||||
|
public DbSet<Card> Cards { get; set; }
|
||||||
|
public DbSet<Match> Matches { get; set; }
|
||||||
|
|
||||||
|
public string dbpath { get; } = "database.db";
|
||||||
|
|
||||||
|
public DbManager() {
|
||||||
|
var fullPath = Environment.CurrentDirectory + Path.DirectorySeparatorChar + dbpath;
|
||||||
|
dbpath = fullPath;
|
||||||
|
}
|
||||||
|
|
||||||
|
protected override void OnConfiguring(DbContextOptionsBuilder optionsBuilder)
|
||||||
|
=> optionsBuilder.UseSqlite($"Data Source={dbpath}");
|
||||||
|
}
|
||||||
8
EStatus.cs
Normal file
8
EStatus.cs
Normal file
@@ -0,0 +1,8 @@
|
|||||||
|
namespace IsleBot;
|
||||||
|
|
||||||
|
public enum EStatus
|
||||||
|
{
|
||||||
|
NotStarted,
|
||||||
|
InProgress,
|
||||||
|
Finished
|
||||||
|
}
|
||||||
22
IsleBot.csproj
Normal file
22
IsleBot.csproj
Normal file
@@ -0,0 +1,22 @@
|
|||||||
|
<Project Sdk="Microsoft.NET.Sdk">
|
||||||
|
|
||||||
|
<PropertyGroup>
|
||||||
|
<OutputType>Exe</OutputType>
|
||||||
|
<TargetFramework>net7.0</TargetFramework>
|
||||||
|
<ImplicitUsings>enable</ImplicitUsings>
|
||||||
|
<Nullable>enable</Nullable>
|
||||||
|
</PropertyGroup>
|
||||||
|
|
||||||
|
<ItemGroup>
|
||||||
|
<PackageReference Include="Discord.Net" Version="3.12.0" />
|
||||||
|
<PackageReference Include="Microsoft.EntityFrameworkCore" Version="7.0.13" />
|
||||||
|
<PackageReference Include="Microsoft.EntityFrameworkCore.Sqlite" Version="7.0.13" />
|
||||||
|
</ItemGroup>
|
||||||
|
|
||||||
|
<ItemGroup>
|
||||||
|
<None Update="config.json">
|
||||||
|
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
|
||||||
|
</None>
|
||||||
|
</ItemGroup>
|
||||||
|
|
||||||
|
</Project>
|
||||||
16
IsleBot.sln
Normal file
16
IsleBot.sln
Normal file
@@ -0,0 +1,16 @@
|
|||||||
|
|
||||||
|
Microsoft Visual Studio Solution File, Format Version 12.00
|
||||||
|
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "IsleBot", "IsleBot.csproj", "{86009AAF-9139-4B36-97FF-8531E01209B4}"
|
||||||
|
EndProject
|
||||||
|
Global
|
||||||
|
GlobalSection(SolutionConfigurationPlatforms) = preSolution
|
||||||
|
Debug|Any CPU = Debug|Any CPU
|
||||||
|
Release|Any CPU = Release|Any CPU
|
||||||
|
EndGlobalSection
|
||||||
|
GlobalSection(ProjectConfigurationPlatforms) = postSolution
|
||||||
|
{86009AAF-9139-4B36-97FF-8531E01209B4}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
|
||||||
|
{86009AAF-9139-4B36-97FF-8531E01209B4}.Debug|Any CPU.Build.0 = Debug|Any CPU
|
||||||
|
{86009AAF-9139-4B36-97FF-8531E01209B4}.Release|Any CPU.ActiveCfg = Release|Any CPU
|
||||||
|
{86009AAF-9139-4B36-97FF-8531E01209B4}.Release|Any CPU.Build.0 = Release|Any CPU
|
||||||
|
EndGlobalSection
|
||||||
|
EndGlobal
|
||||||
17
Match.cs
Normal file
17
Match.cs
Normal file
@@ -0,0 +1,17 @@
|
|||||||
|
using Microsoft.EntityFrameworkCore;
|
||||||
|
|
||||||
|
namespace IsleBot;
|
||||||
|
|
||||||
|
public class Match {
|
||||||
|
public int MatchId { get; set; }
|
||||||
|
|
||||||
|
public User PlayerA { get; set; }
|
||||||
|
public Card PlayerACard { get; set; }
|
||||||
|
|
||||||
|
public User PlayerB { get; set; }
|
||||||
|
public Card PlayerBCard { get; set; }
|
||||||
|
|
||||||
|
public int PlayedTurns { get; set; }
|
||||||
|
|
||||||
|
public EStatus Status { get; set; }
|
||||||
|
}
|
||||||
24
Player.py
24
Player.py
@@ -1,24 +0,0 @@
|
|||||||
import string
|
|
||||||
|
|
||||||
from Card import Card
|
|
||||||
|
|
||||||
|
|
||||||
class Player:
|
|
||||||
id: string = ""
|
|
||||||
name: string = ""
|
|
||||||
activeCard: Card = None
|
|
||||||
|
|
||||||
|
|
||||||
def __init__(self, id: string, name: string):
|
|
||||||
self.id = id
|
|
||||||
self.Name = name
|
|
||||||
|
|
||||||
def __str__(self):
|
|
||||||
return f"Player: {self.Name} - ID: {self.id}"
|
|
||||||
|
|
||||||
def setActiveCard(self, card: Card):
|
|
||||||
self.activeCard = card
|
|
||||||
|
|
||||||
def getActiveCard(self):
|
|
||||||
return self.activeCard
|
|
||||||
|
|
||||||
102
Program.cs
Normal file
102
Program.cs
Normal file
@@ -0,0 +1,102 @@
|
|||||||
|
using Discord;
|
||||||
|
using Discord.Net;
|
||||||
|
using Discord.WebSocket;
|
||||||
|
using Newtonsoft.Json;
|
||||||
|
|
||||||
|
namespace IsleBot;
|
||||||
|
|
||||||
|
public class IsleBot {
|
||||||
|
private Config config;
|
||||||
|
private DiscordSocketClient client;
|
||||||
|
Random rng = new Random();
|
||||||
|
|
||||||
|
public static Task Main(string[] args) {
|
||||||
|
var config = JsonConvert.DeserializeObject<Config>(File.ReadAllText("Config.json"));
|
||||||
|
var islebot = new IsleBot(config);
|
||||||
|
return islebot.MainAsync();
|
||||||
|
}
|
||||||
|
|
||||||
|
public async Task MainAsync() {
|
||||||
|
client = new DiscordSocketClient(
|
||||||
|
new DiscordSocketConfig {
|
||||||
|
LogLevel = LogSeverity.Info,
|
||||||
|
MessageCacheSize = 500,
|
||||||
|
GatewayIntents = GatewayIntents.AllUnprivileged
|
||||||
|
}
|
||||||
|
);
|
||||||
|
|
||||||
|
client.Log += Log;
|
||||||
|
client.Connected += () => {
|
||||||
|
Console.WriteLine("Connection Estabilished");
|
||||||
|
return Task.CompletedTask;
|
||||||
|
};
|
||||||
|
client.Disconnected += (e) => {
|
||||||
|
Console.WriteLine("Connection Lost");
|
||||||
|
return Task.CompletedTask;
|
||||||
|
};
|
||||||
|
|
||||||
|
client.Ready += Client_OnReady;
|
||||||
|
|
||||||
|
client.SlashCommandExecuted += SlashCommandHandler;
|
||||||
|
|
||||||
|
await client.LoginAsync(TokenType.Bot, config.DiscordToken);
|
||||||
|
await client.StartAsync();
|
||||||
|
// Block this task until the program is closed.
|
||||||
|
await Task.Delay(-1);
|
||||||
|
}
|
||||||
|
|
||||||
|
private async Task Client_OnReady() {
|
||||||
|
client.Guilds.ToList().ForEach(guild =>
|
||||||
|
{
|
||||||
|
var guildGetCard = new SlashCommandBuilder()
|
||||||
|
.WithName("get-card")
|
||||||
|
.WithDescription("Get/Replace your current card");
|
||||||
|
|
||||||
|
var attackCommand = new SlashCommandBuilder()
|
||||||
|
.WithName("attack")
|
||||||
|
.WithDescription("Attack a player")
|
||||||
|
.AddOption("target", ApplicationCommandOptionType.User, "The target of the attack");
|
||||||
|
|
||||||
|
try {
|
||||||
|
guild.CreateApplicationCommandAsync(guildGetCard.Build());
|
||||||
|
guild.CreateApplicationCommandAsync(attackCommand.Build());
|
||||||
|
} catch (HttpException exception) {
|
||||||
|
var json = JsonConvert.SerializeObject(exception.Errors, Formatting.Indented);
|
||||||
|
Console.WriteLine(json);
|
||||||
|
}
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
private async Task SlashCommandHandler(SocketSlashCommand command) {
|
||||||
|
switch (command.Data.Name) {
|
||||||
|
case "get-card":
|
||||||
|
var card = GenerateCard();
|
||||||
|
await command.RespondAsync("You got a new card!\n " + card);
|
||||||
|
break;
|
||||||
|
case "attack":
|
||||||
|
var target = command.Data.Options.First().Value as SocketUser;
|
||||||
|
await command.RespondAsync($"You attacked {target.Username}!");
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
private Card GenerateCard() {
|
||||||
|
var card = new Card($"Test Card N. {rng.Next(0, 1000)}",
|
||||||
|
rng.Next(1, 20), rng.Next(0, 10),
|
||||||
|
rng.Next(25, 100));
|
||||||
|
return card;
|
||||||
|
}
|
||||||
|
|
||||||
|
private void Attack(ref Card attacker, ref Card defender) {
|
||||||
|
defender.CurrentHealth -= Math.Clamp(attacker.Attack - defender.Defense, 0, int.MaxValue);
|
||||||
|
}
|
||||||
|
|
||||||
|
private Task Log(LogMessage msg) {
|
||||||
|
Console.WriteLine(msg.ToString());
|
||||||
|
return Task.CompletedTask;
|
||||||
|
}
|
||||||
|
|
||||||
|
public IsleBot(Config config) {
|
||||||
|
this.config = config;
|
||||||
|
}
|
||||||
|
}
|
||||||
14
User.cs
Normal file
14
User.cs
Normal file
@@ -0,0 +1,14 @@
|
|||||||
|
namespace IsleBot;
|
||||||
|
|
||||||
|
public class User
|
||||||
|
{
|
||||||
|
public int Id { get; private set; }
|
||||||
|
public string UserName { get; set; }
|
||||||
|
public List<Card> Cards { get; set; }
|
||||||
|
|
||||||
|
public User(int id, string userName) {
|
||||||
|
Id = id;
|
||||||
|
UserName = userName;
|
||||||
|
Cards = new List<Card>();
|
||||||
|
}
|
||||||
|
}
|
||||||
1
config.json
Normal file
1
config.json
Normal file
@@ -0,0 +1 @@
|
|||||||
|
{ "DiscordToken": "YourTokenHere" }
|
||||||
95
main.py
95
main.py
@@ -1,95 +0,0 @@
|
|||||||
import os
|
|
||||||
import random
|
|
||||||
import dotenv
|
|
||||||
import discord
|
|
||||||
|
|
||||||
from Card import Card
|
|
||||||
from Player import Player
|
|
||||||
|
|
||||||
|
|
||||||
dotenv.load_dotenv()
|
|
||||||
token = os.getenv("TOKEN")
|
|
||||||
#intents: discord.Intents = discord.Intents.default()
|
|
||||||
#intents.guilds = True
|
|
||||||
#intents.members = True
|
|
||||||
#intents.messages = True
|
|
||||||
#intents.message_content = True
|
|
||||||
|
|
||||||
bot = discord.Bot()
|
|
||||||
rng = random.Random()
|
|
||||||
players = []
|
|
||||||
|
|
||||||
@bot.event
|
|
||||||
async def on_ready():
|
|
||||||
print("Bot loaded")
|
|
||||||
|
|
||||||
@bot.event
|
|
||||||
async def on_message(message):
|
|
||||||
# Prevents bot from responding to itself
|
|
||||||
if message.author == bot.user:
|
|
||||||
return
|
|
||||||
|
|
||||||
if message.content.startswith("!hello"):
|
|
||||||
await message.channel.send("Hello!")
|
|
||||||
return
|
|
||||||
|
|
||||||
@bot.slash_command(name="get-card", description="Get a random card")
|
|
||||||
async def getCard(ctx: discord.ApplicationContext):
|
|
||||||
sender = ctx.author
|
|
||||||
player = Player(sender.id, sender.name)
|
|
||||||
player.activeCard = Card(1, f"TestCard {rng.randint(0, 1999)}", rng.randint(2,20), rng.randint(0,5))
|
|
||||||
|
|
||||||
for p in players:
|
|
||||||
if p.id == player.id:
|
|
||||||
p.activeCard = player.activeCard
|
|
||||||
await ctx.respond(f"You already have a card, swapping it...\nYour new card is: \n {p.activeCard}")
|
|
||||||
return
|
|
||||||
players.append(player)
|
|
||||||
await ctx.respond(f"Your card is: \n {player.activeCard}")
|
|
||||||
return
|
|
||||||
|
|
||||||
@bot.slash_command(name="attack", description="Attack another player")
|
|
||||||
async def attackPlayer(ctx: discord.ApplicationContext, target: discord.Member):
|
|
||||||
attacker: Player = None
|
|
||||||
defender: Player = None
|
|
||||||
|
|
||||||
if target == ctx.author:
|
|
||||||
await ctx.respond("You can't attack yourself!")
|
|
||||||
return
|
|
||||||
|
|
||||||
if target.bot:
|
|
||||||
await ctx.respond("You can't attack a bot!")
|
|
||||||
return
|
|
||||||
|
|
||||||
for p in players:
|
|
||||||
if p.id == ctx.author.id:
|
|
||||||
attacker = p
|
|
||||||
if p.activeCard == None:
|
|
||||||
await ctx.respond("You don't have a card! Generate one first!")
|
|
||||||
return
|
|
||||||
break
|
|
||||||
|
|
||||||
for p in players:
|
|
||||||
if p.id == target.id:
|
|
||||||
defender = p
|
|
||||||
if p.activeCard == None:
|
|
||||||
await ctx.respond("That player doesn't have a card! Tell him to generate one first!")
|
|
||||||
return
|
|
||||||
break
|
|
||||||
|
|
||||||
if attacker is None or defender is None:
|
|
||||||
await ctx.respond(f"can't find a match... attacker: {attacker} defender: {defender}")
|
|
||||||
return
|
|
||||||
|
|
||||||
attacker.activeCard.Attack(defender.activeCard)
|
|
||||||
|
|
||||||
if defender.activeCard.currHp <= 0:
|
|
||||||
await ctx.respond(f"{attacker.Name} attacked {defender.Name} and killed his card!")
|
|
||||||
players.remove(defender)
|
|
||||||
return
|
|
||||||
else:
|
|
||||||
await ctx.respond(f"{attacker.Name} attacked {defender.Name}! {defender.Name}'s card has {defender.activeCard.currHp} hp left!")
|
|
||||||
await ctx.send(f"Battle Status:\n{attacker.Name}'s card: {attacker.activeCard.currHp} hp left\n{defender.Name}'s card: {defender.activeCard.currHp} hp left")
|
|
||||||
return
|
|
||||||
|
|
||||||
bot.run(token)
|
|
||||||
BIN
requirements.txt
BIN
requirements.txt
Binary file not shown.
Reference in New Issue
Block a user