hsong7273 / superalphapet Goto Github PK
View Code? Open in Web Editor NEWFramework for Simulating Super Auto Pets and Training AI Mastery of the Game
Framework for Simulating Super Auto Pets and Training AI Mastery of the Game
In ModelTrainer, DQN agent tries to execute action 0, move pet 0 to slot 1, when team is empty.
pl = Player(team=['duck']) pl.sell(0)
Raises TypeError
It is unclear if an issue with duck effect or with effects that affect shop. May hint at future issues with Expansion Pack pets
TypeError Traceback (most recent call last)
c:\Users\Hasung\Dropbox\SuperAlphaPet\sapai.ipynb Cell 3 in <cell line: 2>()
[1](vscode-notebook-cell:/c%3A/Users/Hasung/Dropbox/SuperAlphaPet/sapai.ipynb#ch0000014?line=0) pl = Player(team=['duck'])
----> [2](vscode-notebook-cell:/c%3A/Users/Hasung/Dropbox/SuperAlphaPet/sapai.ipynb#ch0000014?line=1) pl.sell(0)
File c:\Users\Hasung\Dropbox\SuperAlphaPet\sapai\player.py:50, in storeaction.<locals>.store_action(*args, **kwargs)
48 player = args[0]
49 action_name = str(func.__name__).split(".")[-1]
---> 50 targets = func(*args,**kwargs)
51 store_targets = []
52 if targets != None:
File c:\Users\Hasung\Dropbox\SuperAlphaPet\sapai\player.py:682, in Player.sell(self, pet)
680 ### Activate sell trigger first
681 for slot in self.team:
--> 682 slot._pet.sell_trigger(pet)
684 if self.team.check_friend(pet):
685 self.team.remove(pet)
File c:\Users\Hasung\Dropbox\SuperAlphaPet\sapai\pets.py:267, in Pet.sell_trigger(self, trigger)
264 if trigger == self:
265 return activated,targets,possible
--> 267 targets,possible = func(self, [0,pet_idx], [self.team], trigger)
269 activated = True
270 return activated,targets,possible
File c:\Users\Hasung\Dropbox\SuperAlphaPet\sapai\effects.py:655, in ModifyStats(apet, apet_idx, teams, te, te_idx, fixed_targets)
653 target_pet._until_end_of_battle_health_buff += health_amount
654 else:
--> 655 target_pet._attack += attack_amount
656 target_pet._health += health_amount
657 if "includingFuture" in apet.ability["effect"]["target"] and apet.ability["effect"]["target"]["includingFuture"] is True:
TypeError: can only concatenate str (not "int") to str```
Currently Pet, Food, and Statuses are indexed in the player.init(). They should be added to the data dictionary.
This index is used for the team and player state vectors, it could be called petID, foodID, statusID
The targeted food boolean should also be added to sapai.data, simply add the "targeted" : true/false to each food item in the data dictionary
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.