Jump to content
  • The forum downloads section will be removed on Jan 1st 2023. Players may still download mods that are currently hosted, but new submissions are no longer being accepted. Mod makers are advised to relocate their mods to alternative hosting solutions.

1 Screenshot

  • Like 1
  • Thanks 1
  • Haha 1
  • Sad 2

User Feedback

Recommended Comments

It didn't work, it may be the version, but it helped to understand how it worked, so I changed the code inside the original file and it worked

\data\DLC0003\scripts\prefabs\shop_pedestals.lua

change function buyer

before

local function buyer()
    local inst = common()
    inst:AddComponent("shopdispenser")
    inst:AddComponent("shopped")

    inst:ListenForEvent("daytime", function() restock(inst) end, GetWorld())
    inst:ListenForEvent("beginfiesta", function() restock(inst,true) end, GetWorld())
    inst:ListenForEvent("endfiesta", function() restock(inst,true) end, GetWorld())

    return inst
end

after

local function buyer()
    local inst = common()
    inst:AddComponent("shopdispenser")
    inst:AddComponent("shopped")

    inst:ListenForEvent("daytime", function() restock(inst) end, GetWorld())
    inst:ListenForEvent("beginfiesta", function() restock(inst,true) end, GetWorld())
    inst:ListenForEvent("endfiesta", function() restock(inst,true) end, GetWorld())
	
    inst:ListenForEvent("daycomplete", 
		function() 
		
			print("DAY_COMPLETE") 
			SoldItem(inst)
		
		end
		
	, GetWorld())
	
    return inst
end

sorry my english, i'm using google translate

Link to comment
Share on other sites

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...