October 21, 2020, 07:49:15 am


Alternatively, join us on Discord.
You can help CodeWalrus stay online by donating here.

[CSE Basic] Flatforme

Started by 123outerme, January 09, 2015, 11:52:46 pm

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

DJ Omnimaga

I didn't check the code, but is the jumping code located outside the main loop? When I create a walking engine, I try to make it so that everything that isn't walking around is processed outside the main loop. If it checks for collision and it's not an empty spot then it exits the walking loop, same if I press the jump key. Once the jumping and collision is calculated, I go back to the main loop. It requires an extra variable but the speed gain can be worth it.

123outerme

Quote from: DJ Omnimaga on January 22, 2015, 11:53:59 pm
I didn't check the code, but is the jumping code located outside the main loop? When I create a walking engine, I try to make it so that everything that isn't walking around is processed outside the main loop. If it checks for collision and it's not an empty spot then it exits the walking loop, same if I press the jump key. Once the jumping and collision is calculated, I go back to the main loop. It requires an extra variable but the speed gain can be worth it.

I've done that sometimes before, but I only deem it necessary if the speed is atrocious. That being said, I believe my version's speed is near that level, so I'll try that.

Streetwalrus

Looks pretty cool so far. :) I don't have a CSE unfortunately so I won't be able to play it. :/

123outerme

Quote from: Streetwalrus on January 23, 2015, 06:59:17 am
Looks pretty cool so far. :) I don't have a CSE unfortunately so I won't be able to play it. :/

Thanks! Maybe you'll get the CE when it comes out (and hopefully the code won't have to be ported too much)
In other news, I moved the jumping and sword swinging code to outside of the loop, and the speed is tolerable. I'm releasing a beta soon.

DJ Omnimaga


123outerme

Quote from: DJ Omnimaga on January 24, 2015, 07:13:54 pm
Awesome to hear :D

The demo is released! I'm also now working on a level editor. It can create levels, but not load them yet.

LD Studios

Looking good, here's a few tips on level design:
-Having multiple platforms will increase difficulty as well as level diversity
-Make them longer by spawning the player on the far left and putting the target closer to the far right
-Put enemies between the spawning point and the target, right now it's too easy to avoid them entirely
-Having multiple enemies in one level would also be nice



123outerme

January 24, 2015, 10:41:30 pm #37 Last Edit: January 26, 2015, 11:14:29 pm by 123outerme
Quote from: LD Studios on January 24, 2015, 09:34:31 pm
Looking good, here's a few tips on level design:
-Having multiple platforms will increase difficulty as well as level diversity
-Make them longer by spawning the player on the far left and putting the target closer to the far right
-Put enemies between the spawning point and the target, right now it's too easy to avoid them entirely
-Having multiple enemies in one level would also be nice

Thanks! I will see if these can be done. One of the reasons that I was avoiding this [the first one] is because of speed issues. Also, I think that two platforms are unnecessary, as there's only one layer where you can't get to from the ground. Although, scrolling levels might be an option (although, smooth scrolling is out of the question by far).

123outerme

January 25, 2015, 03:33:59 pm #38 Last Edit: January 26, 2015, 01:53:20 am by 123outerme
Got the level editor to work! You can create a level, which it then stores into LFFCUS, and then you can play it in the new "Add" menu! A new beta coming soon, with this feature. All I have to do is test, and I'll probably design a few more levels for the main game. I can use this to make levels as well, but I'll have to manually import them.

Edit: Added the new beta to the first post!

DJ Omnimaga

January 26, 2015, 09:13:56 pm #39 Last Edit: January 27, 2015, 03:32:47 am by DJ Omnimaga
Awesome, I'll install this on my calc soon :D

EDIT I finally tried the new version. At first I think it failed to send because when I tried it it looked identical to the old one, but then I tried sending it again and it was the new version.

