UnderwareDESIGN

PlayBASIC => Show Case => Topic started by: micky4fun on November 26, 2008, 06:57:27 PM

Title: santa's sorta
Post by: micky4fun on November 26, 2008, 06:57:27 PM
hi all

this is my latest game called santa's sorta , it will be hopefull finished in a week or 2 ready for xmas , levels 1 and 2 are 95% complete , just sounds and level linking to be done , this is level 3 the last level in early stages , idea of game is to help santa who is having trouble delivering hes prezzies , he's bag has split and prezzies are falling all over the place so in level 1 you have to collect prezzies falling from hes bag on he's sleigh in the sky, level 2 you have to sort them out into 3 different colours prezzies piles , level 3 you take to the sky as santa and drop prezzies through the chimneys of houses below .

well thats the idea , lets hope i can do a decent job , haha

please look in frogger complete (http://www.underwaredesign.com/forums/index.php?topic=2756.0) thread in show case thread for pic's of levels 1 and 2

back soon
mick :)


(http://www.underwaredesign.com/forums/index.php?action=dlattach;topic=2756.0;attach=2176;image)
Title: Re: santa's sorta
Post by: kevin on November 27, 2008, 05:09:40 AM
 Mick,

    Yep, it looks lovely so far, so if the screen shots are anything to go by, you're doing just fine.

    The forum uses the square  bracket tags.  To link an image into post,   you use the IMG tags {IMG}Http://www.somesite.com/picture.jpg{/img}   -   If you change the {} brackets to the [] brackets the board will parse this into your post.   Same with links {URL}http://www.PlayBasic.com/ {/URL}  or  {URL}http://www.PlayBasic.com/}Link To PlayBasic Site {/URL}
Title: Re: santa's sorta
Post by: BlinkOk on November 27, 2008, 03:22:52 PM
micky  dude. that's lookin fine. very nice job.
i had a santa and sleigh animation hangin around i thought it might look cool to have those reindeer runnin. let me know if it's ok or if you want it smaller or something.

(http://www.underwaredesign.com/screens/PlayBasic/Games/SantaSorta/santa.gif)

santa.gif (http://i93.photobucket.com/albums/l75/blinkok/santa.gif)

sheet-1.png (http://i93.photobucket.com/albums/l75/blinkok/sheet-1.png)
Title: Re: santa's sorta
Post by: micky4fun on November 27, 2008, 06:37:19 PM
hi BlinkOk

Fantastic , yep this looks great , thanks for santa anaimation sheet , its going to put me back a bit putting this sheet into game , but i think is going to be worth it and the santas do look good , im doing level 3 at the moment and for some reason this is taking me ages , took 3 days doing backdrop with houses , 2 days trying to suss out how to release prezzies from santas sleigh while reloading another ready for drop , but i think ive suss it all out tonight , but time for sleep
as im a complete novice at this i do find it hard , sometimes it just dont seem to go into my head what im doing , if you know what i mean.
but i do enjoy doing it .

so i will finish level 3 hopefully in a day or 2 then go back a insert this animation sheet into levels 1 and 2 and see how it looks and see what looks best
i searched the net for a santa animatiom sheet , but had no joy , getting any animation sheet looks hard work , so thanks for posting this one for me and hopefully i will include it im my game

thanks again

mick :)
Title: Re: santa's sorta
Post by: BlinkOk on November 28, 2008, 04:47:15 PM
micky dude,
that sounds great! i did that animation for a xmas e-card. maybe you could use it for a splash screen. i think it would be pretty easy to do because pb has a flash plugin so you could just plugin the flash animation and use i as as.
this is just a suggestion dude. i know you got a lot on your plate and it's your game so it's entirely up to you. i'll understand if you say no ok?

---> LINK TO ANIMATION <--- (http://www.kazoowee.com/design/xmas/santas%20sorta.html)

(http://i93.photobucket.com/albums/l75/blinkok/title.jpg)


Title: Re: santa's sorta
Post by: micky4fun on November 28, 2008, 06:42:23 PM
Hi BlinkOk

oh bugger ,, lol ,,
yes santa sorta splash screen looks good , well fantastic infact , but i have not learned how to use plugins yet , so if its easy then i maybe how to use it , also im running the game at 1024x768 res , will this splash screen run at that res , and ile take it that i can link the play button on the splash screen to the start line in my program ,
maybe you could show the code in PB i need to use

level 3 is 70% complete now , got it going nearly as i wanted it , my novice programming did not let me do it 100% as i wanted ,
but its ok as it is , it still works well in the game

thanks for help , very much appricated
you did this splash screen yourself? ,
mick :)
Title: Re: santa's sorta
Post by: BlinkOk on November 28, 2008, 09:08:58 PM
cool. 1024x768 is no problem. i'll scale things up next week and send you the .swf and .fla.

this is the thread that talks about the flash plugin. i think there's a link to the .dll etc in there as well (http://www.underwaredesign.com/forums/index.php?topic=1147.0)

yeah i did the splash screen and if you need any other screens like win, lose, so you want to quit type screens then just let me know ok?
Title: Re: santa's sorta
Post by: micky4fun on November 29, 2008, 04:55:46 PM
hi BlinkOk

Thats very kind of you . thanks for that , i had a quick look at the flash plug in thread and i think i maybe how to suss it out , well ile give it ago ,
im near completion of level 3 now , so im going to start doing your santa animation , putting into all levels , see if i can do it ok , level 3 has given me loads of headachs , but ive got through it even though ive managed it without knowing whats really happening sometimes , thinking it sould work my way and ends up working another , all revealed once ive finished whole game , maybe Kevin or yourself can tell me why i did'nt work the way i thought it would , when i post full game and code ile point it out ,
you animations are very good , very artistic person , would not have the flare on how to draw like that..

ok better go and get programming again as time goes so so so fast

thanks again
mick :)
Title: Re: santa's sorta
Post by: BlinkOk on November 29, 2008, 05:34:06 PM
sounds cool micky. here's the .swf.
there is a variable in there called gameMode that is set to "gui" when it is showing the gui and then when the user clicks the play button it sets gameMode to "play".
if you are in play mode and you want to bring up the gui then just rewind the flash movie and then play the movie.

[plink]Santas sorta (http://www.kazoowee.com/design/xmas/santas%20sorta.swf)[/plink]

(richt click and "save target as" to save the .swf to your hard drive)

let me know if you want the .fla or anything else

Title: Re: santa's sorta
Post by: kevin on November 29, 2008, 05:49:59 PM

PB classic comes with PBflash binding, but it'll only work in windowed modes.
Title: Re: santa's sorta
Post by: micky4fun on November 30, 2008, 06:03:17 PM
hi all

well ok , im doing my game so far in full screen non window , but it looks fine in window mode as well so thats ok.

BlinkOk thanks for file , ive have downloaded it and tried it out in flash and looks great , will try to put it in my program soon as possible , just done level 3 complete but without sound , including your santa animation . need to add sound and do levels 1 and to with santa animation
here a screenshot of level 3 with yor santa , ile be back as soon as ive done levels 1 and 2 and added sound , could be a few days yet

thanks

ps so i need to host the picture image on a site?
i have just attached it for now
mick :)
Title: Re: santa's sorta
Post by: micky4fun on December 03, 2008, 05:40:03 PM
Hi BlinkOk

game nearly ready now , so i tried to get yoyr flash splash screen going , well got it loading up in my game , but cant suss out how to see if play button has been pressed cant seem to read the string or Integer , i have re-named your file to golf2 to make it easier for me
here is what i have got , can you help me ?
i know im a fool but i am still on a steep learning curve

thanks
mick

EDIT: CODE REMOVED



   


Title: Re: santa's sorta
Post by: BlinkOk on December 04, 2008, 03:50:59 AM
try;
QuoteGetFlashVariable(golf, "_root.gameMode")
i will be away for a couple months but i'm sure kevin can help you out with this stuff. i hear he's pretty good at the playbasic stuff.
Title: Re: santa's sorta
Post by: micky4fun on December 04, 2008, 04:30:30 AM
hi BlinkOk

Thanks , im at work now but will try it later when i get home ,,

many thanks
mick :)
Title: Re: santa's sorta
Post by: Big C. on December 04, 2008, 12:31:45 PM
Quote from: BlinkOk on November 28, 2008, 09:08:58 PM
cool. 1024x768 is no problem. i'll scale things up next week and send you the .swf and .fla.

this is the thread that talks about the flash plugin. i think there's a link to the .dll etc in there as well (http://www.underwaredesign.com/forums/index.php?topic=1147.0)

yeah i did the splash screen and if you need any other screens like win, lose, so you want to quit type screens then just let me know ok?

Hey Mick,

BlinkOK should have send you the sourcefile (.fla)... So you have to proof the sourcefile if there is a variable set for pushing the play-button... this variable do you have to read from the wrapper...


edit:

ups... didn't read
Quote from: BlinkOk on December 04, 2008, 03:50:59 AM
try;
QuoteGetFlashVariable(golf, "_root.gameMode")
i will be away for a couple months but i'm sure kevin can help you out with this stuff. i hear he's pretty good at the playbasic stuff.

sry
Title: Re: santa's sorta
Post by: micky4fun on December 04, 2008, 05:43:12 PM
Hi all

OOH OOH DEAR , ive made a boo boo ,
i started each level seperate to make it easier for me to do , but now im having big problems putting them together , bugger ,, lol
well still learning i suppose , next time if i do more than one level i will do them together ,
so for the time being as im running out of time now before xmas , as i have other things i must do i the next few day upto xmas
here is level one , i will try to link them , if not it will have to be 3 demos , or someone else that knows more than me maybe how to link them up ,, sorry if this is the case to BlinkOK who has put in a lot of effort for me , SORRY

mick :(

10 point for red , green , blue prezzie , minus 10 points for parcel
the idea is that you start off with a 100 mixed items and carry what you collect to level 2
Title: Re: santa's sorta
Post by: kevin on December 04, 2008, 07:12:41 PM

Mick,

  Nice, this look and plays very well also !   

 
Quote
i started each level seperate to make it easier for me to do , but now im having big problems putting them together , bugger ,, lol
well still learning i suppose , next time if i do more than one level i will do them together ,

   So each level is different program completely ?  -  This is not a great idea, as you've no doubt found out.  Things will clash all over the place when you try and merge them.

   Without seeing all of the code,  this is a guess,  but I'd say the easy option would to wrap each level into it's own Function.  This will get rid of some of the clashing problems with variables/arrays.  Not with media though.  Since you're still explicitly using Media indexes.   If you changed to a dynamic approach the clashing problem will vanish.







Title: Re: santa's sorta
Post by: BlinkOk on December 05, 2008, 03:41:43 AM
hey micky dude. that looks greeat. nice game mechanic too. good luck with the other levels dude.
i wouldn't worry to much about getting it done before chrissy. it's more about learning the language i think.
i'd still be interested in it if you finished in july so just keep plugin' away ok.
Title: Re: santa's sorta
Post by: micky4fun on December 05, 2008, 05:19:25 PM
Hi all


So each level is different program completely ? yes sure was , silly billy i am i know ,

well good news all levels now linked , a small bug in level one to be iron out tomorrow hopefully
also i am still having no luck with the flash splash screen , been on it for a while tonight but no joy
what i am going to do i think is put game up , then maybe someone can add it for me

ok thanks for all the kind words and support Kevin and BlinkOk , kept me plugging away at it all day
im wacked now ,
hopefully will be all done for sunday

mick :)

ps im smiling again now ,, but what fun , no hair but a smile , lol
Title: Re: santa's sorta
Post by: micky4fun on December 07, 2008, 06:43:05 AM
Hi all

OK here it is then , ive left it in 1024x768 full screen for time being , but if you want to add flash splash screen then by all means , i just cant seem to suss it out ,
just delete screenvsync on , to setfps to whatever seems the right speed .
Thanks to BlinkOk for santa's animations and splash screen work ,, many thanks
Thanks to Kevin for all the help and him and he's team for this great program

instructions..

level 1 , use mouse to collect the red , blue and green prezzies , but not the orange parcels
100 point per prezzies , but if you collect a parcel then score back to zero
all the prezzies you collect will carry forward to level 2 to be sorted.

level 2 , use mouse and keyboard , keys R , G , B .. move mouse target over prezzie and then press R if a red prezzie
press G if a green prezzie and so forth but be quick ! , this will sort them out
all prezzies sorted out correctly carried forward to level 3 to be delivered.

level 3 , use mouse left button to drop prezzies into house with red arrow in chimney

GOOD LUCK , and MERRY XMAS to all..


heres the game

new download
[plink] Get Santa Sorta (http://www.underwaredesign.com/files/Micky4Fun/santa's_sorta.zip)[/plink]




mick  :)

yep there is a little bug on level one , but hey !!

ps forgot to put up code , will post this asap, its messy so ile try to tidy it first
Title: Re: santa's sorta
Post by: kevin on December 07, 2008, 08:42:50 PM

Good job, this is excellent ! 
Title: Re: santa's sorta
Post by: micky4fun on December 09, 2008, 05:33:06 AM
yes im very pleased with this my 3rd attempt , the download backdrops and BlinkOk santa animations make the game look good , i will post code as soon as i tidy it up a bit in a day or 2 as i have other things to do for now , hopefuly someone will add BlinkOk splash screen as well , a slight bug in level one where a prezzie apears from nowhere , i cant see where the codes wrong? but must be someware , i have 3 or 4 more game ideas i will start as soon as i can , but i think i will have to go some to beat the look of this game with my artistic skills , ie none , lol ,,

mick :)
Title: Re: santa's sorta
Post by: micky4fun on December 09, 2008, 03:55:03 PM
Hi all

ok heres the souce file for the game,
would be great to se the santa splash screen BlinkOK did put on the frontend of this , if anyone does do it would they please post souce so i can see how its done..

I also just wanted to say as a novice programmer , for doing lots of types of games , shooters , froogie , santa's sorta , etc i found the 500 bubbles demo a great place to start..
using the types and dim arrays commands , they are very powerfull commands and quite easy to pick up with great results , hope this helps any novice like myself..

thanks
mick :)
Title: Re: santa's sorta
Post by: kevin on December 10, 2008, 04:26:52 PM
  Thanks for the posting the source code.   You'll have to set your own little Mick's game site soon.  Already got enough games :)   Concerning the intro, if you had the appropriately sized gfx, it wouldn't be difficult to write a PB version of the intro.   
