Giter VIP home page Giter VIP logo

feini's People

Contributors

noyainrain avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

feini's Issues

Vary food ๐Ÿฒ

Make it possible to feed the pet with different food.

Draft

class Space:
    ITEM_CATEGORIES = {'food': ['๐Ÿฅ•', '๐Ÿฒ']}

class Pet:
    async def feed(self, food: str) -> None:
        """Feed the pet with *food*."""
๐Ÿฅ•
๐Ÿฒ
Feed the pet. Stew evokes a ๐Ÿ˜ reaction.

Craft with blueprints ๐Ÿ“‹

Instead of a fixed set of craftable objects, start with a basic set of blueprints and let the player learn more in the course of the game.

Draft

class Space:
    async def get_blueprints(self) -> list[str]:
        """Get known blueprints."""

    async def craft(self, blueprint: str) -> str | Object:
        """Craft a new object given by *blueprint*."""

Dress pet ๐ŸŽ€

Make it possible to dress the pet in different clothing.

Draft

class Space:
    """Item categories."""
    ITEM_CATEGORIES = {
        'resource': ['๐Ÿฅ•', '๐Ÿชจ', '๐Ÿชต', '๐Ÿงถ'],
        'clothing': ['๐Ÿ•ถ๏ธ', '๐ŸŽ€']
    }

class Pet:
    """Clothing the pet is wearing."""
    clothing: str | None

    async def dress(self, clothing: str | None) -> None:
        """Dress the pet in the given *clothing*."""

Pet representation:

  • ๐Ÿ• (without clothing)
  • ๐Ÿ•๐ŸŽ€ (with clothing)

Dress actions:
๐ŸŽ€
Dress in ribbon. Undress if already wearing ribbon.

Potential emojis: https://unicode.org/emoji/charts/emoji-list.html#clothing

View furniture details ๐Ÿ“บ

Let the player view details about a furniture piece, like its state or content.

Draft