My suggestions:
-Make the character start to the complete left all the time, with enemies spawning from the right when you are located in the left half of the screen, but make them spawn from the left like they do when you are on the other side of the screen. You could make enemies start in the middle too when the level is loaded. It would add extra challenge without being annoying.

-Make the vertical platforms drawn using vertical lines rather than horizontal so that they draw faster.

-add holes in the floor (not in every level, but it would add extra challenge)

123outerme

January 27, 2015, 04:48:40 pm #40 Last Edit: January 27, 2015, 05:01:25 pm by 123outerme
Quote from: DJ Omnimaga on January 26, 2015, 09:13:56 pm
Awesome, I'll install this on my calc soon :D

EDIT I finally tried the new version. At first I think it failed to send because when I tried it it looked identical to the old one, but then I tried sending it again and it was the new version.

My suggestions:
-Make the character start to the complete left all the time, with enemies spawning from the right when you are located in the left half of the screen, but make them spawn from the left like they do when you are on the other side of the screen. You could make enemies start in the middle too when the level is loaded. It would add extra challenge without being annoying.

-Make the vertical platforms drawn using vertical lines rather than horizontal so that they draw faster.

-add holes in the floor (not in every level, but it would add extra challenge)


Thanks for the input! I'll definitely add the first two things. I'll add the third too, but knowing me I'll somehow mess it up ;)
Was the speed okay? I tried to move a few things out of the main loop and connect them with Gotos, but I still have more that I can move, if the speed wasn't good enough.
And as for the level editor, how was that? The platform editor was just temporary, as I'm now working on making it based on your position. (Also, passing through the platform erases it for now, I'll see what I can do)

DJ Omnimaga

Speed seemed fine on my calc, but the enemies should probably move at an higher pixel interval, especially in later levels. Although they would move as fast, if not faster than your character, you can actually stab them so you could easily get through them anyway. You should move more stuff out of the main loop, though (if possible, everything that isn't movement), because then speed might get even greater. However, I would advise against using Goto for such game. Instead, take an extra variable then store a value in it when exiting loops rather than using a Goto. Then replace labels with If Variable = That value:Then:<code>:End. Otherwise, Goto search from the very beginning to the end of the game code to find the appropriate label and it slow things down a lot (for large programs it can take as much as 1 second to find the Lbl if it's at the end of the code)

I didn't have time to try the level editor, though.

princetonlion.tibd

I tried this. I like the jumping animation.

I think moving in mid-air is a bit hard. The main menu is cool though :)
Anyway war sucks. Just bring us your food instead of missiles  :P ~ DJ Omnimaga (11.10.2016 20:21:48)

123outerme

Quote from: DJ Omnimaga on January 28, 2015, 03:03:12 am
Speed seemed fine on my calc, but the enemies should probably move at an higher pixel interval, especially in later levels. Although they would move as fast, if not faster than your character, you can actually stab them so you could easily get through them anyway. You should move more stuff out of the main loop, though (if possible, everything that isn't movement), because then speed might get even greater. However, I would advise against using Goto for such game. Instead, take an extra variable then store a value in it when exiting loops rather than using a Goto. Then replace labels with If Variable = That value:Then:<code>:End. Otherwise, Goto search from the very beginning to the end of the game code to find the appropriate label and it slow things down a lot (for large programs it can take as much as 1 second to find the Lbl if it's at the end of the code)

I didn't have time to try the level editor, though.

Thanks for the tip! And to get back to the main loop, do I use a Goto?


Quote from: princetonlion.tibd on January 31, 2015, 05:54:36 pm
I tried this. I like the jumping animation.

I think moving in mid-air is a bit hard. The main menu is cool though :)

Thanks! Are you talking about jumping up in a direction, or when "floating" down?

princetonlion.tibd

Jumping up, when it changes to a lowercase o for a few seconds and then jumps
Anyway war sucks. Just bring us your food instead of missiles  :P ~ DJ Omnimaga (11.10.2016 20:21:48)

Powered by EzPortal