Skip to main content

Indie game storeFree gamesFun gamesHorror games
Game developmentAssetsComics
SalesBundles
Jobs
TagsGame Engines
(+1)

Pigfish event doesn't trigger in 0.19 because

$ have_gala_panties = "stolen panties" in inventory.keys()

is always False since it checks for string equality in collection. Instead it should be

# player has panties in inventory
$ have_gala_panties = False
# for inventory manipulation
$ found_panties = ""
python:
    # item is a string
    for item in inventory.keys():
        # "in" for strings checks for substrings instead of string "in" collection which checks for equality only
        if "stolen panties" in item:
            have_gala_panties = True
            found_panties = item
            # panties found, if you want to delete last instead of first found then comment this break
            break

Since in this case "in" works on strings and produces expected result.

Also deleting should be updated to

if (inventory[found_panties]["count"]!=1):
    $ inventory[found_panties]["count"]-=1
else:
    $ del inventory[found_panties]

Though I would strongly advise to create a function for deleting item(s) since that's their point - to write repetetive code once and then use it later. Or better yet create class for inventory to contain everything related to it including deletion.

(+1)

Also why is the outline of Pigfish in Gendalf/Sauron room so tiny?

(+1)

When starting the game, I didn't know much about renpy. It's my first game. So some outlines are made by manually creating PNGs. 
At some point I learned how to procedurally generate outlines, so new ones are pretty different than old ones. 

Hey hidnight,
thanks a lot for taking time and finding it! I changed the code so it will be ok in 0.21.x. Completely forgot I changed panties naming at some point...
Agree that having a function for it makes sense, I will consider it, also need to consider the cost. which is refactoring a lot of old stuff + testing. 


(+1)

Great. It's your project and you should decide what to do. It's more of a design decision that should be made at the start of the project but, hey, now you've gained new knowledge to apply in future projects.

A cursory grep

grep -iGR --include=*.rpy 'del inventory' ./ | wc -l

gave 62 occurrences so yeah searching and rewriting will be a pain.