The Binding of Isaac: Rebirth

The Binding of Isaac: Rebirth

Angels Drop Items
Sun_Rider 19 Oct @ 8:50am
Сделал фикс
Исправил проблему у себя в этом моде, нужно в файле main.lua (который находится по адресу SteamLibrary\steamapps\common\The Binding of Isaac Rebirth\mods\angels-drop-items_840107435) и заменить функцию function angelItems:entityDeath(entity) на следующий код
function angelItems:entityDeath(entity) if roomState > 0 then local shouldDrop = false if roomState == 3 then shouldDrop = true elseif roomState ~= 0 then for i = 0, Game():GetNumPlayers() - 1 do local player = Game():GetPlayer(i) if entity.Type == EntityType.ENTITY_URIEL and player:HasCollectible(CollectibleType.COLLECTIBLE_KEY_PIECE_1) then shouldDrop = roomState == 1 break elseif entity.Type == EntityType.ENTITY_GABRIEL and player:HasCollectible(CollectibleType.COLLECTIBLE_KEY_PIECE_2) then shouldDrop = roomState == 1 break end end end -- ИСПРАВЛЕННАЯ ЛОГИКА ШАНСА if shouldDrop and (configData["dropChance"] >= 100 or entity:GetDropRNG():RandomInt(100) < configData["dropChance"] + (configData["dropChanceIncrease"] * failedRolls)) then local spawnPos = Isaac.GetFreeNearPosition(entity.Position, 50) local collectibleToSpawn = 0 if configData["useAngelPool"] then -- ИСПРАВЛЕННЫЙ ВЫЗОВ ДЛЯ REPENTANCE+ collectibleToSpawn = Game():GetItemPool():GetCollectible( ItemPoolType.POOL_ANGEL, false, entity:GetDropRNG():Next(), CollectibleType.COLLECTIBLE_NULL, ItemPoolType.POOL_TREASURE ) end -- Проверка на валидность предмета if collectibleToSpawn ~= nil and collectibleToSpawn > 0 then Isaac.Spawn(EntityType.ENTITY_PICKUP, PickupVariant.PICKUP_COLLECTIBLE, collectibleToSpawn, spawnPos, Vector(0, 0), entity) end failedRolls = 0 else failedRolls = failedRolls + 1 end end end
Last edited by Sun_Rider; 19 Oct @ 9:47am
< >
Showing 1-1 of 1 comments
Огонь, все вылеты прекратились, СПС! :steamhappy:
< >
Showing 1-1 of 1 comments
Per page: 1530 50