Add Content.url and summary (see #12).

๐ŸŒบ The houseplant is in full bloom.

๐Ÿ“บ Buffy the Vampire Slayer is on. Into every generation a slayer is born: one girl in all the
world, a chosen one. She alone will wield the strength and skill to fight the vampires, demons, and
the forces of darkness; to stop the spread of their evil and the swell of their number. She is the
Slayer. https://www.themoviedb.org/tv/95-buffy-the-vampire-slayer

๐Ÿ—ž๏ธ Digital pet Tamagotchi turns 25. Adorable, or annoying? The tiny digital egg beeped in the
pockets of millions of children all over the world. But the hype surrounding the little nuisance
ended as quickly as it began. https://www.dw.com/en/digital-pet-tamagotchi-turns-25/a-61709227

๐Ÿ–ผ๏ธ The painting is composed of abstract patterns in gentle colors, which still evoke a delicate
impression of reality.

Tasks

  • Implement draft
  • Use collapse() utility
  • Content: Validate url
  • TMDB: Handle optional overview
  • Merge updates into update_content_url()
  • view_television() / view_newspaper(): Make summary optional

Sew with patterns ๐Ÿ“‹

Let the player learn sewing patterns over the course of the game.

Draft

class Space:
    """Weights by which sewing patterns are ordered."""
    PATTERN_WEIGHTS: dict[str, int]

    async def get_patterns(self) -> list[str]:
        """Get known sewing patterns."""

Celebrate harvest festival ๐ŸŽƒ

Simulate annual dates and unlock seasonal furniture (๐ŸŽƒโšฑ๏ธ๐Ÿฎ) and clothing (๐ŸŽฉ) for the harvest festival.

Draft

class Schedule:
    """Simulation schedule of a :class:`Space`."""

    """Related space."""
    space: Space

    class DateMethod:
        """Simulate an annual date."""

        """Annotated function."""
        func: Callable[[Schedule], Awaitable[None]]
        """Month of the date."""
        month: int
        """Day of the date."""
        day: int

    @staticmethod
    def date(month: int, day: int) -> Callable[[Callable[[Schedule], Awaitable[None]]], DateMethod]:
        """Decorator to define an annual date on *day* of *month*."""
        return partial(Schedule.DateMethod, month=month, day=day)

    async def run(self) -> None:
        """Simulate all scheduled dates."""

    # Example
    @date(31, 10)
    async def start_jenseits_festival(self) -> None: ...

class Space:
    """Simulation schedule."""
    schedule: Schedule

Alf ๐Ÿง, the rural hedonist:

  • Greetings friend, the name is Alf! As the leaves begin to fall, Jenseits festival is drawing near!
  • Lanterns made from carved pumpkins ward off malicious spirits. (You get a carved pumpkin blueprint ๐Ÿ“‹๐ŸŽƒ)
  • This time of year, graves open up a path to Jenseits through which spirits may enter our world. (You get an urn blueprint ๐Ÿ“‹โšฑ๏ธ)
  • (Alf is almost drooling) What would I do for a seasonal delicacy, like a hearty stew ๐Ÿฒ?
  • (You give ๐Ÿฒ to Alf) I'm delighted, friend! Are you dressing up for the festival? (You get a top hat pattern ๐Ÿ“‹๐ŸŽฉ)
  • Jenseits festival is drawing near!
  • Enjoy Jenseits festival, friend!

Fetch current TV shows and news ๐Ÿ“บ๐Ÿ—ž๏ธ

Get current popular TV shows from TMDB and current news from DW.

Draft

@dataclass
class Content:
    """Media content."""

    """Title of the content."""
    title: str

    # Future reference
    """URL of the content or information about it."""
    url: str
    """Short summary."""
    summary: str | None = None

    @staticmethod
    def parse(data: str) -> Content:
        """Parse the string representation *data* into media content."""

class TMDB:
    """The Movie Database source."""

    """Time to live for cached content."""
    CACHE_TTL = timedelta(days=1)

    """API key to fetch the current popular TV shows."""
    key: str | None = None

    """Current TV shows, ordered by popularity, highest first."""
    shows: list[Content] = [Content('Buffy the Vampire Slayer')]

    async def close(self) -> None:
        """Close the source."""

class DW:
    """Deutsche Welle source."""

    """Time to live for cached content."""
    CACHE_TTL = timedelta(days=1)

    """Current news articles, ordered by time, latest first."""
    news: list[Content] = [Content('Digital pet Tamagotchi turns 25')]

    async def close(self) -> None:
        """Close the source."""

class Bot:
    """The Movie Database source."""
    tmdb: TMDB

    """Deutsche Welle source."""
    dw: DW

Tasks

  • Implement draft
  • TMDB: Log fetching
  • TMDB.close(): Cancel task
  • DW: Handle feedparser errors
  • TMDB / DW: Rename _expires to _cache_expires
  • TelevisionTest.test_use() / NewspaperTest.test_use(): Check show / article against TMDB / DW
  • fe.ini: Add tmdb section
  • Add TMDBTest / DWTest

Add extendable Event โšก

Enable event arguments.

Draft

class Event:
    """Game event."""

    """Type of the event."""
    type: str

    """ID of the :class:`Space` where the event happened."""
    space_id: str

    @staticmethod
    def parse(data: str) -> Event:
        """Parse the string representation *data* into an event."""

    async def get_space(self) -> Space:
        """Get the space where the event happened."""

class Bot:
    async def events(self) -> AsyncIterator[Event]:
        """Stream of game events."""

# Future reference
class NudgeEvent(Event):
    """Event about a nudge from the pet."""

    """Activity emoji or ID of the furniture piece to engage with."""
    activity_id: str

    @staticmethod
    def parse(data: str) -> NudgeEvent: ...

    async def get_activity(self) -> Furniture | str:
        """Get the activity emoji or ID of the furniture piece to engage with."""

Tasks

  • Implement draft
  • update_event_format(): Guard with โŸ
  • Redis: Type lset()

Engage pet with furniture โšพ

Let the player play with the pet using furniture.

Draft

class Pet:
    """Available stand-alone activities."""
    ACTIVITIES: set[str]

    async def engage(self, activity: Furniture | str) -> None:
        """Engage the pet in the given *activity*."""
๐Ÿชƒ
โšพ
๐Ÿงธ
๐Ÿ›‹๏ธ
โ›ฒ
Engage the pet with a furniture piece.

Simulate relationship reciprocity ๐Ÿค

Track the reciprocity level of the relationship to the player and make the pet nudge the player based on the reciprocity.

Depends on #14.

Draft

_F = TypeVar('_F', bound=Callable[..., object])

class Pet:
    """Level at which the relationship with the player feels completely reciprocal."""
    RECIPROCITY_MAX = 72

    """Current reciprocity level of the relationship to the player."""
    reciprocity: int

    @staticmethod
    def social(func: _F) -> _F:
        """Decorator to make a social interaction between the player and the pet.

        Social interactions influence the :attr:`reciprocity`.
        """

class Space:
    """
    .. describe:: space-nudge

       Dispatched when the pet nudges the player.
    """

class NudgeEvent(Event):
    """Event about a nudge from the pet."""

    """Intended activity emoji or ID of the furniture piece to engage with."""
    activity_id: str

    @staticmethod
    def parse(data: str) -> NudgeEvent: ...

    async def get_activity(self) -> Furniture | str:
        """Get the intended activity emoji or ID of the furniture piece to engage with."""

class FurnitureProperties(TypedDict):
    """Properties of a furniture piece."""

    """Indicates if the furniture piece is portable or fixed."""
    portable: bool

    # Future reference
    """Needed material."""
    material: list[str]

"""Properties of each furniture piece."""
FURNITURE_PROPERTIES: dict[str, FurnitureProperties]
โšพ๐Ÿ• Feini drops the โšพ item next to you and looks at you with anticipation. Woof! ๐Ÿ˜Š

๐Ÿชด๐Ÿ• Feini calls you over to the ๐Ÿชด furniture piece. Woof! ๐Ÿ˜Š

๐Ÿ• Feini gently nudges you with its head. ๐Ÿ˜Š

Tasks

  • Implement draft
  • Pet.tick(): Set activity in transaction
  • Pet.social(): Reset reciprocity with variation
  • update_pet_reciprocity(): Ignore if pet is hatched

Teach blueprints and patterns ๐Ÿ“‹

Make it possible for characters to teach blueprints and patterns.

Draft

class Message:
    """Blueprint or pattern the character teaches to the player."""
    lesson: str

Pan and shower are not usable

i cant use ๐Ÿšฟ ,๐Ÿณ but i have in tent . When i use it(๐Ÿšฟ,๐Ÿณ) say :You have no ๐Ÿšฟ at the moment. Maybe have a look in the tent โ›บ๏ธ?

Add NPCs ๐Ÿ‘ป

Let the player talk to NPCs.

Draft

@dataclass
class Message:
    """Dialogue message."""

    """Message ID."""
    id: str
    """Items the character currently needs, if any."""
    request: list[str]
    """Items the player has just given to the character, if any."""
    taken: list[str]

    @staticmethod
    def parse(data: str) -> Message:
        """Parse the string representation *data* into a message."""

    def encode(self) -> str:
        """Return a string representation of the message."""

class Character:
    """Character."""

    """Character ID."""
    id: str
    """Related :class:`Space` ID."""
    space_id: str
    """Avatar emoji."""
    avatar: str

    async def get_dialogue(self) -> list[Message]:
        """Get the ongoing dialogue, starting from the most recent message."""

    async def talk(self) -> Message:
        """Talk to the character and return their reply.

        If the character has requested some items, give the items to them or repeat the request
        message.
        """

class Space:
    async def get_characters(self) -> list[Character]:
        """Get the present characters."""

Talk actions:

๐Ÿ‘ป Where am I?

Tasks

  • Implement draft
  • Space.get_characters(): Wrap in transaction
  • Message: Validate attributes
  • view_tent(): Visualize furniture with str()
  • talk_to_character(): Get character by args or return absence message
  • CharacterTest: Create character with GhostStory

Tell ghost story ๐Ÿ‘ป

Add a quest which unlocks the sewing needle blueprint.

Draft

class Story:
    """Short story."""

    """Story ID."""
    id: str
    """Related :class:`Space` ID."""
    space_id: str
    """Current point in the story."""
    state: str
    """Tick the state was updated at."""
    update_tick: int

    async def tell(self) -> None:
        """Continue to the next point in the story if the relevant conditions are met."""
        raise NotImplementedError()

class Space:
    async def get_stories(self) -> set[Story]:
        """Get all active stories."""

Ghost ๐Ÿ‘ป, a regretful parent:

  • Where am I?
  • The last thing I remember is sitting in my chair, making a scarf for my daughter.
  • Dear, do you know where I could find ๐Ÿงถ๐Ÿงถ๐Ÿงถ?
  • Please, let me return the favor and introduce you to sewing.
  • Do you think she will forgive me?

Tasks

  • Implement draft
  • Story: Rename state and update_tick to chapter and update_time
  • Space.get_stories(): Get type directly from module
  • Space.tell_stories()
  • Story: Use Bot.time
  • IntroStory: Add start chapter
  • IntroStory: Prefix events with space-explain

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.