Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Restructure #380

Draft
wants to merge 475 commits into
base: mainline
Choose a base branch
from
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
475 commits
Select commit Hold shift + click to select a range
cd266dc
Update Skill.js
theBGuy Aug 21, 2023
9940079
Update UserAddon.js
theBGuy Aug 21, 2023
baf056c
Update Pickit.js
theBGuy Aug 21, 2023
7b5cfe9
include gameReady check
theBGuy Aug 21, 2023
72efec5
Create PubJoinConfig.js
theBGuy Aug 21, 2023
aba0bad
Create FollowConfig.js
theBGuy Aug 21, 2023
2c6222a
Update D2BotPubJoin.dbj
theBGuy Aug 21, 2023
52c1602
Update D2BotPubJoin.dbj
theBGuy Aug 21, 2023
8996c0d
Update SimpleParty.js
theBGuy Aug 22, 2023
5f8a123
Update Locations.js
theBGuy Aug 22, 2023
1c2eee1
Update Pickit.js
theBGuy Aug 22, 2023
2c98287
Update D2BotFollow.dbj
theBGuy Aug 22, 2023
3434e2d
Update globals.d.ts
theBGuy Aug 22, 2023
d5f0ca5
Update D2BotPubJoin.dbj
theBGuy Aug 22, 2023
562493b
Update D2BotLead.dbj
theBGuy Aug 22, 2023
9e730bb
Update D2BotMuleLog.dbj
theBGuy Aug 22, 2023
ba22248
Add SkillCycloneArmor stat to sdk
theBGuy Aug 22, 2023
d1194f5
Update Precast.js
theBGuy Aug 22, 2023
5350096
Update SkillData.js
theBGuy Aug 22, 2023
f7bc61b
Update Skill.js
theBGuy Aug 22, 2023
c6786d8
Update Precast.js
theBGuy Aug 22, 2023
af126ab
Update Skill.d.ts
theBGuy Aug 22, 2023
111871f
Create ChannelConfig.js
theBGuy Aug 23, 2023
1e4776c
Update D2BotChannel.dbj
theBGuy Aug 23, 2023
9659a29
Update Locations.js
theBGuy Aug 23, 2023
300fe62
Update D2BotGameAction.dbj
theBGuy Aug 23, 2023
992d613
Update D2BotChannel.dbj
theBGuy Aug 23, 2023
8b91a98
Update D2BotChannel.dbj
theBGuy Aug 23, 2023
6c70de8
automule configs -> `automule/config`
theBGuy Aug 24, 2023
cf5f907
move mule specific methods into own file
theBGuy Aug 24, 2023
ed3befe
Create main.js
theBGuy Aug 24, 2023
8356bf6
Update D2BotMule.dbj
theBGuy Aug 24, 2023
5f41636
Update AutoMule.d.ts
theBGuy Aug 24, 2023
39b872a
move mapthread into root of manualplay dir
theBGuy Aug 24, 2023
95e7d53
rename mapthread -> main.js
theBGuy Aug 24, 2023
f82cd26
small bit of cleanup with the name change
theBGuy Aug 24, 2023
0d37805
Update default.dbj
theBGuy Aug 24, 2023
7909c65
Update D2BotMule.dbj
theBGuy Aug 24, 2023
b405e43
Update D2BotMap.dbj
theBGuy Aug 24, 2023
9baa625
update workers to check for main.js
theBGuy Aug 24, 2023
88fed5c
Update main.js
theBGuy Aug 24, 2023
739ef54
Update Town.js
theBGuy Aug 24, 2023
372110f
Update Town.js
theBGuy Aug 24, 2023
d717516
Update main.js
theBGuy Aug 24, 2023
37d4f87
typedefs
theBGuy Aug 25, 2023
59917a3
add String prototypes `at` and `unshift`
theBGuy Aug 25, 2023
18cebb7
Update NTItemParser.js
theBGuy Aug 25, 2023
d3cb013
Update NTItemParser.js
theBGuy Aug 26, 2023
1ffa53d
Update NTItemParser.js
theBGuy Aug 26, 2023
4054d06
little bit of formatting
theBGuy Aug 26, 2023
1068414
Fix getting inital mule data
theBGuy Aug 28, 2023
ac312dc
Update Baal.js
theBGuy Aug 29, 2023
12d405b
Update D2BotGameAction.dbj
theBGuy Aug 30, 2023
a206cc8
Update D2BotMule.dbj
theBGuy Aug 30, 2023
b6ef7c7
Update D2BotMuleLog.dbj
theBGuy Aug 30, 2023
31942c8
Update D2BotMuleLog.dbj
theBGuy Aug 31, 2023
ba8993f
Update OOG.js
theBGuy Sep 2, 2023
9ae0999
Update DataFile.js
theBGuy Sep 3, 2023
4d95436
Update Locations.js
theBGuy Sep 3, 2023
1d037d6
Update D2BotLead.dbj
theBGuy Sep 3, 2023
311f6e3
Update D2BotFollow.dbj
theBGuy Sep 3, 2023
dafae9a
Update Polyfill.js
theBGuy Sep 3, 2023
654b404
Create Idle.js
theBGuy Sep 3, 2023
33beec5
Update NTItemAlias.js
theBGuy Sep 3, 2023
37d1bcd
Update Me.js
theBGuy Sep 4, 2023
8557c7c
update with new `me` methods
theBGuy Sep 4, 2023
0b80b98
create NPC.js
theBGuy Sep 4, 2023
e046c34
small bits of formatting
theBGuy Sep 4, 2023
acc016f
Update Me.js
theBGuy Sep 4, 2023
9529061
Update D2BotFollow.dbj
theBGuy Sep 5, 2023
b19d28a
Update TownChicken.js
theBGuy Sep 5, 2023
a32de9d
Update Me.js
theBGuy Sep 6, 2023
bf39bbb
skip announcing kill/clear/goTo while running dia/baa
theBGuy Sep 6, 2023
57e585f
Update D2BotFollow.dbj
theBGuy Sep 6, 2023
2776327
Update Pickit.js
theBGuy Sep 6, 2023
5927989
create autorush system directory
theBGuy Sep 6, 2023
2a9adb3
Update ControlBot
theBGuy Sep 6, 2023
8602384
Change `ConfigMaxGameTime` to use minutes
theBGuy Sep 6, 2023
4cbc0a5
Update ControlBot.js
theBGuy Sep 7, 2023
dc45dda
Update Loader.js
theBGuy Sep 8, 2023
1035bb6
Add exclude game option to channel joiner
theBGuy Sep 10, 2023
4b0e092
Update Barbarian.js
theBGuy Sep 12, 2023
d43a347
Update Prototypes.js
theBGuy Sep 13, 2023
fa2105f
some refactoring in manualplay
theBGuy Sep 13, 2023
94b365b
Update ItemHooks.js
theBGuy Sep 13, 2023
f41921c
Update ControlBot.js
theBGuy Sep 13, 2023
8406391
Update AutoRush.js
theBGuy Sep 13, 2023
d4377a9
Update Util.js
theBGuy Sep 13, 2023
c08ad10
Update Town.js
theBGuy Sep 13, 2023
fd66886
Update AutoRush.js
theBGuy Sep 14, 2023
e0682bb
Update ControlBot.js
theBGuy Sep 15, 2023
551ddf8
Update AutoRush.js
theBGuy Sep 16, 2023
db20bda
Update AutoBaal.js
theBGuy Sep 17, 2023
679ff43
Update MFHelper.js
theBGuy Sep 17, 2023
82f3609
Update Tools.js
theBGuy Sep 20, 2023
213db33
Update Me.js
theBGuy Sep 20, 2023
2787fb7
Update Pickit.js
theBGuy Sep 20, 2023
49f6f7f
more replacing `print` with `console.log`
theBGuy Sep 20, 2023
cb1c308
Update Town.js
theBGuy Sep 20, 2023
9137624
Update Skill.js
theBGuy Sep 20, 2023
c77c185
more replacing print statments
theBGuy Sep 20, 2023
dfab272
fix rushthread starting prematurely
theBGuy Sep 21, 2023
bd9aa30
add `Storage.Inventory.IsPossibleToFit`
theBGuy Sep 22, 2023
72815c4
typedef updates
theBGuy Sep 22, 2023
19bbba9
Update AutoRush.js
theBGuy Sep 22, 2023
f152c38
Update Storage.js
theBGuy Sep 22, 2023
cf32cfb
Update AutoMule.js
theBGuy Sep 22, 2023
28b2901
Add `GetFade` script
theBGuy Sep 23, 2023
2934dc7
Update ControlBot.js
theBGuy Oct 3, 2023
d35cbf8
Update AutoRush.js
theBGuy Oct 26, 2023
a666d1a
Update TownChicken.js
theBGuy Oct 26, 2023
5781fd7
Update Skill.js
theBGuy Oct 27, 2023
180d029
Bloodraven smith quest (#392)
icommitdesnet Dec 11, 2023
bb004ab
Add missing controls for account settings
theBGuy Dec 12, 2023
436743b
Update D2BotMule.dbj
theBGuy Dec 13, 2023
f178b0b
refactored `Town.cubeRepairItem` to `Cubing.repairItem`
theBGuy Dec 14, 2023
a8c27cf
Update town methods
theBGuy Dec 14, 2023
7849278
Add LadderMenu controls
theBGuy Dec 14, 2023
33b5b39
Update Pather.js
theBGuy Dec 16, 2023
9bc1409
Update Prototypes.js
theBGuy Dec 18, 2023
778de1d
Update Cubing.js
theBGuy Dec 21, 2023
fa3ee62
Update Cubing.js
theBGuy Dec 21, 2023
e287cbe
GetEssences.js (#393)
magace Dec 28, 2023
5fefff0
add `closeToStash` option to `Cubing.closeCube`
theBGuy Jan 9, 2024
0f1aefd
Update Town.js
theBGuy Jan 9, 2024
d4a6b28
Add more sdk.locale.items values
theBGuy Jan 22, 2024
11ac863
Manualplay (#395)
icommitdesnet Jan 27, 2024
75ca534
Add `Packet.initNPC`
theBGuy Jan 28, 2024
69b48b2
Update ShopBot.js
theBGuy Jan 28, 2024
768e319
[Feat] Add ngvote to ControlBot.js
theBGuy Jan 29, 2024
4c1e796
[Feat] Low gold watch for ControlBot
theBGuy Jan 29, 2024
14cc99e
[Formatting] gambling\TeamsConfig.js
theBGuy Jan 29, 2024
5ee69e3
[Revert] BlockWalk collision change
theBGuy Jan 30, 2024
696302e
[Feat] Add dropgold command to ControlBot
theBGuy Jan 30, 2024
f6d3600
Create extensions.json
theBGuy Feb 3, 2024
730d204
Update `.gitignore` file (#405)
samlitowitz Mar 15, 2024
7b8e083
Add `editorconfig` fix vscode exclusions
theBGuy Mar 17, 2024
a1746f3
Revert recursive gem cubing
theBGuy Mar 25, 2024
7ea308b
[BugFix] Continous Torch/Anni mules not moving to next char
theBGuy Mar 25, 2024
6dedb61
Add switch casting functionality to `Skill.cast`
theBGuy Mar 26, 2024
cff3e30
Add `Config.CustomPreAttack`
theBGuy Mar 26, 2024
ed58e2a
Update Baal.js
theBGuy Mar 26, 2024
a0b1584
Add ChargeCast config info to base class configs
theBGuy Mar 26, 2024
0e794e0
Fix typo in ToolsThread.js (#408)
Antiwarden Mar 26, 2024
d81fbf8
Simple advertise worker
theBGuy Mar 27, 2024
78281e9
Update BattleOrders.js
theBGuy Mar 27, 2024
ff531e5
Update Pather.js
theBGuy Mar 28, 2024
445760f
[BugFix] Add missing bonearmor state to skilldata
theBGuy Mar 30, 2024
82e17be
[BugFix] MFSwitchPercent
theBGuy Mar 30, 2024
3433e38
[Feat] Difficulty + mode announcement in channel
theBGuy Mar 30, 2024
0eef1ce
Update Misc.js
theBGuy Mar 31, 2024
5667e9e
[BugFix] Using a3/a5 shrines
theBGuy Mar 31, 2024
0aa1224
Update ShrineData.js
theBGuy Mar 31, 2024
fe6099e
[Feat] Add usage of wells to scanshrines
theBGuy Mar 31, 2024
6855331
Update tsconfig.json
theBGuy Apr 10, 2024
76abd6d
Add `Pather.randMove`
theBGuy Apr 10, 2024
3cecdfd
Update Loader.js
theBGuy Apr 10, 2024
1af9384
Switch to using new `Runnable` class
theBGuy Apr 10, 2024
2bf6dfd
typedef udates
theBGuy Apr 10, 2024
074e8ae
[BugFix] Typo `BaalAssisstant` -> `BaalAssistant`
theBGuy Apr 11, 2024
fc9b0d0
Update OOG.js
theBGuy Apr 14, 2024
6124fdd
Fix find/getCharacters for singleplayer
theBGuy Apr 14, 2024
332078d
Add lowgold case for dropping below our repaircosts
theBGuy Apr 14, 2024
040fbe5
[BugFix] Don't touch cube if it's in locked invo spot
theBGuy Apr 17, 2024
988fdff
Update ConfigOverrides.js
theBGuy Apr 30, 2024
83cd4d0
Update Item.js
theBGuy May 2, 2024
2166f43
Cleanup warnings from depreciated methods
theBGuy May 11, 2024
f89293b
Update Attack.js
theBGuy May 11, 2024
3e59165
[BugFix] Cubing - Fix ladder check for single player
theBGuy May 13, 2024
1b99000
Small leech script tweaks
theBGuy May 13, 2024
88e509e
Adding `Config.RunningAura`, allow setting specific aura while pathing
theBGuy May 13, 2024
0f16d1e
Add `aura` to SkillData, create `Skill.isAura`
theBGuy May 13, 2024
c80a408
Default start acts 2,3 to use Act 1 due to long distance from wp
theBGuy May 14, 2024
59cd542
Update autoLeaderDetect
theBGuy May 14, 2024
1d36e79
Update Wakka hot-tp check
theBGuy May 15, 2024
605f3f2
[BugFix] Fix uploading to itemlog and saving screenshot
theBGuy May 16, 2024
9a802e3
Allow passing in callback function for clearLevel to stop early
theBGuy May 20, 2024
77b7944
Track bosses killed and add `PathNode` class
theBGuy May 22, 2024
d029e55
Add `NTIP.addLine` method
theBGuy May 22, 2024
4020222
Add `Config.FastPickRange` and init `Config.PickitLines`
theBGuy May 22, 2024
37dac64
Add `options` parameter to `Runnable` class, add `bossid` to boss scr…
theBGuy May 22, 2024
7dcf86f
Fix `Attack.clear` adding to _killed set before target is dead
theBGuy May 22, 2024
1212c82
Handle adding superuniques to killed set
theBGuy May 22, 2024
30ed7a1
Small tweaks
theBGuy May 22, 2024
26ced20
Fix `Attack.kill` for adding correct info to `_killed` set
theBGuy May 22, 2024
4387113
Add bossid check to `Loader.runScript`
theBGuy May 22, 2024
1643707
Add `Attack.haveKilled` checks for scripts that handle more than one …
theBGuy May 22, 2024
3dc0ac5
Move `startArea` into RunnableOptions parameter
theBGuy May 23, 2024
db4113a
Add `Pather.getWalkDistance` + use to fix `getIntoPosition`
theBGuy May 23, 2024
34a533e
Add experimental autoshriner
theBGuy May 23, 2024
1f41f4a
[Feat] New nip syntax `in` and `notin`
theBGuy May 26, 2024
4c49571
Update NTItemParser.js
theBGuy May 27, 2024
3c5aa6b
Moved `parseAliasIn` and maps outside of `ParseLineInt`'s function body
theBGuy May 27, 2024
f02a29f
Update NTIP.d.ts
theBGuy May 27, 2024
a90ca85
Update NTIP.d.ts
theBGuy May 27, 2024
e75c00f
Minor maintenance
theBGuy May 29, 2024
94e304e
Feature/wp cache (#410)
jaenster May 29, 2024
dff90c3
Merge branch 'restructure' of https://github.com/blizzhackers/kolbot …
theBGuy May 29, 2024
7cc7392
Add room drawing hooks to collmap
theBGuy May 29, 2024
6d956bf
Create Graph.js
theBGuy May 29, 2024
604bef0
Cleanup + refactor Graph
theBGuy May 29, 2024
f07f588
Update Graph.js
theBGuy Jun 2, 2024
0e02d11
Update Attack.js
theBGuy Jun 2, 2024
5f888d7
[BugFix] `seenGids.add` returns void caused failure to build chest list
theBGuy Jun 9, 2024
eb374d1
accidental upload - revert changes to rusher/rushee
theBGuy Jun 9, 2024
b77e062
Update Misc.js
theBGuy Jun 19, 2024
ac6dac8
Add support for ChargeCasting to restrict to certain classids
theBGuy Jun 20, 2024
b8f9263
Enable use of ChargedSkills with CustomPreAttack
theBGuy Jun 20, 2024
cd27f25
Update `Time.format` method
theBGuy Jun 21, 2024
4f86647
Fix `ControlAction.getCharacters`
theBGuy Jul 4, 2024
0d60f6a
Fix typo in `Skill.castCharges`. Fix error `filter is not a method` i…
theBGuy Jul 7, 2024
ba2db0d
Add `Skill.useableOn` method to fix casting stateful spells on monste…
theBGuy Jul 7, 2024
56a8759
Update `Attack.clear` for charge usage
theBGuy Jul 7, 2024
1f50af0
[hotfix[ Update shriner to handle objects with no name prop
theBGuy Aug 11, 2024
65e5fcc
Update Loader.js
theBGuy Aug 20, 2024
0e2bc77
Update ChestMania.js
theBGuy Aug 20, 2024
b18db44
Update Loader.d.ts
theBGuy Aug 20, 2024
9544d2b
Update ActionHooks.js
theBGuy Aug 21, 2024
25fd72e
Fix PickThread for manulaplay
theBGuy Sep 26, 2024
f92c096
Update Config.d.ts
theBGuy Sep 26, 2024
b677ecc
[Chore] Cleanup + maintenance
theBGuy Oct 12, 2024
1bf6c10
Update package.json
theBGuy Oct 12, 2024
c59b216
Update DeveloperMode.js
theBGuy Oct 12, 2024
de723b0
Update string prototype `isEqual` and add `isType` utility method
theBGuy Oct 12, 2024
226c33d
Ensure only unique recipes in cubing list + add low grand charm recipe
theBGuy Oct 13, 2024
ebfe140
Created `globals.js` to clean up the misuse of Pollyfill.js
theBGuy Oct 27, 2024
d3d640c
Track what our entry script is
theBGuy Oct 27, 2024
82b1fff
Remove password check from friend list channel join
theBGuy Oct 27, 2024
b3d67fc
Update AutoRush.js
theBGuy Oct 27, 2024
82f9993
Update AutoRush.js
theBGuy Oct 28, 2024
2bd964c
Update README.md
theBGuy Oct 29, 2024
925f513
Add `Config.GetEssences.RunDuriel` option
theBGuy Nov 14, 2024
d65929b
Update ControlBot.js
theBGuy Dec 20, 2024
2eba73f
Fix D2BotPubJoin utilizing `AttemptNextGame`
theBGuy Dec 20, 2024
4bdde93
Update Pickit.js
theBGuy Dec 20, 2024
3a896ab
Fix D2BotMuleLog not updating `currAcc` property in generated `MuleLo…
theBGuy Dec 22, 2024
cdc164f
Update ControlBot.js
theBGuy Dec 25, 2024
3bb49e4
Fix typo in `SimpleParty.js`
theBGuy Dec 27, 2024
d6e3bde
Update RuneData.js
theBGuy Dec 27, 2024
3c80e12
Update SimpleParty.js
theBGuy Dec 27, 2024
30168fd
Formatted + updated AntiHostile to fix infinite wait and usage with S…
theBGuy Dec 27, 2024
e4ff8c1
Update `SimpleParty` to have a scriptmsg listener for updating shitli…
theBGuy Dec 27, 2024
835bbe0
Update globals.d.ts
theBGuy Dec 27, 2024
1c9b0b0
Add `me.shitList` property so it's easier to share data across worker…
theBGuy Dec 27, 2024
e2b0926
Update Mule.js
theBGuy Dec 27, 2024
69f48ce
Fix `ngvote` for ControlBot + little refactoring
theBGuy Jan 3, 2025
2c3c975
Manualplay fixes (#425)
icommitdesnet Jan 3, 2025
6839b81
Fix strict warning for secondary alternative attack skill setup
theBGuy Jan 13, 2025
68bca5f
Update globals.d.ts
theBGuy Jan 14, 2025
24c54dd
Add handler for pre-existing mule files leftover from ladder reset
theBGuy Jan 14, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
8 changes: 8 additions & 0 deletions .editorconfig
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
root = true

[*]
indent_style = space
indent_size = 2
charset = utf-8
trim_trailing_whitespace = true
insert_final_newline = true
260 changes: 131 additions & 129 deletions .eslintrc.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,133 +3,135 @@
// Compatible with ESLint plugin

module.exports = {
"root": true,
"extends": "eslint:recommended",
"parserOptions": {
"ecmaFeatures": {
"impliedStrict": true,
}
},
"env": {
"es6": true,
},
"globals": {
// The following globals are defined within D2BS, or are actually defined in the source code
"include": true,
"print": true,
"me": true,
"td": true,
"getTickCount": true,
"delay": true,
"getParty": true,
"takeScreenshot": true,
"getUnit": true,
"quit": true,
"clickMap": true,
"getBaseStat": true,
"clickItem": true,
"getCursorType": true,
"getPresetUnits": true,
"getDistance": true,
"copyUnit": true,
"getRoom": true,
"getLocaleString": true,
"scriptBroadcast": true,
"isIncluded": true,
"showConsole": true,
"getInteractedNPC": true,
"getDialogLines": true,
"getUIFlag": true,
"sendPacket": true,
"getPacket": true,
"getPath": true,
"rand": true,
"PresetUnit": true,
"getPresetUnit": true,
"getArea": true,
"getWaypoint": true,
"getScript": true,
"Room": true,
"say": true,
"load": true,
"addEventListener": true,
"getMercHP": true,
"checkCollision": true,
"gold": true,
"getLocation": true,
"login": true,
"sendCopyData": true,
"getControl": true,
"debugLog": true,
"getCollision": true,
"transmute": true,
"submitItem": true,
"createGame": true,
"joinGame": true,
"Line": true,
"removeEventListener": true,
"Unit": true,
"Party": true,
"UtilitySystem": true,
"moveNPC": true,
"getPlayerFlag": true,
"clickParty": true,
"dopen": true,
"NTIPAliasClassID": true,
"Items": true,
"Text": true,
"File": true,
"js_strict": true,
"handler": true,
"sendKey": true,
"md5": true,
"module": true,
"require": true,
"Box": true,
"Frame": true,
"revealLevel": true,
"hideConsole": true,
},
"rules": {
// enable additional rules
"indent": ["warn", "tab"],
"linebreak-style": ["off", "windows"],
"semi": ["error", "always"],
"comma-spacing": ["error", {"before": false, "after": true}],
"keyword-spacing": ["error", {"before": true, "after": true}],
"brace-style": ["error", "1tbs", {"allowSingleLine": true}],
"space-infix-ops": "error",
"space-unary-ops": ["error", {"words": true, "nonwords": false}],
"arrow-spacing": "error",
"arrow-body-style": ["error", "as-needed"],
"space-before-blocks": "error",
"key-spacing": ["error", {"beforeColon": false, "afterColon": true}],
"no-mixed-spaces-and-tabs": "error",
"no-trailing-spaces": ["warn", {"ignoreComments": true, "skipBlankLines": true}],
"no-whitespace-before-property": "error",
"comma-style": ["error", "last"],
"eol-last": ["error", "always"],
"block-scoped-var": "error",
"no-var": "warn",
"curly": ["error", "multi-line"],
"dot-notation": "warn",
"eqeqeq": ["error", "smart"],
"no-caller": "error",
"no-floating-decimal": "error",
"no-multi-spaces": ["error", {"ignoreEOLComments": true }],
"no-self-compare": "error",
"no-case-declarations": "off",
"no-with": "error",
"no-shadow": "off",
"no-use-before-define": "off",
"no-prototype-builtins": "off",
"quotes": ["warn", "double", { "avoidEscape": true }],
"no-constant-condition": ["error", {"checkLoops": false}],
"no-extra-label": "error",
//"no-labels": ["error", {"allowLoop": true}], // in the future no loops ;)
"no-unused-vars": ["warn", {"vars": "local"}],
"no-fallthrough": ["error", {"commentPattern": "break[\\s\\w]*omitted"}],
"no-undef": ["off", "always"],
"no-extra-boolean-cast": ["off", "always"],
}
"root": true,
"extends": "eslint:recommended",
"parserOptions": {
"ecmaFeatures": {
"impliedStrict": true,
}
},
"env": {
"es6": true,
},
"globals": {
// The following globals are defined within D2BS, or are actually defined in the source code
"include": true,
"print": true,
"me": true,
"td": true,
"getTickCount": true,
"delay": true,
"getParty": true,
"takeScreenshot": true,
"getUnit": true,
"quit": true,
"clickMap": true,
"getBaseStat": true,
"clickItem": true,
"getCursorType": true,
"getPresetUnits": true,
"getDistance": true,
"copyUnit": true,
"getRoom": true,
"getLocaleString": true,
"scriptBroadcast": true,
"isIncluded": true,
"showConsole": true,
"getInteractedNPC": true,
"getDialogLines": true,
"getUIFlag": true,
"sendPacket": true,
"getPacket": true,
"getPath": true,
"rand": true,
"PresetUnit": true,
"getPresetUnit": true,
"getArea": true,
"getWaypoint": true,
"getScript": true,
"Room": true,
"say": true,
"load": true,
"addEventListener": true,
"getMercHP": true,
"checkCollision": true,
"gold": true,
"getLocation": true,
"login": true,
"sendCopyData": true,
"getControl": true,
"debugLog": true,
"getCollision": true,
"transmute": true,
"submitItem": true,
"createGame": true,
"joinGame": true,
"Line": true,
"removeEventListener": true,
"Unit": true,
"Party": true,
"UtilitySystem": true,
"moveNPC": true,
"getPlayerFlag": true,
"clickParty": true,
"dopen": true,
"Items": true,
"Text": true,
"File": true,
"js_strict": true,
"handler": true,
"sendKey": true,
"md5": true,
"module": true,
"require": true,
"Box": true,
"Frame": true,
"revealLevel": true,
"hideConsole": true,
},
"rules": {
// enable additional rules
"indent": ["warn", 2],
"linebreak-style": ["off", "windows"],
"semi": ["error", "always"],
"comma-spacing": ["error", { "before": false, "after": true }],
"keyword-spacing": ["error", { "before": true, "after": true }],
"object-curly-spacing": ["error", "always"],
"brace-style": ["error", "1tbs", { "allowSingleLine": true }],
"space-infix-ops": "error",
"space-unary-ops": ["error", { "words": true, "nonwords": false }],
"arrow-spacing": "error",
"arrow-body-style": ["error", "as-needed"],
"space-before-blocks": "error",
"key-spacing": ["error", { "mode": "strict", "beforeColon": false, "afterColon": true }],
"no-mixed-spaces-and-tabs": "error",
"no-trailing-spaces": ["warn", { "ignoreComments": true, "skipBlankLines": true }],
"no-whitespace-before-property": "error",
"comma-style": ["error", "last"],
"eol-last": ["error", "always"],
"block-scoped-var": "error",
"no-var": "warn",
"curly": ["error", "multi-line"],
"dot-notation": "warn",
"eqeqeq": ["error", "smart"],
"no-caller": "error",
"no-floating-decimal": "error",
"no-multi-spaces": ["error", { "ignoreEOLComments": true }],
"no-self-compare": "error",
"no-case-declarations": "off",
"no-with": "error",
"no-shadow": "off",
"no-use-before-define": "off",
"no-prototype-builtins": "off",
"quotes": ["warn", "double", { "avoidEscape": true }],
"no-constant-condition": ["error", { "checkLoops": false }],
"no-extra-label": "error",
//"no-labels": ["error", {"allowLoop": true}], // in the future no loops ;)
"no-unused-vars": ["warn", { "vars": "local", "varsIgnorePattern": "^_" }],
"no-fallthrough": ["error", { "commentPattern": "break[\\s\\w]*omitted" }],
"no-undef": ["off", "always"],
"no-extra-boolean-cast": ["off", "always"],
"no-useless-escape": ["off", "always"],
"max-len": ["warn", { "code": 120, "ignoreComments": true, "ignoreUrls": true, "ignoreStrings": true }],
}
};
23 changes: 23 additions & 0 deletions .github/workflows/eslint.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
name: ESLint Check

on:
pull_request:

jobs:
lint:
runs-on: ubuntu-latest

steps:
- name: Checkout code
uses: actions/checkout@v4

- name: Set up Node.js
uses: actions/setup-node@v4
with:
node-version: '18.20.4'

- name: Install dependencies
run: npm install

- name: Run ESLint
run: npm run lint
25 changes: 25 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,4 +1,20 @@
# Do not track hidden files and directories by default
.*

# Track these hidden files
!.eslintrc.js
!.gitignore
!.gitmodules
!.editorconfig

# Track these hidden directories
!.github/

# Track these files from vscodes
!.vscode/settings.json
!.vscode/extensions.json

# Do not track user generated data
d2bs/kolbot/data/secure/*.txt
d2bs/kolbot/data/*.json
d2bs/kolbot/logs/*.json
Expand All @@ -7,3 +23,12 @@ d2bs/kolbot/logs/**/**
d2bs/kolbot/mules/**/*.txt
d2bs/logs/*.log
d2bs/kolbot/libs/manualplay/config/*.*.js
d2bs/kolbot/libs/soloplay/**
d2bs/kolbot/libs/config/*.*.js
d2bs/kolbot/D2BotSoloPlay.dbj
data/
images/
logs/

# Do not track install packages
node_modules/
6 changes: 6 additions & 0 deletions .vscode/extensions.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
{
"recommendations": [
"dbaeumer.vscode-eslint",
"thebguy.vsnip-check"
]
}
10 changes: 10 additions & 0 deletions .vscode/settings.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
{
"editor.rulers": [
120
],
"editor.tabSize": 2,
"editor.detectIndentation": false,
"editor.codeActionsOnSave": {
"source.fixAll.eslint": "explicit"
},
}
21 changes: 11 additions & 10 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,29 +19,30 @@
* D2Bot# - manager (C#)
* kolbot - script library (JS)

* use the mainline (trunk) branch
If you want to contribute to kolbot code, make sure you run `npm run lint` for final polish.

If you want to contribute to kolbot code, make sure you use [ESLint options for kolbot code](https://gist.githubusercontent.com/Nishimura-Katsuo/2d6866666c7acf10047c486a15a7fe60/raw/99ef9c2995929c492ef856772ff346e0f19709cd/.eslintrc.js) or [JSLint options for kolbot code](https://gist.githubusercontent.com/noah-/d917342e52281d54c404e0b2c18b0c6e/raw/fbade95e38b103d2654b90d85ef62a51c4295153/jslint.config) for final polish.
If you want to contribute to d2bs/d2bot#, come to irc.synirc.net/d2bs and ask around.

[**Live Docs**](https://bhdocs.github.io/)

[**Documentation Repo**](https://github.com/blizzhackers/documentation#diablo-2-botting-system-d2bs)

## Install dependencies - do this first!
- [Microsoft Visual C++ 2010 Redistributable Package (x86)](https://www.microsoft.com/en-us/download/details.aspx?id=26999)
- [Microsoft .NET Framework 4.0 (or higher)](https://dotnet.microsoft.com/download/dotnet-framework)

## Getting Started
- [download kolbot](https://github.com/blizzhackers/documentation/blob/master/d2bot/Download.md#download)
- [d2bot manager setup](https://github.com/blizzhackers/documentation/blob/master/d2bot/ManagerSetup.md/#manager-setup)
- [IDE-Setup](IDES.md/#code-editors-ides): How to set up your IDE for syntax highlighting
- [FAQ](https://github.com/blizzhackers/documentation/blob/master/kolbot/FAQ.md/#faq)
- [download kolbot](https://github.com/blizzhackers/documentation/blob/restructure/d2bot/Download.md#download)
- [d2bot manager setup](https://github.com/blizzhackers/documentation/blob/restructure/d2bot/ManagerSetup.md/#manager-setup)
- [IDE-Setup](https://github.com/blizzhackers/documentation/blob/restructure/kolbot/IDES.md/#code-editors-ides):
- [FAQ](https://github.com/blizzhackers/documentation/blob/restructure/kolbot/FAQ.md/#faq)

## Guides
- [manual playing](https://github.com/blizzhackers/documentation/blob/master/kolbot/ManualPlay.md/#manual-playing)
- [multi botting](https://github.com/blizzhackers/documentation/blob/master/kolbot/MultiBotting.md/#multi-botting)
- [manual playing](https://github.com/blizzhackers/documentation/blob/restructure/kolbot/ManualPlay.md/#manual-playing)
- [multi botting](https://github.com/blizzhackers/documentation/blob/restructure/kolbot/MultiBotting.md/#multi-botting)
- [kolbot-SoloPlay](https://github.com/blizzhackers/kolbot-SoloPlay)
- [character config](https://github.com/blizzhackers/documentation/blob/master/kolbot/CharacterConfig.md/#character-configuration)
- [TCP/IP Games](https://github.com/blizzhackers/documentation/blob/master/kolbot/TCP-IP%20games.md#tcpip-games)
- [character config](https://github.com/blizzhackers/documentation/blob/restructure/kolbot/CharacterConfig.md/#character-configuration)
- [TCP/IP Games](https://github.com/blizzhackers/documentation/blob/restructure/kolbot/TCP-IP%20games.md#tcpip-games)

## LimeDrop web based item manager and dropper

Expand Down
Loading
Loading