isaacscript-common 1.0.507 → 1.0.511
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.
|
@@ -8,8 +8,8 @@ function ____exports.initRNG(self, seed)
|
|
|
8
8
|
seed = Random()
|
|
9
9
|
end
|
|
10
10
|
if seed == 0 then
|
|
11
|
-
error("You cannot initialize an RNG object with a seed of 0, or the game will crash.")
|
|
12
11
|
traceback(nil)
|
|
12
|
+
error("You cannot initialize an RNG object with a seed of 0, or the game will crash.")
|
|
13
13
|
end
|
|
14
14
|
local rng = RNG()
|
|
15
15
|
rng:SetSeed(seed, RECOMMENDED_SHIFT_IDX)
|
|
@@ -121,7 +121,11 @@ export declare function inDimension(dimension: Dimension): boolean;
|
|
|
121
121
|
/** Helper function to determine if the current room shape is one of the four L room shapes. */
|
|
122
122
|
export declare function inLRoom(): boolean;
|
|
123
123
|
export declare function inGenesisRoom(): boolean;
|
|
124
|
-
/**
|
|
124
|
+
/**
|
|
125
|
+
* Helper function to determine whether or not the current room is the starting room of a floor.
|
|
126
|
+
* Only returns true for the starting room of the primary dimension (meaning that being in the
|
|
127
|
+
* starting room of the mirror world does not count).
|
|
128
|
+
*/
|
|
125
129
|
export declare function inStartingRoom(): boolean;
|
|
126
130
|
/**
|
|
127
131
|
* Helper function to determine whether or not the current room is part of the floor layout. For
|
package/dist/functions/rooms.lua
CHANGED
|
@@ -202,7 +202,7 @@ function ____exports.inStartingRoom(self)
|
|
|
202
202
|
local level = game:GetLevel()
|
|
203
203
|
local startingRoomGridIndex = level:GetStartingRoomIndex()
|
|
204
204
|
local roomSafeGridIndex = ____exports.getRoomSafeGridIndex(nil)
|
|
205
|
-
return roomSafeGridIndex == startingRoomGridIndex
|
|
205
|
+
return roomSafeGridIndex == startingRoomGridIndex and ____exports.inDimension(nil, 0)
|
|
206
206
|
end
|
|
207
207
|
function ____exports.isRoomInsideMap(self)
|
|
208
208
|
local roomSafeGridIndex = ____exports.getRoomSafeGridIndex(nil)
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "isaacscript-common",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.511",
|
|
4
4
|
"description": "Helper functions for IsaacScript mods",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"isaac",
|
|
@@ -25,10 +25,10 @@
|
|
|
25
25
|
"dist/**/*.d.ts"
|
|
26
26
|
],
|
|
27
27
|
"devDependencies": {
|
|
28
|
-
"isaac-typescript-definitions": "^1.0.
|
|
29
|
-
"isaacscript-lint": "^1.0.
|
|
28
|
+
"isaac-typescript-definitions": "^1.0.293",
|
|
29
|
+
"isaacscript-lint": "^1.0.71",
|
|
30
30
|
"typedoc": "^0.22.10",
|
|
31
|
-
"typescript": "4.
|
|
32
|
-
"typescript-to-lua": "
|
|
31
|
+
"typescript": "4.4.4",
|
|
32
|
+
"typescript-to-lua": "1.1.1"
|
|
33
33
|
}
|
|
34
34
|
}
|