isaacscript-common 2.0.16 → 2.0.19
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/callbacks/itemPickup.lua +3 -3
- package/dist/callbacks/postCustomDoorEnter.d.ts +5 -3
- package/dist/callbacks/postDoorRender.d.ts +1 -0
- package/dist/callbacks/postDoorRender.lua +24 -0
- package/dist/callbacks/postDoorUpdate.d.ts +1 -0
- package/dist/callbacks/postDoorUpdate.lua +24 -0
- package/dist/callbacks/postEffectStateChanged.lua +1 -1
- package/dist/callbacks/postFamiliarStateChanged.lua +1 -1
- package/dist/callbacks/postGridEntity.lua +5 -4
- package/dist/callbacks/postGridEntityRender.d.ts +1 -0
- package/dist/callbacks/postGridEntityRender.lua +24 -0
- package/dist/callbacks/postItemDischarged.lua +5 -5
- package/dist/callbacks/postNPCStateChanged.lua +1 -1
- package/dist/callbacks/postPickupStateChanged.lua +1 -1
- package/dist/callbacks/postPitRender.d.ts +1 -0
- package/dist/callbacks/postPitRender.lua +24 -0
- package/dist/callbacks/postPitUpdate.d.ts +1 -0
- package/dist/callbacks/postPitUpdate.lua +24 -0
- package/dist/callbacks/postPlayerChangeType.lua +1 -1
- package/dist/callbacks/postPoopRender.d.ts +1 -0
- package/dist/callbacks/postPoopRender.lua +24 -0
- package/dist/callbacks/postPoopUpdate.d.ts +1 -0
- package/dist/callbacks/postPoopUpdate.lua +24 -0
- package/dist/callbacks/postPressurePlateRender.d.ts +1 -0
- package/dist/callbacks/postPressurePlateRender.lua +24 -0
- package/dist/callbacks/postPressurePlateUpdate.d.ts +1 -0
- package/dist/callbacks/postPressurePlateUpdate.lua +24 -0
- package/dist/callbacks/postRockRender.d.ts +1 -0
- package/dist/callbacks/postRockRender.lua +24 -0
- package/dist/callbacks/postRockUpdate.d.ts +1 -0
- package/dist/callbacks/postRockUpdate.lua +24 -0
- package/dist/callbacks/postSlotRender.lua +1 -1
- package/dist/callbacks/postSpikesRender.d.ts +1 -0
- package/dist/callbacks/postSpikesRender.lua +24 -0
- package/dist/callbacks/postSpikesUpdate.d.ts +1 -0
- package/dist/callbacks/postSpikesUpdate.lua +24 -0
- package/dist/callbacks/postTNTRender.d.ts +1 -0
- package/dist/callbacks/postTNTRender.lua +24 -0
- package/dist/callbacks/postTNTUpdate.d.ts +1 -0
- package/dist/callbacks/postTNTUpdate.lua +24 -0
- package/dist/callbacks/subscriptions/postDoorRender.d.ts +5 -0
- package/dist/callbacks/subscriptions/postDoorRender.lua +24 -0
- package/dist/callbacks/subscriptions/postDoorUpdate.d.ts +5 -0
- package/dist/callbacks/subscriptions/postDoorUpdate.lua +24 -0
- package/dist/callbacks/subscriptions/postGridEntityBroken.d.ts +2 -1
- package/dist/callbacks/subscriptions/postGridEntityBroken.lua +8 -2
- package/dist/callbacks/subscriptions/postGridEntityCollision.d.ts +2 -1
- package/dist/callbacks/subscriptions/postGridEntityCollision.lua +5 -0
- package/dist/callbacks/subscriptions/postGridEntityInit.d.ts +2 -1
- package/dist/callbacks/subscriptions/postGridEntityInit.lua +8 -2
- package/dist/callbacks/subscriptions/postGridEntityRemove.d.ts +2 -1
- package/dist/callbacks/subscriptions/postGridEntityRemove.lua +5 -1
- package/dist/callbacks/subscriptions/postGridEntityRender.d.ts +6 -0
- package/dist/callbacks/subscriptions/postGridEntityRender.lua +29 -0
- package/dist/callbacks/subscriptions/postGridEntityStateChanged.d.ts +2 -1
- package/dist/callbacks/subscriptions/postGridEntityStateChanged.lua +8 -2
- package/dist/callbacks/subscriptions/postGridEntityUpdate.d.ts +2 -1
- package/dist/callbacks/subscriptions/postGridEntityUpdate.lua +8 -2
- package/dist/callbacks/subscriptions/postItemPickup.d.ts +9 -5
- package/dist/callbacks/subscriptions/postItemPickup.lua +2 -2
- package/dist/callbacks/subscriptions/postPitRender.d.ts +5 -0
- package/dist/callbacks/subscriptions/postPitRender.lua +24 -0
- package/dist/callbacks/subscriptions/postPitUpdate.d.ts +5 -0
- package/dist/callbacks/subscriptions/postPitUpdate.lua +24 -0
- package/dist/callbacks/subscriptions/postPlayerChangeHealth.d.ts +3 -2
- package/dist/callbacks/subscriptions/postPlayerChangeHealth.lua +5 -0
- package/dist/callbacks/subscriptions/postPlayerChangeType.d.ts +3 -2
- package/dist/callbacks/subscriptions/postPlayerChangeType.lua +8 -1
- package/dist/callbacks/subscriptions/postPlayerFatalDamage.d.ts +3 -2
- package/dist/callbacks/subscriptions/postPlayerFatalDamage.lua +5 -0
- package/dist/callbacks/subscriptions/postPlayerInitLate.d.ts +3 -2
- package/dist/callbacks/subscriptions/postPlayerInitLate.lua +5 -0
- package/dist/callbacks/subscriptions/postPlayerInitReordered.d.ts +3 -2
- package/dist/callbacks/subscriptions/postPlayerInitReordered.lua +5 -0
- package/dist/callbacks/subscriptions/postPlayerRenderReordered.d.ts +3 -2
- package/dist/callbacks/subscriptions/postPlayerRenderReordered.lua +5 -0
- package/dist/callbacks/subscriptions/postPlayerUpdateReordered.d.ts +3 -2
- package/dist/callbacks/subscriptions/postPlayerUpdateReordered.lua +5 -0
- package/dist/callbacks/subscriptions/postPoopRender.d.ts +5 -0
- package/dist/callbacks/subscriptions/postPoopRender.lua +24 -0
- package/dist/callbacks/subscriptions/postPoopUpdate.d.ts +5 -0
- package/dist/callbacks/subscriptions/postPoopUpdate.lua +24 -0
- package/dist/callbacks/subscriptions/postPressurePlateRender.d.ts +5 -0
- package/dist/callbacks/subscriptions/postPressurePlateRender.lua +24 -0
- package/dist/callbacks/subscriptions/postPressurePlateUpdate.d.ts +5 -0
- package/dist/callbacks/subscriptions/postPressurePlateUpdate.lua +24 -0
- package/dist/callbacks/subscriptions/postRockRender.d.ts +5 -0
- package/dist/callbacks/subscriptions/postRockRender.lua +24 -0
- package/dist/callbacks/subscriptions/postRockUpdate.d.ts +5 -0
- package/dist/callbacks/subscriptions/postRockUpdate.lua +24 -0
- package/dist/callbacks/subscriptions/postSacrifice.d.ts +4 -2
- package/dist/callbacks/subscriptions/postSacrifice.lua +13 -1
- package/dist/callbacks/subscriptions/postSlotAnimationChanged.d.ts +1 -1
- package/dist/callbacks/subscriptions/postSlotDestroyed.d.ts +1 -1
- package/dist/callbacks/subscriptions/postSlotInit.d.ts +1 -1
- package/dist/callbacks/subscriptions/postSlotRender.d.ts +1 -1
- package/dist/callbacks/subscriptions/postSlotUpdate.d.ts +1 -1
- package/dist/callbacks/subscriptions/postSpikesRender.d.ts +5 -0
- package/dist/callbacks/subscriptions/postSpikesRender.lua +24 -0
- package/dist/callbacks/subscriptions/postSpikesUpdate.d.ts +5 -0
- package/dist/callbacks/subscriptions/postSpikesUpdate.lua +24 -0
- package/dist/callbacks/subscriptions/postTNTRender.d.ts +5 -0
- package/dist/callbacks/subscriptions/postTNTRender.lua +24 -0
- package/dist/callbacks/subscriptions/postTNTUpdate.d.ts +5 -0
- package/dist/callbacks/subscriptions/postTNTUpdate.lua +24 -0
- package/dist/callbacks/subscriptions/preBerserkDeath.d.ts +3 -2
- package/dist/callbacks/subscriptions/preBerserkDeath.lua +5 -0
- package/dist/callbacks/subscriptions/preCustomRevive.d.ts +4 -2
- package/dist/callbacks/subscriptions/preCustomRevive.lua +15 -3
- package/dist/callbacks/subscriptions/preItemPickup.d.ts +9 -5
- package/dist/callbacks/subscriptions/preItemPickup.lua +2 -2
- package/dist/classes/DefaultMap.d.ts +8 -8
- package/dist/classes/DefaultMap.lua +3 -3
- package/dist/constants.d.ts +3 -2
- package/dist/constants.lua +2 -2
- package/dist/constantsMax.d.ts +15 -9
- package/dist/constantsMax.lua +7 -1
- package/dist/enums/ModCallbackCustom.d.ts +69 -54
- package/dist/enums/ModCallbackCustom.lua +84 -54
- package/dist/features/debugDisplay.d.ts +7 -0
- package/dist/features/debugDisplay.lua +117 -14
- package/dist/features/deployJSONRoom.lua +2 -2
- package/dist/features/extraConsoleCommands/commands.lua +32 -27
- package/dist/features/extraConsoleCommands/commandsDisplay.d.ts +63 -0
- package/dist/features/extraConsoleCommands/commandsDisplay.lua +49 -0
- package/dist/features/extraConsoleCommands/init.d.ts +2 -2
- package/dist/features/extraConsoleCommands/init.lua +18 -1
- package/dist/features/getCollectibleItemPoolType.lua +3 -2
- package/dist/features/playerInventory.lua +6 -6
- package/dist/features/preventCollectibleRotate.lua +7 -2
- package/dist/functions/array.lua +1 -1
- package/dist/functions/boss.d.ts +2 -3
- package/dist/functions/cards.lua +3 -1
- package/dist/functions/character.lua +2 -2
- package/dist/functions/charge.d.ts +6 -6
- package/dist/functions/collectibleCacheFlag.lua +3 -1
- package/dist/functions/collectibleSet.lua +3 -1
- package/dist/functions/collectibleTag.lua +3 -1
- package/dist/functions/collectibles.d.ts +1 -0
- package/dist/functions/collectibles.lua +32 -16
- package/dist/functions/entity.d.ts +1 -1
- package/dist/functions/entitySpecific.d.ts +4 -5
- package/dist/functions/entityTypes.d.ts +5 -0
- package/dist/functions/entityTypes.lua +10 -0
- package/dist/functions/familiars.d.ts +3 -3
- package/dist/functions/gridEntity.d.ts +0 -5
- package/dist/functions/gridEntity.lua +0 -14
- package/dist/functions/gridEntitySpecific.d.ts +18 -0
- package/dist/functions/gridEntitySpecific.lua +88 -0
- package/dist/functions/log.lua +2 -3
- package/dist/functions/npc.lua +3 -1
- package/dist/functions/npcTypes.d.ts +3 -0
- package/dist/functions/npcTypes.lua +7 -0
- package/dist/functions/pickupVariants.d.ts +13 -0
- package/dist/functions/pickupVariants.lua +22 -0
- package/dist/functions/pickups.lua +3 -1
- package/dist/functions/playerIndex.d.ts +2 -2
- package/dist/functions/rooms.d.ts +2 -3
- package/dist/functions/rooms.lua +5 -3
- package/dist/functions/run.lua +3 -1
- package/dist/functions/stage.d.ts +1 -1
- package/dist/functions/stage.lua +6 -5
- package/dist/functions/trinketCacheFlag.lua +3 -1
- package/dist/functions/trinketSet.lua +3 -1
- package/dist/functions/trinkets.lua +7 -3
- package/dist/index.d.ts +3 -0
- package/dist/index.lua +24 -0
- package/dist/initCustomCallbacks.lua +45 -0
- package/dist/initFeatures.lua +0 -3
- package/dist/maps/cardMap.lua +204 -202
- package/dist/maps/pillEffectMap.lua +82 -80
- package/dist/objects/callbackRegisterFunctions.lua +45 -0
- package/dist/objects/cardDescriptions.lua +1 -1
- package/dist/objects/cardNames.lua +1 -1
- package/dist/objects/cardTypes.lua +1 -1
- package/dist/types/AddCallbackParameterCustom.d.ts +30 -0
- package/dist/types/PickingUpItem.d.ts +2 -0
- package/dist/types/PickingUpItem.lua +10 -0
- package/dist/types/private/TSTLClassMetatable.d.ts +1 -1
- package/package.json +3 -3
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
local ____exports = {}
|
|
2
|
+
local subscriptions = {}
|
|
3
|
+
function ____exports.postDoorUpdateHasSubscriptions(self)
|
|
4
|
+
return #subscriptions > 0
|
|
5
|
+
end
|
|
6
|
+
function ____exports.postDoorUpdateRegister(self, ...)
|
|
7
|
+
local args = {...}
|
|
8
|
+
subscriptions[#subscriptions + 1] = args
|
|
9
|
+
end
|
|
10
|
+
function ____exports.postDoorUpdateFire(self, door)
|
|
11
|
+
local gridEntityVariant = door:GetVariant()
|
|
12
|
+
for ____, ____value in ipairs(subscriptions) do
|
|
13
|
+
local callback = ____value[1]
|
|
14
|
+
local callbackGridEntityVariant = ____value[2]
|
|
15
|
+
do
|
|
16
|
+
if callbackGridEntityVariant ~= nil and callbackGridEntityVariant ~= gridEntityVariant then
|
|
17
|
+
goto __continue5
|
|
18
|
+
end
|
|
19
|
+
callback(nil, door)
|
|
20
|
+
end
|
|
21
|
+
::__continue5::
|
|
22
|
+
end
|
|
23
|
+
end
|
|
24
|
+
return ____exports
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { GridEntityType } from "isaac-typescript-definitions";
|
|
2
2
|
export declare type PostGridEntityBrokenRegisterParameters = [
|
|
3
3
|
callback: (gridEntity: GridEntity) => void,
|
|
4
|
-
gridEntityType?: GridEntityType
|
|
4
|
+
gridEntityType?: GridEntityType,
|
|
5
|
+
gridEntityVariant?: int
|
|
5
6
|
];
|
|
@@ -8,11 +8,17 @@ function ____exports.postGridEntityBrokenRegister(self, ...)
|
|
|
8
8
|
subscriptions[#subscriptions + 1] = args
|
|
9
9
|
end
|
|
10
10
|
function ____exports.postGridEntityBrokenFire(self, gridEntity)
|
|
11
|
+
local gridEntityType = gridEntity:GetType()
|
|
12
|
+
local gridEntityVariant = gridEntity:GetVariant()
|
|
11
13
|
for ____, ____value in ipairs(subscriptions) do
|
|
12
14
|
local callback = ____value[1]
|
|
13
|
-
local
|
|
15
|
+
local callbackGridEntityType = ____value[2]
|
|
16
|
+
local callbackGridEntityVariant = ____value[3]
|
|
14
17
|
do
|
|
15
|
-
if
|
|
18
|
+
if callbackGridEntityType ~= nil and callbackGridEntityType ~= gridEntityType then
|
|
19
|
+
goto __continue5
|
|
20
|
+
end
|
|
21
|
+
if callbackGridEntityVariant ~= nil and callbackGridEntityVariant ~= gridEntityVariant then
|
|
16
22
|
goto __continue5
|
|
17
23
|
end
|
|
18
24
|
callback(nil, gridEntity)
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { GridEntityType } from "isaac-typescript-definitions";
|
|
2
2
|
export declare type PostGridEntityCollisionRegisterParameters = [
|
|
3
3
|
callback: (gridEntity: GridEntity, entity: Entity) => void,
|
|
4
|
-
gridEntityType?: GridEntityType
|
|
4
|
+
gridEntityType?: GridEntityType,
|
|
5
|
+
gridEntityVariant?: int
|
|
5
6
|
];
|
|
@@ -9,13 +9,18 @@ function ____exports.postGridEntityCollisionRegister(self, ...)
|
|
|
9
9
|
end
|
|
10
10
|
function ____exports.postGridEntityCollisionFire(self, gridEntity, entity)
|
|
11
11
|
local gridEntityType = gridEntity:GetType()
|
|
12
|
+
local gridEntityVariant = gridEntity:GetVariant()
|
|
12
13
|
for ____, ____value in ipairs(subscriptions) do
|
|
13
14
|
local callback = ____value[1]
|
|
14
15
|
local callbackGridEntityType = ____value[2]
|
|
16
|
+
local callbackGridEntityVariant = ____value[3]
|
|
15
17
|
do
|
|
16
18
|
if callbackGridEntityType ~= nil and callbackGridEntityType ~= gridEntityType then
|
|
17
19
|
goto __continue5
|
|
18
20
|
end
|
|
21
|
+
if callbackGridEntityVariant ~= nil and callbackGridEntityVariant ~= gridEntityVariant then
|
|
22
|
+
goto __continue5
|
|
23
|
+
end
|
|
19
24
|
callback(nil, gridEntity, entity)
|
|
20
25
|
end
|
|
21
26
|
::__continue5::
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { GridEntityType } from "isaac-typescript-definitions";
|
|
2
2
|
export declare type PostGridEntityInitRegisterParameters = [
|
|
3
3
|
callback: (gridEntity: GridEntity) => void,
|
|
4
|
-
gridEntityType?: GridEntityType
|
|
4
|
+
gridEntityType?: GridEntityType,
|
|
5
|
+
gridEntityVariant?: int
|
|
5
6
|
];
|
|
@@ -8,11 +8,17 @@ function ____exports.postGridEntityInitRegister(self, ...)
|
|
|
8
8
|
subscriptions[#subscriptions + 1] = args
|
|
9
9
|
end
|
|
10
10
|
function ____exports.postGridEntityInitFire(self, gridEntity)
|
|
11
|
+
local gridEntityType = gridEntity:GetType()
|
|
12
|
+
local gridEntityVariant = gridEntity:GetVariant()
|
|
11
13
|
for ____, ____value in ipairs(subscriptions) do
|
|
12
14
|
local callback = ____value[1]
|
|
13
|
-
local
|
|
15
|
+
local callbackGridEntityType = ____value[2]
|
|
16
|
+
local callbackGridEntityVariant = ____value[3]
|
|
14
17
|
do
|
|
15
|
-
if
|
|
18
|
+
if callbackGridEntityType ~= nil and callbackGridEntityType ~= gridEntityType then
|
|
19
|
+
goto __continue5
|
|
20
|
+
end
|
|
21
|
+
if callbackGridEntityVariant ~= nil and callbackGridEntityVariant ~= gridEntityVariant then
|
|
16
22
|
goto __continue5
|
|
17
23
|
end
|
|
18
24
|
callback(nil, gridEntity)
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { GridEntityType } from "isaac-typescript-definitions";
|
|
2
2
|
export declare type PostGridEntityRemoveRegisterParameters = [
|
|
3
3
|
callback: (gridIndex: int, gridEntityType: GridEntityType) => void,
|
|
4
|
-
gridEntityType?: GridEntityType
|
|
4
|
+
gridEntityType?: GridEntityType,
|
|
5
|
+
gridEntityVariant?: int
|
|
5
6
|
];
|
|
@@ -7,14 +7,18 @@ function ____exports.postGridEntityRemoveRegister(self, ...)
|
|
|
7
7
|
local args = {...}
|
|
8
8
|
subscriptions[#subscriptions + 1] = args
|
|
9
9
|
end
|
|
10
|
-
function ____exports.postGridEntityRemoveFire(self, gridIndex, gridEntityType)
|
|
10
|
+
function ____exports.postGridEntityRemoveFire(self, gridIndex, gridEntityType, gridEntityVariant)
|
|
11
11
|
for ____, ____value in ipairs(subscriptions) do
|
|
12
12
|
local callback = ____value[1]
|
|
13
13
|
local callbackGridEntityType = ____value[2]
|
|
14
|
+
local callbackGridEntityVariant = ____value[3]
|
|
14
15
|
do
|
|
15
16
|
if callbackGridEntityType ~= nil and callbackGridEntityType ~= gridEntityType then
|
|
16
17
|
goto __continue5
|
|
17
18
|
end
|
|
19
|
+
if callbackGridEntityVariant ~= nil and callbackGridEntityVariant ~= gridEntityVariant then
|
|
20
|
+
goto __continue5
|
|
21
|
+
end
|
|
18
22
|
callback(nil, gridIndex, gridEntityType)
|
|
19
23
|
end
|
|
20
24
|
::__continue5::
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
local ____exports = {}
|
|
2
|
+
local subscriptions = {}
|
|
3
|
+
function ____exports.postGridEntityRenderHasSubscriptions(self)
|
|
4
|
+
return #subscriptions > 0
|
|
5
|
+
end
|
|
6
|
+
function ____exports.postGridEntityRenderRegister(self, ...)
|
|
7
|
+
local args = {...}
|
|
8
|
+
subscriptions[#subscriptions + 1] = args
|
|
9
|
+
end
|
|
10
|
+
function ____exports.postGridEntityRenderFire(self, gridEntity)
|
|
11
|
+
local gridEntityType = gridEntity:GetType()
|
|
12
|
+
local gridEntityVariant = gridEntity:GetVariant()
|
|
13
|
+
for ____, ____value in ipairs(subscriptions) do
|
|
14
|
+
local callback = ____value[1]
|
|
15
|
+
local callbackGridEntityType = ____value[2]
|
|
16
|
+
local callbackGridEntityVariant = ____value[3]
|
|
17
|
+
do
|
|
18
|
+
if callbackGridEntityType ~= nil and callbackGridEntityType ~= gridEntityType then
|
|
19
|
+
goto __continue5
|
|
20
|
+
end
|
|
21
|
+
if callbackGridEntityVariant ~= nil and callbackGridEntityVariant ~= gridEntityVariant then
|
|
22
|
+
goto __continue5
|
|
23
|
+
end
|
|
24
|
+
callback(nil, gridEntity)
|
|
25
|
+
end
|
|
26
|
+
::__continue5::
|
|
27
|
+
end
|
|
28
|
+
end
|
|
29
|
+
return ____exports
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { GridEntityType } from "isaac-typescript-definitions";
|
|
2
2
|
export declare type PostGridEntityStateChangedRegisterParameters = [
|
|
3
3
|
callback: (gridEntity: GridEntity, oldState: int, newState: int) => void,
|
|
4
|
-
gridEntityType?: GridEntityType
|
|
4
|
+
gridEntityType?: GridEntityType,
|
|
5
|
+
gridEntityVariant?: int
|
|
5
6
|
];
|
|
@@ -8,11 +8,17 @@ function ____exports.postGridEntityStateChangedRegister(self, ...)
|
|
|
8
8
|
subscriptions[#subscriptions + 1] = args
|
|
9
9
|
end
|
|
10
10
|
function ____exports.postGridEntityStateChangedFire(self, gridEntity, oldState, newState)
|
|
11
|
+
local gridEntityType = gridEntity:GetType()
|
|
12
|
+
local gridEntityVariant = gridEntity:GetVariant()
|
|
11
13
|
for ____, ____value in ipairs(subscriptions) do
|
|
12
14
|
local callback = ____value[1]
|
|
13
|
-
local
|
|
15
|
+
local callbackGridEntityType = ____value[2]
|
|
16
|
+
local callbackGridEntityVariant = ____value[3]
|
|
14
17
|
do
|
|
15
|
-
if
|
|
18
|
+
if callbackGridEntityType ~= nil and callbackGridEntityType ~= gridEntityType then
|
|
19
|
+
goto __continue5
|
|
20
|
+
end
|
|
21
|
+
if callbackGridEntityVariant ~= nil and callbackGridEntityVariant ~= gridEntityVariant then
|
|
16
22
|
goto __continue5
|
|
17
23
|
end
|
|
18
24
|
callback(nil, gridEntity, oldState, newState)
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { GridEntityType } from "isaac-typescript-definitions";
|
|
2
2
|
export declare type PostGridEntityUpdateRegisterParameters = [
|
|
3
3
|
callback: (gridEntity: GridEntity) => void,
|
|
4
|
-
gridEntityType?: GridEntityType
|
|
4
|
+
gridEntityType?: GridEntityType,
|
|
5
|
+
gridEntityVariant?: int
|
|
5
6
|
];
|
|
@@ -8,11 +8,17 @@ function ____exports.postGridEntityUpdateRegister(self, ...)
|
|
|
8
8
|
subscriptions[#subscriptions + 1] = args
|
|
9
9
|
end
|
|
10
10
|
function ____exports.postGridEntityUpdateFire(self, gridEntity)
|
|
11
|
+
local gridEntityType = gridEntity:GetType()
|
|
12
|
+
local gridEntityVariant = gridEntity:GetVariant()
|
|
11
13
|
for ____, ____value in ipairs(subscriptions) do
|
|
12
14
|
local callback = ____value[1]
|
|
13
|
-
local
|
|
15
|
+
local callbackGridEntityType = ____value[2]
|
|
16
|
+
local callbackGridEntityVariant = ____value[3]
|
|
14
17
|
do
|
|
15
|
-
if
|
|
18
|
+
if callbackGridEntityType ~= nil and callbackGridEntityType ~= gridEntityType then
|
|
19
|
+
goto __continue5
|
|
20
|
+
end
|
|
21
|
+
if callbackGridEntityVariant ~= nil and callbackGridEntityVariant ~= gridEntityVariant then
|
|
16
22
|
goto __continue5
|
|
17
23
|
end
|
|
18
24
|
callback(nil, gridEntity)
|
|
@@ -1,7 +1,11 @@
|
|
|
1
1
|
import { CollectibleType, ItemType, TrinketType } from "isaac-typescript-definitions";
|
|
2
|
-
import { PickingUpItem } from "../../types/PickingUpItem";
|
|
3
|
-
export declare type PostItemPickupRegisterParameters = [
|
|
4
|
-
callback: (player: EntityPlayer, pickingUpItem:
|
|
5
|
-
itemType
|
|
6
|
-
|
|
2
|
+
import { PickingUpItem, PickingUpItemCollectible, PickingUpItemTrinket } from "../../types/PickingUpItem";
|
|
3
|
+
export declare type PostItemPickupRegisterParameters = [callback: (player: EntityPlayer, pickingUpItem: PickingUpItem) => void] | [
|
|
4
|
+
callback: (player: EntityPlayer, pickingUpItem: PickingUpItemCollectible) => void,
|
|
5
|
+
itemType: ItemType.PASSIVE | ItemType.ACTIVE | ItemType.FAMILIAR,
|
|
6
|
+
collectibleType?: CollectibleType
|
|
7
|
+
] | [
|
|
8
|
+
callback: (player: EntityPlayer, pickingUpItem: PickingUpItemTrinket) => void,
|
|
9
|
+
itemType: ItemType.TRINKET,
|
|
10
|
+
trinketType?: TrinketType
|
|
7
11
|
];
|
|
@@ -11,12 +11,12 @@ function ____exports.postItemPickupFire(self, player, pickingUpItem)
|
|
|
11
11
|
for ____, ____value in ipairs(subscriptions) do
|
|
12
12
|
local callback = ____value[1]
|
|
13
13
|
local itemType = ____value[2]
|
|
14
|
-
local
|
|
14
|
+
local subType = ____value[3]
|
|
15
15
|
do
|
|
16
16
|
if itemType ~= nil and itemType ~= pickingUpItem.itemType then
|
|
17
17
|
goto __continue5
|
|
18
18
|
end
|
|
19
|
-
if
|
|
19
|
+
if subType ~= nil and subType ~= pickingUpItem.subType then
|
|
20
20
|
goto __continue5
|
|
21
21
|
end
|
|
22
22
|
callback(nil, player, pickingUpItem)
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
local ____exports = {}
|
|
2
|
+
local subscriptions = {}
|
|
3
|
+
function ____exports.postPitRenderHasSubscriptions(self)
|
|
4
|
+
return #subscriptions > 0
|
|
5
|
+
end
|
|
6
|
+
function ____exports.postPitRenderRegister(self, ...)
|
|
7
|
+
local args = {...}
|
|
8
|
+
subscriptions[#subscriptions + 1] = args
|
|
9
|
+
end
|
|
10
|
+
function ____exports.postPitRenderFire(self, pit)
|
|
11
|
+
local gridEntityVariant = pit:GetVariant()
|
|
12
|
+
for ____, ____value in ipairs(subscriptions) do
|
|
13
|
+
local callback = ____value[1]
|
|
14
|
+
local callbackGridEntityVariant = ____value[2]
|
|
15
|
+
do
|
|
16
|
+
if callbackGridEntityVariant ~= nil and callbackGridEntityVariant ~= gridEntityVariant then
|
|
17
|
+
goto __continue5
|
|
18
|
+
end
|
|
19
|
+
callback(nil, pit)
|
|
20
|
+
end
|
|
21
|
+
::__continue5::
|
|
22
|
+
end
|
|
23
|
+
end
|
|
24
|
+
return ____exports
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
local ____exports = {}
|
|
2
|
+
local subscriptions = {}
|
|
3
|
+
function ____exports.postPitUpdateHasSubscriptions(self)
|
|
4
|
+
return #subscriptions > 0
|
|
5
|
+
end
|
|
6
|
+
function ____exports.postPitUpdateRegister(self, ...)
|
|
7
|
+
local args = {...}
|
|
8
|
+
subscriptions[#subscriptions + 1] = args
|
|
9
|
+
end
|
|
10
|
+
function ____exports.postPitUpdateFire(self, pit)
|
|
11
|
+
local gridEntityVariant = pit:GetVariant()
|
|
12
|
+
for ____, ____value in ipairs(subscriptions) do
|
|
13
|
+
local callback = ____value[1]
|
|
14
|
+
local callbackGridEntityVariant = ____value[2]
|
|
15
|
+
do
|
|
16
|
+
if callbackGridEntityVariant ~= nil and callbackGridEntityVariant ~= gridEntityVariant then
|
|
17
|
+
goto __continue5
|
|
18
|
+
end
|
|
19
|
+
callback(nil, pit)
|
|
20
|
+
end
|
|
21
|
+
::__continue5::
|
|
22
|
+
end
|
|
23
|
+
end
|
|
24
|
+
return ____exports
|
|
@@ -1,6 +1,7 @@
|
|
|
1
|
-
import { PlayerVariant } from "isaac-typescript-definitions";
|
|
1
|
+
import { PlayerType, PlayerVariant } from "isaac-typescript-definitions";
|
|
2
2
|
import { HealthType } from "../../enums/HealthType";
|
|
3
3
|
export declare type PostPlayerChangeHealthRegisterParameters = [
|
|
4
4
|
callback: (player: EntityPlayer, healthType: HealthType, amount: int) => void,
|
|
5
|
-
playerVariant?: PlayerVariant
|
|
5
|
+
playerVariant?: PlayerVariant,
|
|
6
|
+
character?: PlayerType
|
|
6
7
|
];
|
|
@@ -8,13 +8,18 @@ function ____exports.postPlayerChangeHealthRegister(self, ...)
|
|
|
8
8
|
subscriptions[#subscriptions + 1] = args
|
|
9
9
|
end
|
|
10
10
|
function ____exports.postPlayerChangeHealthFire(self, player, healthType, amount)
|
|
11
|
+
local character = player:GetPlayerType()
|
|
11
12
|
for ____, ____value in ipairs(subscriptions) do
|
|
12
13
|
local callback = ____value[1]
|
|
13
14
|
local playerVariant = ____value[2]
|
|
15
|
+
local callbackCharacter = ____value[3]
|
|
14
16
|
do
|
|
15
17
|
if playerVariant ~= nil and playerVariant ~= player.Variant then
|
|
16
18
|
goto __continue5
|
|
17
19
|
end
|
|
20
|
+
if callbackCharacter ~= nil and callbackCharacter ~= character then
|
|
21
|
+
goto __continue5
|
|
22
|
+
end
|
|
18
23
|
callback(nil, player, healthType, amount)
|
|
19
24
|
end
|
|
20
25
|
::__continue5::
|
|
@@ -1,4 +1,5 @@
|
|
|
1
|
-
import { PlayerType } from "isaac-typescript-definitions";
|
|
1
|
+
import { PlayerType, PlayerVariant } from "isaac-typescript-definitions";
|
|
2
2
|
export declare type PostPlayerChangeTypeRegisterParameters = [
|
|
3
|
-
callback: (player: EntityPlayer, oldCharacter: PlayerType, newCharacter: PlayerType) => void
|
|
3
|
+
callback: (player: EntityPlayer, oldCharacter: PlayerType, newCharacter: PlayerType) => void,
|
|
4
|
+
playerVariant?: PlayerVariant
|
|
4
5
|
];
|
|
@@ -10,7 +10,14 @@ end
|
|
|
10
10
|
function ____exports.postPlayerChangeTypeFire(self, player, oldCharacter, newCharacter)
|
|
11
11
|
for ____, ____value in ipairs(subscriptions) do
|
|
12
12
|
local callback = ____value[1]
|
|
13
|
-
|
|
13
|
+
local playerVariant = ____value[2]
|
|
14
|
+
do
|
|
15
|
+
if playerVariant ~= nil and playerVariant ~= player.Variant then
|
|
16
|
+
goto __continue5
|
|
17
|
+
end
|
|
18
|
+
callback(nil, player, oldCharacter, newCharacter)
|
|
19
|
+
end
|
|
20
|
+
::__continue5::
|
|
14
21
|
end
|
|
15
22
|
end
|
|
16
23
|
return ____exports
|
|
@@ -1,5 +1,6 @@
|
|
|
1
|
-
import { DamageFlag, PlayerVariant } from "isaac-typescript-definitions";
|
|
1
|
+
import { DamageFlag, PlayerType, PlayerVariant } from "isaac-typescript-definitions";
|
|
2
2
|
export declare type PostPlayerFatalDamageRegisterParameters = [
|
|
3
3
|
callback: (player: EntityPlayer, damageAmount: float, damageFlags: BitFlags<DamageFlag>, damageSource: EntityRef, damageCountdownFrames: int) => boolean | void,
|
|
4
|
-
playerVariant?: PlayerVariant
|
|
4
|
+
playerVariant?: PlayerVariant,
|
|
5
|
+
character?: PlayerType
|
|
5
6
|
];
|
|
@@ -8,13 +8,18 @@ function ____exports.postPlayerFatalDamageRegister(self, ...)
|
|
|
8
8
|
subscriptions[#subscriptions + 1] = args
|
|
9
9
|
end
|
|
10
10
|
function ____exports.postPlayerFatalDamageFire(self, player, damageAmount, damageFlags, damageSource, damageCountdownFrames)
|
|
11
|
+
local character = player:GetPlayerType()
|
|
11
12
|
for ____, ____value in ipairs(subscriptions) do
|
|
12
13
|
local callback = ____value[1]
|
|
13
14
|
local playerVariant = ____value[2]
|
|
15
|
+
local callbackCharacter = ____value[3]
|
|
14
16
|
do
|
|
15
17
|
if playerVariant ~= nil and playerVariant ~= player.Variant then
|
|
16
18
|
goto __continue5
|
|
17
19
|
end
|
|
20
|
+
if callbackCharacter ~= nil and callbackCharacter ~= character then
|
|
21
|
+
goto __continue5
|
|
22
|
+
end
|
|
18
23
|
local shouldSustainDeath = callback(
|
|
19
24
|
nil,
|
|
20
25
|
player,
|
|
@@ -1,5 +1,6 @@
|
|
|
1
|
-
import { PlayerVariant } from "isaac-typescript-definitions";
|
|
1
|
+
import { PlayerType, PlayerVariant } from "isaac-typescript-definitions";
|
|
2
2
|
export declare type PostPlayerInitLateRegisterParameters = [
|
|
3
3
|
callback: (player: EntityPlayer) => void,
|
|
4
|
-
playerVariant?: PlayerVariant
|
|
4
|
+
playerVariant?: PlayerVariant,
|
|
5
|
+
character?: PlayerType
|
|
5
6
|
];
|
|
@@ -8,13 +8,18 @@ function ____exports.postPlayerInitLateRegister(self, ...)
|
|
|
8
8
|
subscriptions[#subscriptions + 1] = args
|
|
9
9
|
end
|
|
10
10
|
function ____exports.postPlayerInitLateFire(self, player)
|
|
11
|
+
local character = player:GetPlayerType()
|
|
11
12
|
for ____, ____value in ipairs(subscriptions) do
|
|
12
13
|
local callback = ____value[1]
|
|
13
14
|
local playerVariant = ____value[2]
|
|
15
|
+
local callbackCharacter = ____value[3]
|
|
14
16
|
do
|
|
15
17
|
if playerVariant ~= nil and playerVariant ~= player.Variant then
|
|
16
18
|
goto __continue5
|
|
17
19
|
end
|
|
20
|
+
if callbackCharacter ~= nil and callbackCharacter ~= character then
|
|
21
|
+
goto __continue5
|
|
22
|
+
end
|
|
18
23
|
callback(nil, player)
|
|
19
24
|
end
|
|
20
25
|
::__continue5::
|
|
@@ -1,5 +1,6 @@
|
|
|
1
|
-
import { PlayerVariant } from "isaac-typescript-definitions";
|
|
1
|
+
import { PlayerType, PlayerVariant } from "isaac-typescript-definitions";
|
|
2
2
|
export declare type PostPlayerInitReorderedRegisterParameters = [
|
|
3
3
|
callback: (player: EntityPlayer) => void,
|
|
4
|
-
playerVariant?: PlayerVariant
|
|
4
|
+
playerVariant?: PlayerVariant,
|
|
5
|
+
character?: PlayerType
|
|
5
6
|
];
|
|
@@ -8,13 +8,18 @@ function ____exports.postPlayerInitReorderedRegister(self, ...)
|
|
|
8
8
|
subscriptions[#subscriptions + 1] = args
|
|
9
9
|
end
|
|
10
10
|
function ____exports.postPlayerInitReorderedFire(self, player)
|
|
11
|
+
local character = player:GetPlayerType()
|
|
11
12
|
for ____, ____value in ipairs(subscriptions) do
|
|
12
13
|
local callback = ____value[1]
|
|
13
14
|
local playerVariant = ____value[2]
|
|
15
|
+
local callbackCharacter = ____value[3]
|
|
14
16
|
do
|
|
15
17
|
if playerVariant ~= nil and playerVariant ~= player.Variant then
|
|
16
18
|
goto __continue5
|
|
17
19
|
end
|
|
20
|
+
if callbackCharacter ~= nil and callbackCharacter ~= character then
|
|
21
|
+
goto __continue5
|
|
22
|
+
end
|
|
18
23
|
callback(nil, player)
|
|
19
24
|
end
|
|
20
25
|
::__continue5::
|
|
@@ -1,5 +1,6 @@
|
|
|
1
|
-
import { PlayerVariant } from "isaac-typescript-definitions";
|
|
1
|
+
import { PlayerType, PlayerVariant } from "isaac-typescript-definitions";
|
|
2
2
|
export declare type PostPlayerRenderReorderedRegisterParameters = [
|
|
3
3
|
callback: (player: EntityPlayer) => void,
|
|
4
|
-
playerVariant?: PlayerVariant
|
|
4
|
+
playerVariant?: PlayerVariant,
|
|
5
|
+
character?: PlayerType
|
|
5
6
|
];
|
|
@@ -8,13 +8,18 @@ function ____exports.postPlayerRenderReorderedRegister(self, ...)
|
|
|
8
8
|
subscriptions[#subscriptions + 1] = args
|
|
9
9
|
end
|
|
10
10
|
function ____exports.postPlayerRenderReorderedFire(self, player)
|
|
11
|
+
local character = player:GetPlayerType()
|
|
11
12
|
for ____, ____value in ipairs(subscriptions) do
|
|
12
13
|
local callback = ____value[1]
|
|
13
14
|
local playerVariant = ____value[2]
|
|
15
|
+
local callbackCharacter = ____value[3]
|
|
14
16
|
do
|
|
15
17
|
if playerVariant ~= nil and playerVariant ~= player.Variant then
|
|
16
18
|
goto __continue5
|
|
17
19
|
end
|
|
20
|
+
if callbackCharacter ~= nil and callbackCharacter ~= character then
|
|
21
|
+
goto __continue5
|
|
22
|
+
end
|
|
18
23
|
callback(nil, player)
|
|
19
24
|
end
|
|
20
25
|
::__continue5::
|
|
@@ -1,5 +1,6 @@
|
|
|
1
|
-
import { PlayerVariant } from "isaac-typescript-definitions";
|
|
1
|
+
import { PlayerType, PlayerVariant } from "isaac-typescript-definitions";
|
|
2
2
|
export declare type PostPlayerUpdateReorderedRegisterParameters = [
|
|
3
3
|
callback: (player: EntityPlayer) => void,
|
|
4
|
-
playerVariant?: PlayerVariant
|
|
4
|
+
playerVariant?: PlayerVariant,
|
|
5
|
+
character?: PlayerType
|
|
5
6
|
];
|
|
@@ -8,13 +8,18 @@ function ____exports.postPlayerUpdateReorderedRegister(self, ...)
|
|
|
8
8
|
subscriptions[#subscriptions + 1] = args
|
|
9
9
|
end
|
|
10
10
|
function ____exports.postPlayerUpdateReorderedFire(self, player)
|
|
11
|
+
local character = player:GetPlayerType()
|
|
11
12
|
for ____, ____value in ipairs(subscriptions) do
|
|
12
13
|
local callback = ____value[1]
|
|
13
14
|
local playerVariant = ____value[2]
|
|
15
|
+
local callbackCharacter = ____value[3]
|
|
14
16
|
do
|
|
15
17
|
if playerVariant ~= nil and playerVariant ~= player.Variant then
|
|
16
18
|
goto __continue5
|
|
17
19
|
end
|
|
20
|
+
if callbackCharacter ~= nil and callbackCharacter ~= character then
|
|
21
|
+
goto __continue5
|
|
22
|
+
end
|
|
18
23
|
callback(nil, player)
|
|
19
24
|
end
|
|
20
25
|
::__continue5::
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
local ____exports = {}
|
|
2
|
+
local subscriptions = {}
|
|
3
|
+
function ____exports.postPoopRenderHasSubscriptions(self)
|
|
4
|
+
return #subscriptions > 0
|
|
5
|
+
end
|
|
6
|
+
function ____exports.postPoopRenderRegister(self, ...)
|
|
7
|
+
local args = {...}
|
|
8
|
+
subscriptions[#subscriptions + 1] = args
|
|
9
|
+
end
|
|
10
|
+
function ____exports.postPoopRenderFire(self, poop)
|
|
11
|
+
local gridEntityVariant = poop:GetVariant()
|
|
12
|
+
for ____, ____value in ipairs(subscriptions) do
|
|
13
|
+
local callback = ____value[1]
|
|
14
|
+
local callbackGridEntityVariant = ____value[2]
|
|
15
|
+
do
|
|
16
|
+
if callbackGridEntityVariant ~= nil and callbackGridEntityVariant ~= gridEntityVariant then
|
|
17
|
+
goto __continue5
|
|
18
|
+
end
|
|
19
|
+
callback(nil, poop)
|
|
20
|
+
end
|
|
21
|
+
::__continue5::
|
|
22
|
+
end
|
|
23
|
+
end
|
|
24
|
+
return ____exports
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
local ____exports = {}
|
|
2
|
+
local subscriptions = {}
|
|
3
|
+
function ____exports.postPoopUpdateHasSubscriptions(self)
|
|
4
|
+
return #subscriptions > 0
|
|
5
|
+
end
|
|
6
|
+
function ____exports.postPoopUpdateRegister(self, ...)
|
|
7
|
+
local args = {...}
|
|
8
|
+
subscriptions[#subscriptions + 1] = args
|
|
9
|
+
end
|
|
10
|
+
function ____exports.postPoopUpdateFire(self, poop)
|
|
11
|
+
local gridEntityVariant = poop:GetVariant()
|
|
12
|
+
for ____, ____value in ipairs(subscriptions) do
|
|
13
|
+
local callback = ____value[1]
|
|
14
|
+
local callbackGridEntityVariant = ____value[2]
|
|
15
|
+
do
|
|
16
|
+
if callbackGridEntityVariant ~= nil and callbackGridEntityVariant ~= gridEntityVariant then
|
|
17
|
+
goto __continue5
|
|
18
|
+
end
|
|
19
|
+
callback(nil, poop)
|
|
20
|
+
end
|
|
21
|
+
::__continue5::
|
|
22
|
+
end
|
|
23
|
+
end
|
|
24
|
+
return ____exports
|