Title: Re: santa's sorta
Post by: Big C. on December 15, 2008, 05:50:22 PM
Hoh hoh hoh mick ;D

Here is my way... It isn't 100% but it will do the job... Anybody knows why the flashfile is jerking at the loading ???

The following Part of code I've insert at the beginning  (see attached file for complete version. You need all GFX from the Release Version of the game!)

[pbcode]

#Include "PBFlash.pba"

OpenScreen 1024,768,32,1

SetFps 60

_Init(GetScreenHandle())

SplashScreen:

SantaFlash = NewFlash(CurrentDir$() + "gfx\santas_sorta.swf", 0, 0)
   
ShowFlashStart:

   If GetFlashVariable(SantaFlash, "_root.gameMode") = "play" And IsFlashPlaying(SantaFlash) = 0
      HideFlash SantaFlash
      Goto Init
   EndIf
   
Goto ShowFlashStart   

Init:

DeleteFlash SantaFlash


;----------------------------------------------------------------------

[/pbcode]

Please take notice that you have to play the game in windowed mode if you want to implement a Splashflashscreen (see here (http://www.underwaredesign.com/forums/index.php?topic=1159.msg12314#msg12314))

2 Hints for Kevin:

If I run my solution in Debug-Mode I got an error and found cruft code at the end of PBFlash.pba. Can you proof this in your Version pls and maybe correct it?
QuoteThis was in my file at the end:
#IF PBDebug=True
   #IF PBDebugMode=2
      #Trace _PBLIB_ACTIVEX_PREVDBGSTATE
   #ENDIF
#ENDIF



Second:
Quote; make a new window
openscreen 740,500,16,1

;attach pb flash to it
_init(GetScreenHandle())

This is a very usefull hint I missed in the Helpfiles... Maybe it find his way as a part of the file "About the PBFlash library - How to use this library"

cheers Big C.

Title: Re: santa's sorta
Post by: micky4fun on December 16, 2008, 02:08:21 PM
Hi Big C.

Thanks for post , see what you mean , its very jerky , would be nice if Kevin could av a look when he gets time as he must know whats stopping it running fluid ,
i did muck around with it for about a hour , but ive not really got a clue what im doing , apart from frezzing my p.c a few times , lol

Thanks again

Mick :)
Title: Re: santa's sorta
Post by: kevin on December 23, 2008, 06:01:36 AM
  if you use flash with PB, you still need to SYNC in your PB app.    This will keep the app running at a more constant speed,  but it's never going to super smooth.  

 ie.
[pbcode]
   
ShowFlashStart:
      cls 0

         If GetFlashVariable(SantaFlash, "_root.gameMode") = "play" And IsFlashPlaying(SantaFlash) = 0
             HideFlash SantaFlash
             Goto Init
          EndIf

      sync   
      Goto ShowFlashStart   

[/pbcode]