Page 35 of 68

Re: Noob learns to code in 3 months

Posted: March 9th, 2017, 3:01 pm
by albinopapa
Depends on what you mean by efficient. Memory efficient, probably not but I don't think you are using all that much memory for the entities themselves anyway. CPU efficient, probably since you aren't creating and destroying ( allocating and deallocating ) memory throughout the level.

Honestly, unless you start seeing framerates drop I wouldn't worry about it.

Re: Noob learns to code in 3 months

Posted: March 9th, 2017, 3:38 pm
by Yumtard
albinopapa wrote:Depends on what you mean by efficient. Memory efficient, probably not but I don't think you are using all that much memory for the entities themselves anyway. CPU efficient, probably since you aren't creating and destroying ( allocating and deallocating ) memory throughout the level.

Honestly, unless you start seeing framerates drop I wouldn't worry about it.
Sweet.
I'll get to designing the level then, which is harder than I expected :D

Re: Noob learns to code in 3 months

Posted: March 9th, 2017, 11:20 pm
by Yumtard
Man this is hard :D

Almost feels like whatever level I'll be able to make will be worse than the rng level lol.
Oh well gonna spend max 2-3 days on this and just try to make sure the level isn't completely horrible.

Re: Noob learns to code in 3 months

Posted: March 10th, 2017, 4:26 am
by albinopapa
Well, perhaps randomly generate levels and have each level be a different seed. Write out the level and make modifications if needed. A mix between random and creative.

Re: Noob learns to code in 3 months

Posted: March 11th, 2017, 5:21 pm
by Yumtard
Added boss at the end of the level. Had a few different ideas how to do this, ended up with setting the boss y pos in level.cpp along with all other entities and updating boss position the same way as I do with all things. When boss reaches the screen his state changes to entrancestate which also changes the game state to boss state.

Also fixed a couple bugs, made it so you can have a shield vs the boss (wasn't drawing/updating shield or even checking for collisions with shield in boss state)

Also fixed a bug with black holes. if you start getting sucked into a bluck hole but then got pushed by an obstacle than it kinda fucked everything up, so I'm no longer checking for collisions with obstacles if the ship is in transition state.

gonna do some more work on the level and think it'll be more or less done for testing tonight.

@Chili
If you could please show me how to change the graphics to use sysbuffer it'd highly appreciated as I've tried to get alpha working for a total of prob 20 hours and only managed to f everything up :D
It's also pretty much the last thing left in dev
albinopapa wrote:Well, perhaps randomly generate levels and have each level be a different seed. Write out the level and make modifications if needed. A mix between random and creative.
Nah I think it's alright :) I'll just ake it somewhat random on my own and change stuff that seems too hard/easy etc

Re: Noob learns to code in 3 months

Posted: March 11th, 2017, 6:05 pm
by Zedtho
Do you have a Github where you put the code? Although, I think you said you were going to hand this in somewhere, so you don't want it to be on the internet for people to use...
Anyways, from what I've heard, this looks awesome!
Also, to your entities always existing, remember the PooGame by Chili? Well, although I put in like 10'000 poos (which didn't get deconstructed after being eaten) my game didn't lag at all, so I think you're safe.
On the other hand, I'm using an i7-6700k, so mileage may vary.

Re: Noob learns to code in 3 months

Posted: March 11th, 2017, 6:14 pm
by Yumtard
Zedtho wrote:Do you have a Github where you put the code? Although, I think you said you were going to hand this in somewhere, so you don't want it to be on the internet for people to use...
Anyways, from what I've heard, this looks awesome!
Also, to your entities always existing, remember the PooGame by Chili? Well, although I put in like 10'000 poos (which didn't get deconstructed after being eaten) my game didn't lag at all, so I think you're safe.
On the other hand, I'm using an i7-6700k, so mileage may vary.
https://github.com/Yumtard/Spaceballs

Here's the repo if you wanna take a look at the code or try it out :)
It's my first game and the plan is to put it in a portfolio which I need to send to a school I'm gonna apply for.

edit: the level is obv incomplete as you will notice

Re: Noob learns to code in 3 months

Posted: March 11th, 2017, 10:48 pm
by Yumtard
Added comets
fixed a couple bugs
neater start pos for ship

think I'm basically done :O

Re: Noob learns to code in 3 months

Posted: March 14th, 2017, 3:46 pm
by Yumtard
It's mentally tough for me putting this game on ice and start another project before this one is 100% complete. So I end up spending a lot of time starring at the screen feeling like I should be doing something when there's really not much left to do :p
I think alpha is pretty much the last piece unless I find some small tweaks, and it seems like I'll have to revisit the alpha blending later when I have more tools in my belt.

So Now I'm gonna force myself not to work on spaceballs for a while (unless I get some new input in my other thread for stuff to improve) instead I'm gonna pick up the tutorials again, starting episode 23 tonight. Spend a couple days finishing the beginner series and then start trying to learn SFML.

Re: Noob learns to code in 3 months

Posted: March 14th, 2017, 10:18 pm
by Yumtard
Watched 23.1 without pausing etc to get the basic idea of it. Plan for tomorrow is to watch 23.2 during the morning coffee and then later in the day to rewatch both part in a little more detail and hopefully if I have time start working on trying to make the game on my own.