Mtarnuhal / FrozenCookies

An automated Cookie Clicker tool.
27 stars 22 forks source link

safeBuy buildings when store is in Sell mode #33

Closed piels closed 4 years ago

piels commented 4 years ago

In current version of Cookie Clicker (2.029), Game.Objects[].buy() will actually sell buildings if the store is in sell mode. Since buildings get more efficient when you sell them, this will usually cause FC to sell all of that building type as it keeps trying to autobuy them. The safeBuy() function makes sure the store is in buy mode before trying to buy a building.