Open halstead opened 11 years ago
Question: Does getMovementMod(self): return self.movemod in items.py line 20 actually do anything? Because you seems to never call on the function and instead uses self.movemod directly.
This is a mistake I made. In Java and several other languages you need to use accessor (getter and setter) methods in order to update data on an object. In Python these are never needed. I wrote the getter and setter out of habit from those other languages but then I access the property directly elsewhere as is proper in Python.
You can read more at http://stackoverflow.com/questions/1568091/why-use-getters-and-setters
Please feel free to remove setMovementMod() and getMovementMod() and clean up the code. Good catch. :)
You like mah pretteh bubbles? Looks better ingame
Bubbles are beautiful! What did you draw them with?
Also there is new e-mail about robotics if you didn't see it check your e-mail.
Bubbles were drawn by paint. Duh. Best graphic designing program.
For some reason projectiles (not including aimed fire) would only hit the player or the snake if they are standing on top of each other. Like when i shoot fireegg the snake only catch on fire when im standing on top of it.
in items.py ln 90 what does that if block do exactly? It appears like self.target has the value of None as declared through init.
By default fireballs have no target and fly. One a target is set the fireball sticks to it and starts to burn the target.
In eat_a_snake.py on line 118 the snake will call fireball.use() when the the fireball and snake collide. Then in items.py on line 105 the target is set. From now on a target is set on that fireball so the fireball burns it instead of flying around.
How do you erase a commit, like if you committed 2 but you realized didn't want that last one that you just commit?
What are firetimers and why are they all set to 0? All the fireegg class seems to have that variable.
Oh i get what they're for now. Attack delays and confusion tactic against nooby programmers.
Yeah they limit how fast fireballs are spawned.
You can remove the last commit if you didn't push it with "git reset --soft HEAD~1" otherwise you can use git revert to make a new commit the reverses your changes.
Aww yeah. Finally get hunter to eat master fork and gaining its power. There's no limiters on how fast you can shoot right now, so probably add that later.
Time to play some vidya.
Forks are working awesome but duel fork is OP. See screenshot. (jk)
I'm on it >:D
Is there a way to tell exactly which part of a sprite that another sprite collided at? For example, a way to tell whether the fireball collided on top of the hunter (rect.top) or bottom(rect.bottom) or etc...
I dug up the pygame documentation but the closest i got was mask which is used for precise collision but doesn't seems to return which part the of the sprites that collided.
Once you find the colliding sprites you can get both their .rect rectangles and do some comparisons of the .rect.topleft properties and such to find where they overlap if needed. On Jul 2, 2013 2:43 AM, "tinlun123" notifications@github.com wrote:
Is there a way to tell exactly which part of a sprite that another sprite collided at? For example, a way to tell whether the fireball collided on top of the hunter (rect.top) or bottom(rect.bottom) or etc...
I dug up the pygame documentation but the closest i got was mask which is used for precise collision but doesn't seems to return which part the of the sprites that collided.
— Reply to this email directly or view it on GitHubhttps://github.com/eliza411/freezing-octo-snake/issues/1#issuecomment-20336181 .
It would be nice to have forks in the game. Perhaps they shoot fire to start with. Later we could change them to stab snakes or something.