Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

PWhiddy patches applied pokemon_red.py #49

Open
wants to merge 2 commits into
base: 0.5-cleanup
Choose a base branch
from

Conversation

techmore
Copy link

@techmore techmore commented Oct 22, 2023

There was a section about health I was not sure how to integrate so I added those lines commented out.

Current code line 418

        # healing reward
        curr_health = self.read_hp_fraction()
        self.rewards["healing"] = self.cfg["rewards"]["healing_scale"] * max(0, curr_health - self.cfg["state_params"]["health"])
        if self.cfg["state_params"]["health"] <= 0: self.death_count += 1
        self.cfg["state_params"]["health"] = curr_health

New pushed code that is commented out

        '''
        # Not sure where to integrate
        prog = self.progress_reward
        # these values are only used by memory
        return (prog['level'] * 100 / self.reward_scale, 
                self.read_hp_fraction()*2000, 
                prog['explore'] * 150 / (self.explore_weight * self.reward_scale))
        '''

There was a section about health I was not sure how to integrate so I added those lines commented out.
Copy link
Author

@techmore techmore left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Added changes from Rousk

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant