Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

AppGameKit Classic Chat / 2D Pinball WIP (Concave collision) [Source]

Author
Message
ando
4
Years of Service
User Offline
Joined: 21st Feb 2020
Location: Australia
Posted: 10th Mar 2022 20:30 Edited at: 25th Oct 2022 10:18
My first attempt at 2D pinball, early WIP.
I started out trying to make something else 2D for my android phone but got side tracked with concave collision.
After testing on my phone I see it works really good. Phone is an old galaxy J3 (2016).
After I get all the game mechanics done then I'll try to make it look pretty.

I added a lot of comments in the code for anyone that may be interested.
BASIC appeared in May 1964. Lightning flashed, the wind roared and the Earth moved.
And nine months later I was born.
So here I am.
I am Basic.
Code is in my genes.

Attachments

Login to view attachments
Virtual Nomad
Moderator
18
Years of Service
User Offline
Joined: 14th Dec 2005
Location: SF Bay Area, USA
Posted: 12th Mar 2022 00:51
gave it a quick run and it plays solid. no tunneling noticed (which i obviously expected) and everything felt good.

thanks for sharing, ando. now, make it purdy
ando
4
Years of Service
User Offline
Joined: 21st Feb 2020
Location: Australia
Posted: 12th Mar 2022 11:33
Cheers Virtual Nomad and thanks for the feedback.
And yes, when the time comes, I'll put a lot of effort in to the purdy stuff.
BASIC appeared in May 1964. Lightning flashed, the wind roared and the Earth moved.
And nine months later I was born.
So here I am.
I am Basic.
Code is in my genes.
Barry Pythagoras
10
Years of Service
User Offline
Joined: 14th Mar 2014
Location:
Posted: 27th Mar 2022 12:28
It's great I like it! I always wanted to make a Pinball Game!

It just needs the graphics!
blink0k
Moderator
11
Years of Service
User Offline
Joined: 22nd Feb 2013
Location: the land of oz
Posted: 1st Oct 2022 21:25
This is excellent! Well done
ando
4
Years of Service
User Offline
Joined: 21st Feb 2020
Location: Australia
Posted: 25th Oct 2022 10:39
Cheers guys.
The latest version you can download from my first post.
I added extra ball and multiball.
If you have 5x multiplier, every time you get the BONUS letters again will keep the multiball alive.
If that's too hard then just tap key B (for testing).

I made test version 3 earlier in the year but had to stop for a while to get surgery to remove an ulser (a gastrojejunostomy).
Feeling much better now that I can eat and drink again. LOL.
Looking forward to getting in to coding again.

Sharing the code for anyone that wants to make a pinball game. There might be one or two things in there that can help.
BASIC appeared in May 1964. Lightning flashed, the wind roared and the Earth moved.
And nine months later I was born.
So here I am.
I am Basic.
Code is in my genes.
ando
4
Years of Service
User Offline
Joined: 21st Feb 2020
Location: Australia
Posted: 25th Oct 2022 11:14 Edited at: 25th Oct 2022 11:14
Here is a little program I was playing with to test concave collision ideas and got me started on pinball.
BASIC appeared in May 1964. Lightning flashed, the wind roared and the Earth moved.
And nine months later I was born.
So here I am.
I am Basic.
Code is in my genes.

Attachments

Login to view attachments
Virtual Nomad
Moderator
18
Years of Service
User Offline
Joined: 14th Dec 2005
Location: SF Bay Area, USA
Posted: 25th Oct 2022 21:57
nice update, ando. and, glad you're feeling better.

it's still playing smoothly and the graphics/sounds helps pull it all together.

i've skimmed the code and see room for optimization that i hope to take a stab at some day. for now, it's all solid and appreciated!

thanks again

blink0k
Moderator
11
Years of Service
User Offline
Joined: 22nd Feb 2013
Location: the land of oz
Posted: 3rd Nov 2022 18:56
Quote: "Here is a little program I was playing with to test concave collision ideas and got me started on pinball."

Exceptional work!! Writing a table editor for this is on my 5 year plan, as well as some graphics.
ando
4
Years of Service
User Offline
Joined: 21st Feb 2020
Location: Australia
Posted: 3rd Nov 2022 20:57
Thanks for the feedback guys.
With the little test program, I was thinking of making a simple game for mobile devices where the player would
place some objects like ramps and bouncers that would apply a force to the ball, avoid some obstacles and
with one shot get the ball to some kind of target.

With a built in level editor, it would be quicker to make all the levels and then save them to a folder.
BASIC appeared in May 1964. Lightning flashed, the wind roared and the Earth moved.
And nine months later I was born.
So here I am.
I am Basic.
Code is in my genes.
Phaelax
DBPro Master
21
Years of Service
User Offline
Joined: 16th Apr 2003
Location: Metropia
Posted: 14th Nov 2022 18:46
Worked pretty well for me. Looking at the help I think you probably went about this the same way I would've, a bunch of line intersection tests. The ball moved very fast though, some times it shot back down the entry so fast it propelled itself back out of it like a rocket.
Tiled TMX Importer V.2
XML Parser V.2
Base64 Encoder/Decoder
Purple Token - Free online hi-score database
Legend of Zelda
Pixel-Perfect Collision

"I like offending people, because I think people who get offended should be offended." - Linus Torvalds

fubarpk
Retired Moderator
19
Years of Service
User Offline
Joined: 11th Jan 2005
Playing: AGK is my friend
Posted: 23rd Nov 2022 12:33
Fantastic 'ando' plays really well, allot better and more complete than the pinball attempt I had for android
would love to see this go further, perhaps with your pinball design and attributes it mightn't be too hard at
a later stage to also make a pinball construction set. The reason I say this allot of the time, all the construction
work that goes into a program like 'Aquarius pinbal' a construction set is often half designed in the process.
PK
Arch-Ok
AGK Developer
4
Years of Service
User Offline
Joined: 11th Jul 2019
Location: Bursa/TÜRKIYE
Posted: 24th Nov 2022 17:18
Nice work @ando, it looks so promising. Couldn't get that "b"o"n"u"s" yet.
Steve Ancell
18
Years of Service
User Offline
Joined: 16th Feb 2006
Location: Brighton, East Sussex, UK
Posted: 24th Nov 2022 23:25
@ando

That's one hell of a pinball engine you've got there.
ando
4
Years of Service
User Offline
Joined: 21st Feb 2020
Location: Australia
Posted: 26th Nov 2022 07:10
Hey, thanks to all of you for giving it a spin.

@fubarpk, I like the idea of a construction set. I wonder if a modular tile set would be the easy way to go???
BASIC appeared in May 1964. Lightning flashed, the wind roared and the Earth moved.
And nine months later I was born.
So here I am.
I am Basic.
Code is in my genes.

Login to post a reply

Server time is: 2024-04-24 07:51:01
Your offset time is: 2024-04-24 07:51:01