Jump to content

Recommended Posts

I want to remove the powder monkey when firing monkeyisland portal.I'm using upvaluehacker by rezecib. But it don't work.
Here is my modmain.lua

local UpvalueHacker = GLOBAL.require("tools/upvaluehacker")

AddPrefabPostInit("monkeyisland_portal", function(inst)

	local portal_event_spawns_patched = {
    	"cutgrass",
        "cutgrass",
        "dug_bananabush",
        "dug_monkeytail",
        "palmcone_seed",
        "palmcone_seed",
       	"rocks",
        "rocks",   -- deleted a "powder monkey" form here
        "twigs",
        "twigs",
    }

	UpvalueHacker.SetUpvalue(GLOBAL.Prefabs.monkeyisland_portal.fn, portal_event_spawns_patched, "on_timer_done", "fire_portal_event", "portal_event_spawns")
end)

It's seems like that the game loaded the original table before the mod applys.How can I sovle this problem?

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
  • Create New...