coding help.

Im developing a game where after acquiring 6 different items, the game ends. how do I code this?

Which bit do you need help with, and what do you have so far?

Any six items, or six specific items? And are you using Inform 7 or Inform 6?

Also: does the player need to be holding all 6 items, or merely have picked them up at some point?

Without knowing anything else, I think I can at least say you’ll need an Every Turn rule:

Every turn when at least six treasures are carried: say "At last you possess [the list of carried treasures]!"; end the story finally saying "You can retire now";

If you need that to happen right away before any other turn sequence rules or triggered actions, you can have it run “after doing anything” or maybe just “after taking.” You can also give it a name and invoke it in multiple places:

[code]Every turn (this is the check for victory rule):
if at least six treasures are carried:
end the story finally saying “You have won”.

After taking something:
abide by the check for victory rule;
continue the action.[/code]