isaacscript-common 1.2.99 → 1.2.100
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/functions/log.d.ts +1 -0
- package/dist/functions/log.lua +17 -0
- package/package.json +2 -2
package/dist/functions/log.d.ts
CHANGED
|
@@ -39,6 +39,7 @@ export declare function logEntity(this: void, entity: Entity): void;
|
|
|
39
39
|
export declare function logKColor(this: void, kColor: KColor): void;
|
|
40
40
|
export declare function logMap(this: void, map: Map<AnyNotNil, unknown>): void;
|
|
41
41
|
/** Helper function for printing out information about the current room. */
|
|
42
|
+
export declare function logRoom(this: void): void;
|
|
42
43
|
export declare function logTable(this: void, table: unknown, parentTables?: number): void;
|
|
43
44
|
export declare function logTemporaryEffects(this: void, player: EntityPlayer): void;
|
|
44
45
|
export declare function logSet(this: void, set: Set<AnyNotNil>): void;
|
package/dist/functions/log.lua
CHANGED
|
@@ -14,6 +14,11 @@ local ____flag = require("functions.flag")
|
|
|
14
14
|
local hasFlag = ____flag.hasFlag
|
|
15
15
|
local ____player = require("functions.player")
|
|
16
16
|
local getEffectsList = ____player.getEffectsList
|
|
17
|
+
local ____rooms = require("functions.rooms")
|
|
18
|
+
local getRoomListIndex = ____rooms.getRoomListIndex
|
|
19
|
+
local getRoomSafeGridIndex = ____rooms.getRoomSafeGridIndex
|
|
20
|
+
local getRoomSubType = ____rooms.getRoomSubType
|
|
21
|
+
local getRoomVariant = ____rooms.getRoomVariant
|
|
17
22
|
local ____trinkets = require("functions.trinkets")
|
|
18
23
|
local getTrinketName = ____trinkets.getTrinketName
|
|
19
24
|
function ____exports.getDebugPrependString(self, msg, numParentFunctions)
|
|
@@ -124,6 +129,18 @@ function ____exports.logMap(map)
|
|
|
124
129
|
end
|
|
125
130
|
____exports.log("The size of the map was: " .. tostring(map.size))
|
|
126
131
|
end
|
|
132
|
+
function ____exports.logRoom()
|
|
133
|
+
local game = Game()
|
|
134
|
+
local room = game:GetRoom()
|
|
135
|
+
local roomType = room:GetType()
|
|
136
|
+
local roomVariant = getRoomVariant(nil)
|
|
137
|
+
local roomSubType = getRoomSubType(nil)
|
|
138
|
+
local roomSafeGridIndex = getRoomSafeGridIndex(nil)
|
|
139
|
+
local roomListIndex = getRoomListIndex(nil)
|
|
140
|
+
____exports.log((((("Current room type/variant/sub-type: " .. tostring(roomType)) .. ".") .. tostring(roomVariant)) .. ".") .. tostring(roomSubType))
|
|
141
|
+
____exports.log("Current room safe grid index: " .. tostring(roomSafeGridIndex))
|
|
142
|
+
____exports.log("Current room list index: " .. tostring(roomListIndex))
|
|
143
|
+
end
|
|
127
144
|
function ____exports.logTable(____table, parentTables)
|
|
128
145
|
if parentTables == nil then
|
|
129
146
|
parentTables = 0
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "isaacscript-common",
|
|
3
|
-
"version": "1.2.
|
|
3
|
+
"version": "1.2.100",
|
|
4
4
|
"description": "Helper functions for IsaacScript mods",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"isaac",
|
|
@@ -25,7 +25,7 @@
|
|
|
25
25
|
"dist/**/*.d.ts"
|
|
26
26
|
],
|
|
27
27
|
"devDependencies": {
|
|
28
|
-
"@zamiell/typescript-to-lua": "^1.4.
|
|
28
|
+
"@zamiell/typescript-to-lua": "^1.4.2",
|
|
29
29
|
"isaac-typescript-definitions": "^1.0.355",
|
|
30
30
|
"isaacscript-lint": "^1.0.84",
|
|
31
31
|
"isaacscript-tsconfig": "^1.1.8",
|