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

Better Hammer Bros #403

Merged
merged 14 commits into from
Aug 13, 2024
Merged

Better Hammer Bros #403

merged 14 commits into from
Aug 13, 2024

Conversation

WilliamFr0g
Copy link
Contributor

No description provided.

Make them less brutally unfair so much of the time
It was truly stupidly long
So they aren't so hard to stomp even after you take damage
Missed a condition
I missed another one, can't do anything first try
@alesan99 alesan99 added the change An existing feature should be tweaked label May 29, 2022
@alesan99
Copy link
Owner

alesan99 commented Jan 4, 2023

I would encourage the use of more variables (like groundfreezetime).

@alesan99 alesan99 added the uncertain This doesn't seem right label Jan 4, 2023
@WilliamFr0g
Copy link
Contributor Author

Global variables in variables.lua is very annoying. It just means you have to do more looking to find them: first you have to check the actual enemy lua to find the variable name or if it's there at all, then go fishing in the sea that is variables.lua

@alesan99
Copy link
Owner

alesan99 commented May 1, 2023

Global variables in variables.lua is very annoying. It just means you have to do more looking to find them: first you have to check the actual enemy lua to find the variable name or if it's there at all, then go fishing in the sea that is variables.lua

Consistency is nice
And its not much of an issue with ctrl f and a good IDE

@WilliamFr0g
Copy link
Contributor Author

WilliamFr0g commented Aug 1, 2023

I don't use a good ide, I use notepad and 7zip and it's constantly painful. What even is the point? It's a 1.6 thing and 1.6 is chock full of short-sighted choices. It's not even a case where the variable is used in multiple locations

@qixils
Copy link
Collaborator

qixils commented Nov 3, 2023

Using constant variables is just good programming practice to A) help annotate your code / make it more clear what it's doing, and B) so if you decide later you want to change fireball speed or whatever then you can easily do that. You don't have to store them in variables.lua, putting them as locals at the top of hammerbro.lua would be fine as well imo.

@alesan99
Copy link
Owner

alesan99 commented Nov 4, 2023

I don't use a good ide, I use notepad and 7zip and it's constantly painful.

And I think the solution is obvious here

@WilliamFr0g
Copy link
Contributor Author

WilliamFr0g commented Nov 9, 2023

Having them as local variables is fine, it's having them in variables.lua that I find problematic. Variables.lua is cluttered with numbers or other constants that are only used one single time, and serve only to make finding each other more difficult. If you've looked at #583 I give some examples there. It has no benefit over having them near the usage, and only makes finding them take extra steps, even with an IDE. Also I don't think the obvious solution to "the code is hard to read" is the equivalent of "use a magnifying glass"

@alesan99
Copy link
Owner

alesan99 commented Nov 9, 2023

No one is really questioning whether or not mari0s code is bad and disorganized. If we were starting over sure but it's not worth the time or potential oversights changing it at this point, so might as well try to stay consistent so you at least know the variables will probably be in variables.lua
In vscode I can just search for it instantly throughout all files in the same time it would take me to look at the local variables so hardly an issue for me at least

Still can't believe how long they were (and technically still are, hurry up Alesan please)
Stars don't make you invincible, Mari0 makes perfect sense
@WilliamFr0g
Copy link
Contributor Author

There, it uses variables, and also I fixed a bug (which I knew about, but I was too lazy to do before this had any more attention)

The balls bouncing off walls was horrible, I can't believe I forgot it earlier
@WilliamFr0g
Copy link
Contributor Author

Bumping this to remind people of the current state of bros in this game

ice bro

sm16.fire.bros.mp4

WilliamFr0g and others added 4 commits August 12, 2024 17:28
Why not I suppose. Fixes "return to spawn" behavior eating their initial jump, fixes them attaching to tracks automatically, and just cleans up a smidge
Even slightly nicer-er, I also forgot to mention in the last commit that I fixed map height issues
Copy link
Collaborator

@qixils qixils left a comment

Choose a reason for hiding this comment

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

Cleaned up variables (they're used a little bit more, and there's no longer unused global variables), updated to LÖVE 11, and fixed some bugs; LGTM

@alesan99 alesan99 merged commit 26b9168 into alesan99:master Aug 13, 2024
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
change An existing feature should be tweaked uncertain This doesn't seem right
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants