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 / Carnival Game

Author
Message
fubarpk
Retired Moderator
19
Years of Service
User Offline
Joined: 11th Jan 2005
Playing: AGK is my friend
Posted: 24th Oct 2018 00:18 Edited at: 24th Oct 2018 02:19
Ok so I got the torus object working for the hoop toss

Video removed for space please see further down for a later one

With the following code
fubar
blink0k
Moderator
11
Years of Service
User Offline
Joined: 22nd Feb 2013
Location: the land of oz
Posted: 24th Oct 2018 00:23
Nice work! 2 for 2. You've been practicing
fubarpk
Retired Moderator
19
Years of Service
User Offline
Joined: 11th Jan 2005
Playing: AGK is my friend
Posted: 24th Oct 2018 00:27 Edited at: 24th Oct 2018 16:39
Thanks I should've won the big teddy bear lol

It still very much needs work but think the hardest part sorted with the compound shapes

Added a hand model

video removed for space please see later post

I think using the getdistance vector command I can determine if a hoop is over a bottle all stuff to do
will have to add a back face to the hand model yet all in good time
fubar
fubarpk
Retired Moderator
19
Years of Service
User Offline
Joined: 11th Jan 2005
Playing: AGK is my friend
Posted: 24th Oct 2018 05:32 Edited at: 24th Oct 2018 16:39
been playing with toilet toss too and that's working now


video removed for space please see later post


but ofcourse needs work
fubar
fubarpk
Retired Moderator
19
Years of Service
User Offline
Joined: 11th Jan 2005
Playing: AGK is my friend
Posted: 24th Oct 2018 05:44 Edited at: 24th Oct 2018 05:50
All the minigames need allot of work and hooptoss and toiletToss will eventually get different images so as its like a new booth
but its kinda nice going from one to the other while I contemplate how to go about doing other stuff im not sure how yet lol
fubar
fubarpk
Retired Moderator
19
Years of Service
User Offline
Joined: 11th Jan 2005
Playing: AGK is my friend
Posted: 24th Oct 2018 08:59 Edited at: 2nd Nov 2018 07:26
ok made some color changes for now

Videos removed for space please see further down

and did some organisation of code now each minigame has its own folder inside the media folder

All suggestions welcome
fubar
fubarpk
Retired Moderator
19
Years of Service
User Offline
Joined: 11th Jan 2005
Playing: AGK is my friend
Posted: 24th Oct 2018 16:53 Edited at: 2nd Nov 2018 07:25
Really need to create a better group of compound shapes for the hoop
its a pity you cant AddObjectShapeObject(objectId) to the compound shapes command
because that would make life so much easier

Using AddObjectShapeSphere( objID, positionVec3, diameter ) for the torus object works much better with the physics
You can see it works much better in this video
Video removed for space please see further down

The below code shows the new objectshape added the old commands commented out



The other method I could've used is to have the hoop only used as a visibility and positioning object with no collisions set
Then I could have several different invisible objects with collisions on fixed to the hoop . This would make placement allot easier
as you could position the objects in a program such as blender so as when you load them you don't need to position them just
use the fix object command and fix them all to the hoop using my above example
fubar
fubarpk
Retired Moderator
19
Years of Service
User Offline
Joined: 11th Jan 2005
Playing: AGK is my friend
Posted: 29th Oct 2018 00:18
Some updates to come but my internet and phone cables all in the process of being changed over
hopefully will be back up and running in a couple of days using the libraries computers atm.
fubar
GarBenjamin
AGK Developer
7
Years of Service
User Offline
Joined: 30th Nov 2016
Location: USA
fubarpk
Retired Moderator
19
Years of Service
User Offline
Joined: 11th Jan 2005
Playing: AGK is my friend
Posted: 31st Oct 2018 02:52 Edited at: 2nd Nov 2018 07:25
It may be Garbenjamin

Altho I did purchase the VR plug in I cant test anything with VR yet

This shows the four carnival games


Video removed for space please see further down


One thing I have learned if your really skilled you can knock down 2 ducks with one shot
fubar
GarBenjamin
AGK Developer
7
Years of Service
User Offline
Joined: 30th Nov 2016
Location: USA
Posted: 31st Oct 2018 05:34
fubarpk
Retired Moderator
19
Years of Service
User Offline
Joined: 11th Jan 2005
Playing: AGK is my friend
Posted: 31st Oct 2018 06:37
Thanks it was one of the simpler additions but I agree it does work well
fubar
fubarpk
Retired Moderator
19
Years of Service
User Offline
Joined: 11th Jan 2005
Playing: AGK is my friend
Posted: 31st Oct 2018 21:33
Whats a carnival without prizes? (admit it you used to play the carnival games just for the prizes)

So im thinking of some kind of prize awarded depending on the players score which will most probably just be a picture
that they store in there inventory of items won. Perhaps when you have the four top prizes your awarded a golden pass

Perhaps start the players off with so many coins(maybe 500) with each carnival event costing so much(maybe120) if you
win the top prize of an event your awarded 120 coins plus the top prize. Once you have 4 top prizes one from each event
you get the golden pass which allows you to play any game again for free.

Just a thought adding monies into a game is kinda new for me so im asking what people think.
trying to use it for longer lasting appeal. Perhaps a pass to each event can be awarded for the top prize in each event. which
would only allow them to play that game unlimeted times without coins.

SUGGESTIONS ?

fubar
fubarpk
Retired Moderator
19
Years of Service
User Offline
Joined: 11th Jan 2005
Playing: AGK is my friend
Posted: 1st Nov 2018 12:49 Edited at: 13th Nov 2018 21:16
Ok so we have some improvements The pointlights get removed after duckshoot has been played atm
which does make the others look a little dark but it shows progress

EDIT VIDEO removed for space

Thanks for the help and input ive been getting from blink
fubar
puzzler2018
User Banned
Posted: 1st Nov 2018 13:24
Wow Fubarpk - some impressive work here - well done and greatly achieved. Awesome.
GarBenjamin
AGK Developer
7
Years of Service
User Offline
Joined: 30th Nov 2016
Location: USA
Posted: 1st Nov 2018 19:37
You're really polishing this up. The duck shoot & bowing look excellent! I keep thinking that last game toilet toss (which first time I thought we'd be actually tossing toilets) would be better play wise if the view was angled like camera up looking down a bit because it seems like the slingshot type weapon has to block view of target currently. Just an idea.

Overall very nice work and definitely making excellent progress!
fubarpk
Retired Moderator
19
Years of Service
User Offline
Joined: 11th Jan 2005
Playing: AGK is my friend
Posted: 1st Nov 2018 19:49 Edited at: 1st Nov 2018 19:53
Thanks Puzzler and Gar

not long finished the 3D score board
Still need to figure out how to get the duckshoot using the gyro as it uses mouse and calculates vectors from that
Think bowling is very close that uses the gyro and has a button you can hold down so you can rotate which works quite nicely in Android

Hooptoss and toilettoss lots to do there yet. Especialy with scene placement currently both hooptoss and toilettoss do it manualy and the
toilet, table and floor all probably need to go down slightly. I purchased the slingshot model but not sure it is the right model to use just
wanted something a bit different from the cannon and a hand. I think if the toilet was lower to the floor it might work better.
fubar
fubarpk
Retired Moderator
19
Years of Service
User Offline
Joined: 11th Jan 2005
Playing: AGK is my friend
Posted: 1st Nov 2018 22:13 Edited at: 1st Nov 2018 22:14
I now have things working with a sort of emulated gyroscopic mouse

done similar to this which sets it to a 45 degree angle starting position (upright)


so now duckshoot, hooptoss and toilettoss all have a mouse equivalent in Android
This means all the vectors that are calculated from the current getscreenvector commands work in android and show aiming etc
fubar
blink0k
Moderator
11
Years of Service
User Offline
Joined: 22nd Feb 2013
Location: the land of oz
Posted: 1st Nov 2018 22:18
I wonder if it was a countdown rather than a tap to shoot? So it would go 3, 2, 1 and then shoot. I think it might add a bit of tension and avoid upsetting the gyroscope when you press the fire button
Might be interesting to try
puzzler2018
User Banned
Posted: 1st Nov 2018 22:31
Yeah - sounds good.. a 3D

3
2
1
GO!

a 3D primative object for fonts with an outer skin of a gray color and the inner part of it been a bright color like red. gives some niciety to 3D fonts once again.

Interesting but not something to work on at this minute
fubarpk
Retired Moderator
19
Years of Service
User Offline
Joined: 11th Jan 2005
Playing: AGK is my friend
Posted: 1st Nov 2018 22:33 Edited at: 1st Nov 2018 23:33
That may be an idea

ATM it flickers a little with the gyro I think its the math im using I believe trunc() or ceil()
may fix that


Oh ofcourse Floor because I don't need a float for screen
fubar
fubarpk
Retired Moderator
19
Years of Service
User Offline
Joined: 11th Jan 2005
Playing: AGK is my friend
Posted: 2nd Nov 2018 07:23 Edited at: 13th Nov 2018 21:17
Added costing for the games not sure what each will cost yet and all you get is a totalscore
and fixed the 3D scoreboard
EDIT VIDEO removed for space
fubar
Virtual Nomad
Moderator
18
Years of Service
User Offline
Joined: 14th Dec 2005
Location: SF Bay Area, USA
Posted: 2nd Nov 2018 21:43
looking better and better, fubarpk. nice work!

i think it's time to share an online "Chiptone Generator" that i recently discovered, in case you're ready for some SFX/Music
blink0k
Moderator
11
Years of Service
User Offline
Joined: 22nd Feb 2013
Location: the land of oz
Posted: 5th Nov 2018 00:50
Saw this by @VirtualNamad and thought of dodg'em cars
I wonder if Mr Nomad would let you in on how he did it?
fubarpk
Retired Moderator
19
Years of Service
User Offline
Joined: 11th Jan 2005
Playing: AGK is my friend
Posted: 5th Nov 2018 01:15 Edited at: 5th Nov 2018 17:12
That's a good idea and I believe there is dodgem car models at the TGC assets store

The main issue is each car would have to be dynamic for the physics to work and would have to delete its physics object
after each new movement. Unless its movement was based on using the SetObject3DPhysicsLinearVelocity( objID, dirX, dirY, dirZ, initialSpeed )
commands and perhaps to get the angle GetObject3DPhysicsAngularVelocityZ( objID ). will have to have a play and see what I can come up with
fubar
fubarpk
Retired Moderator
19
Years of Service
User Offline
Joined: 11th Jan 2005
Playing: AGK is my friend
Posted: 5th Nov 2018 18:30 Edited at: 5th Nov 2018 19:06
@blinkok
I think with work dodgem cars can be done like this


Calculating the angle vector needs allot of work but it demonstrates one red bumper car moving around by itself
bouncing off the walls setting direction and angular vectors


add a second car increase the height of walls and increase the velocity and you get something like this



but I think with a car with a rounded front end it would work better with the physics and not get stuck in the corners
the main reason I cranked the velocity

and I think getting/setting the angular velocity separate from velocity might work better.

Anyone watching this thread that's achieved this using a better method?

HAHAHA This project proving to be quite a large thing to complete lol There is just so many games that can be added
maybe if Dodgem cars eventuates it could be a bonus game
fubar
fubarpk
Retired Moderator
19
Years of Service
User Offline
Joined: 11th Jan 2005
Playing: AGK is my friend
Posted: 5th Nov 2018 19:55
and if I use character controllers for the cars and the rotatecharactercontroller command that stops the movecharactercontroller from working
so in effect the car can either rotate or move not sure whats wrong here

fubar
blink0k
Moderator
11
Years of Service
User Offline
Joined: 22nd Feb 2013
Location: the land of oz
Posted: 5th Nov 2018 20:53
It's getting there
fubarpk
Retired Moderator
19
Years of Service
User Offline
Joined: 11th Jan 2005
Playing: AGK is my friend
Posted: 5th Nov 2018 22:00
Thanks blinkok
fubar
Virtual Nomad
Moderator
18
Years of Service
User Offline
Joined: 14th Dec 2005
Location: SF Bay Area, USA
Posted: 6th Nov 2018 06:37 Edited at: 6th Nov 2018 06:45
the Friday 4x project is simply a heavily smoothed 128x128 heightmap scaled up with:
.

the trucks:


arrowkey controls:


applied to X# & Z# (pulled from the SIN/COS of its Y-Angle), with:


(i'm keeping SPEED# and TURN# rates constant right now)

throwing the handful of commands in was easy but the "week's work" was playing with damping, restitution, friction to get it to "feel" right.

and, trust me, i've got hacks in there to maintain "control". ie, if it tilts too much in any direction or is beyond a threshold above the heightmap, i shut the velocities off.

anyway, definitely hoped bumper cars would be discussed here where every carnival should have 'em

PS: the first lesson learned when i started experimenting was to definitely keep the trucks > 40 units in all directions to avoid tunneling (the dae model/"box" is 48x48x96 i believe)
fubarpk
Retired Moderator
19
Years of Service
User Offline
Joined: 11th Jan 2005
Playing: AGK is my friend
Posted: 6th Nov 2018 11:56 Edited at: 6th Nov 2018 11:57
Thanks for that Nomad
Quote: ""week's work" was playing with damping, restitution, friction to get it to "feel" right."

Yes I know that too well

I bumped the scale up as you suggested and threw in some of your declarations the cars are now cylinders as im finding that works best until i use a model
fubar
fubarpk
Retired Moderator
19
Years of Service
User Offline
Joined: 11th Jan 2005
Playing: AGK is my friend
Posted: 6th Nov 2018 20:38 Edited at: 29th Nov 2018 20:15
Ok I decided it needed some kind of model
Edit Video removed for space please see the latest one further on
Code isn't much different than above except it uses the model
"not so sure why I have trouble sometimes with the objects sitting too high above ground and
other times its fine I thought it was the pivot of the model and it still may be but It doesn't seem
to matter where I place the pivot point in blender atm I centred it" but not sure why it is sitting
so high above ground level/ Have a similar issue with hooptoss setting it up
fubar
Virtual Nomad
Moderator
18
Years of Service
User Offline
Joined: 14th Dec 2005
Location: SF Bay Area, USA
Posted: 6th Nov 2018 22:32
fubar, since we can't directly alter centers of mass, i think the cylinder collision shapes are tilting/flipping over (which we can't see since we have no debug mode). they are very prone to do so, as are (probably more-appropriate) capsule collision shapes.

i get similar with box shapes in the 4x project so i run aforementioned "checks" to monitor tilts, shutting off velocities if they are leaning too much in any direction which, then, allows the physics system to (sort of) "right" themselves.

you're also maintaining "too much" friction on all objects where they are "gripping" everything they touch and pulling themselves into (and underneath) whatever they strike.

as mentioned, its a chore finding "just right" settings, but i'm sure there is a sweet spot.

fubarpk
Retired Moderator
19
Years of Service
User Offline
Joined: 11th Jan 2005
Playing: AGK is my friend
Posted: 6th Nov 2018 23:45 Edited at: 29th Nov 2018 20:15
Thanks for the help and advice nomad

That wasy with box collision shapes its strange how dynamic objects behaves sometimes and this is cylinder

not sure I understand why cylinder shapes and capsules need an axis but il try that next
I may have to create my own object collision shapes and attach them to the car and set them as the collision shape
or use the SetObjectShapeCompound(objId) like in hooptoss and toiletthrow still playing with concepts to see which
works best

Edit Video removed for space please see the latest one further on
fubar
blink0k
Moderator
11
Years of Service
User Offline
Joined: 22nd Feb 2013
Location: the land of oz
Posted: 7th Nov 2018 05:13 Edited at: 7th Nov 2018 05:14
Quote: "not sure I understand why cylinder shapes and capsules need an axis but il try that next"

It's to tell AppGameKit how the shape is oriented on the model.

For example; The wheels on a car would have an axis of z (If it was facing left or right). Where as a silo would have an axis of y

I'm hella busy right now with other stuff (including my pc crashing...again!) but when i get a chance i have some car models that i could turn into bumper cars (so you don't need any ghosts lol)
fubarpk
Retired Moderator
19
Years of Service
User Offline
Joined: 11th Jan 2005
Playing: AGK is my friend
Posted: 7th Nov 2018 06:15 Edited at: 7th Nov 2018 13:14
Thanks Blink

My understanding is x is horizontal y is verticle and z depth axis but there is so many times when this is not true
I get confused with this sometimes. youd think by now with my 3D play I have had with AppGameKit and other TGC products
in the past ide have some rule that makes more sence out of x,y,z. All I know is my x left me for z and I don't know y hahahah

hahahha I kinda like the ghost idea anyway could be the "haunted bumper cars"
Still have to improve the movements lots will prob have to make allowances for cars being blocked in etc
wanted to get the collisions working as they should first, think il have to use SetObjectShapeCompound(objId)
which is kinda a pain to set up but all in time as I kinda need a rounded front but flat sides.
I tried convex hull but the cars tip over as soon as they try to move
fubar
blink0k
Moderator
11
Years of Service
User Offline
Joined: 22nd Feb 2013
Location: the land of oz
Posted: 7th Nov 2018 08:12
I think there might be an issue (or something i don't understand about convex hulls).
Have a look at this. If you shoot outside the square it still collides.
fubarpk
Retired Moderator
19
Years of Service
User Offline
Joined: 11th Jan 2005
Playing: AGK is my friend
Posted: 7th Nov 2018 12:32 Edited at: 7th Nov 2018 12:54
That's strange it collides to the right with the static plain
but if you convert the plain to a box it works. There ,may
be some kind of rule not to use convex hulls with plains
but I would expect that to work aswell


Maybe to use convex hull the object itself has to be convex
but I have no idea why a plain dont work


Changing the position of the gun and the
camera still has same problem. I was wondering if its convex
calculations worked best on a particular axis as I tried
RotateObjectLocalX and RotateObjectLocalY and it behaved a
little better but there was still a problem
fubar
fubarpk
Retired Moderator
19
Years of Service
User Offline
Joined: 11th Jan 2005
Playing: AGK is my friend
Posted: 8th Nov 2018 05:03 Edited at: 13th Nov 2018 21:17
I did some work on hooptoss and toilettoss

Heres what there is so far
EDIT VIDEO removed for space

The button in the left corner is a hold to aim button on android shift in windows
The aiming is controlled with the gyroscope and takes advantage of using a virtual mouse
Which is using a calculation from the gyros position to provide a virtual mouse movement

you will notice both hooptoss and toilet toss gets the same scene, I just need to make some snazzy graphics for
those yet but wanted to set the scenes up the same size etc for now

Haunted Dodgemcars may be a bonus game for completion of all levels or for getting a certain score not sure
yet

There is a problem as you can see in hoop toss the hoops may stick to the wall that's got to do with the way I do
the collisions il rectify that sometime
fubar
Kevin Cross
21
Years of Service
User Offline
Joined: 15th Nov 2003
Location: London, UK
Posted: 8th Nov 2018 09:36
Looking good @fubarpk.

Couldn't help notice with the bottle and toilet game that once you got it once you could leave the pointer in the same place and throw all of your remaining shots and continue scoring. You may want to move something, maybe the pointer slightly/drastically after each throw to make it a little harder. The toilet one you could move around after each shot, but couldn't really do that with bottles, unless you went for the game where the things float around in a water ring and you have to throw the hoops on the moving targets.
fubarpk
Retired Moderator
19
Years of Service
User Offline
Joined: 11th Jan 2005
Playing: AGK is my friend
Posted: 8th Nov 2018 09:55
Thanks Kevin Cross

Its much harder with android as its the gyroscope but easier in windows yes
fubar
puzzler2018
User Banned
Posted: 8th Nov 2018 22:12 Edited at: 8th Nov 2018 22:13
NIcely done. great

I used to love the Waltzers.... just need 3d triangulated objects with a thickness with a motion that goes round and round a pivot point in a sine/cos wave motion, all the thick trinagualted objects joined together in a circle fashion.


That would be awesome to see in gaming world
fubarpk
Retired Moderator
19
Years of Service
User Offline
Joined: 11th Jan 2005
Playing: AGK is my friend
Posted: 8th Nov 2018 22:32
Thanks puzzler

I think SetObject3DPhysicsAngularVelocity( objID, angX, angY, angZ, initialSpeed ) would work for that
but want to get bumper cars working better before i do something new
fubar
puzzler2018
User Banned
Posted: 8th Nov 2018 22:43
Ok cool

On a waltzer you have tha mian ticket booth in the centre - so so the platforms need to have 4 vectored illongulated squares if you like instead of 3 pointed triangles towards the centre

We cannot escape that centred ticketing booth

Ill have a think and help in some way.
fubarpk
Retired Moderator
19
Years of Service
User Offline
Joined: 11th Jan 2005
Playing: AGK is my friend
Posted: 8th Nov 2018 23:14
Oh just googled it now I see what a waltzer is I was thinking like a spinning board selection
and when you said you have them near the ticket booth i had the idea that it could be a way
of having a random game selector
fubar
puzzler2018
User Banned
Posted: 8th Nov 2018 23:23
all good
puzzler2018
User Banned
Posted: 8th Nov 2018 23:25
fubarpk
Retired Moderator
19
Years of Service
User Offline
Joined: 11th Jan 2005
Playing: AGK is my friend
Posted: 8th Nov 2018 23:33 Edited at: 8th Nov 2018 23:36
thanks not so sure I want rides atm trying to keep the scales of the project down for mobiles still
apart from bumpercars I thought that was kinda classic and still could have a scoring as the bumper
car hits could provide a score or perhaps have a life percentage if I go down the haunted theme
With the percentage theme the textures could change or perhaps show how much life the ghost
car has left. And score is based on the amount of damage done and when a car has complete
damage it nolonger moves. Still toying with that concept tho or perhaps you score without taking a
hit which was the idea of dodgems hahahahahha but who didn't like smashems lol


Or perhaps your total score is used as a timer for dodgems with every hit taking off time so as
the more crashing the less the time you have on them and that would work with the concept of
dodgems not smashems lol
fubar
puzzler2018
User Banned
Posted: 8th Nov 2018 23:34 Edited at: 8th Nov 2018 23:38
Would be nice to "ride it" too.. All good for you carnival app...

Please get into the 3D world and maybe we could be driving that dodgem too.

Whats holding you back on 3D stuff
GarBenjamin
AGK Developer
7
Years of Service
User Offline
Joined: 30th Nov 2016
Location: USA
Posted: 10th Nov 2018 04:07
Wow @fubarpk this is looks fantastic! That new title screen is very well done too. Very colorful just looks very well done and each game looks better & better every time i come here to check the latest updates. Really nice work!

Login to post a reply

Server time is: 2024-11-23 14:33:43
Your offset time is: 2024-11-23 14:33:43