theres a couple of nice looking projects in the show case that im very much looking forward to when released,
so i think im going to start a longer project here , with the option to jump to another small project inbetween
that way gives me some freedom , so heres a simple looking and hopefully simple to program scrolling platform game in the mario type theme
with things to collect , dodge , kill etc
at the moment the map blocks are 64x64 pixels so a 16X12 screen at 1024x768 resolution , a bit large i know but going to try and get away with this if i can
heres a starting level screen shot , but this will take a while to complete i would have thought
btw , some of you might reconise the man from another demo in the PB folder
mick :)
nice idea =) good luck micky4fun
Quote
so heres a simple looking and hopefully simple to program scrolling platform game in the mario type theme
with things to collect , dodge , kill etc
at the moment the map blocks are 64x64 pixels so a 16X12 screen at 1024x768 resolution , a bit large i know but going to try and get away with this if i can
heres a starting level screen shot , but this will take a while to complete i would have thought
Yeah making the levels is always the sticking point. So do yourself a huge favor and build a level/world editing tool. Doesn't have to be pretty, just enough to stick the blocks in place, drop the starting positions of the characters and set whatever global variables the world has.
Thankfully, the original mario games are based on some pretty simple rules, so the coding side of it should be a breeze.
Quotebtw , some of you might reconise the man from another demo in the PB folder
I think that's another blink one. It's a version of some other guys walking dude, can't remember the name. Will have to search for the thread in minutes, it's on here somewhere.
Found it, It's [plink]Draco's Tale (http://www.underwaredesign.com/forums/index.php?topic=785.0)[/plink]
sounds good mick. i've heard some very good things about the tiling system in PB.
there are a lot of very good free tile graphics out there if you wanna look around too
cool micky. looking forward to see what you come up with.
i found platformers fun to make. learnt a lot too. post code when you can so we can see your progress.
stevmjon
Hi All
QuoteSo do yourself a huge favor and build a level/world editing tool. Doesn't have to be pretty,
yes think i will take your advice here , i can be a bit of lets just get going , but as i am going to take time on this i will knock one up and your right again it wont be pretty , haha
Quotesounds good mick. i've heard some very good things about the tiling system in PB.
there are a lot of very good free tile graphics out there if you wanna look around too
yep BlinkOk will try and go a bit deeper in the maps commands , only really used it very lighty in Bank Job game
Quotecool micky. looking forward to see what you come up with.
thanks stevmjon , me to , platform games are my favourite type of game , so about time i tried one
yes will post any updates as soon as it starts taking shape
mick :)
there are a few 3rd party/free level editors out there. you might wanna check them out too.
Hello Mickey4fun!
Sounds and looks interesting! Let you know us, how you manage your program?
I like jump and run games, too! :)
Sigtrygg
I don't know how old this post is but I'm going to reply.
Mick if you want I can sit down with you and take some time to help you build a nicer tile/level editor.
The first step is to figure out a sort of format for your levels.
If you design a level file first it becomes alot easier to read in and out the level data.
I recently got into doing this sort of habit rather than having to re load all my level data every single time I wanted to test a new mechanic in my test level using my dkc2 game engine. xd and yeah it will save you a ton of time when debugging to already have set up.
The first method you should use once you load all your images/sound/media and set all your variables and arrays up is start loading the level.
To help you out I'll post my level loading code from my dkc2 editor. Feel free to adjust/change it to your liking. Actually. I'll do you one better.
I'll give you the code that saves the level file and the code that loads it!
Saves:
[pbcode]
if mouseinbox(0, 600, 0+(128*2), 664)
if leftmousebutton()
if fileexist("C:/brambles_map2.txt")
deletefile ("C:/brambles_map2.txt")
endif
writefile "levels\brambles_map2.txt", 1
writeint 1, Mapwidth
writeint 1, mapheight
writeint 1, charx
writeint 1, chary
writeint 1, scrollx
writeint 1, scrolly
for tempx=1 to Mapwidth
for tempy=1 to mapheight
writeint 1, map(tempx, tempy)
writeint 1, solids(tempx, tempy).x1
writeint 1, solids(tempx, tempy).y1
writeint 1, solids(tempx, tempy).x2
writeint 1, solids(tempx, tempy).y2
next tempy
next tempx
for tempx=1 to MAPWIDTH/2
for tempy=1 to MAPHEIGHT/2
writeint 1, TILEMAP(tempx, tempy)
next tempy
next tempx
for temp=1 to 30
writeint 1, b_barrels(temp).facing_type
writeint 1, b_barrels(temp).x1
writeint 1, b_barrels(temp).y1
writeint 1, b_barrels(temp).x2
writeint 1, b_barrels(temp).y2
next temp
closefile 1
endif
endif
[/pbcode]
Loads:
[pbcode]
read=false
if fileexist("levels\brambles_map2.txt") then read=true
IF READ=TRUE
readfile "levels\brambles_map2.txt", 1
ink rgb(0, 0, 255)
tile_to_read=1
totaltiles=MAPWIDTH*MAPHEIGHT
rendertoscreen
Mapwidth=readint(1)
mapheight=readint(1)
charx=readint(1)
chary=readint(1)
scrollx=readint(1)
scrolly=readint(1)
dim map(MAPWIDTH, MAPHEIGHT)
dim TILEMAP(MAPWIDTH/2, MAPHEIGHT/2) ;32 by 32 pixel tiles
dim solids(MAPWIDTH, MAPHEIGHT) as solid_tile
coinframetimer=timer()+30
for tempx=1 to MAPWIDTH
for tempy=1 to MAPHEIGHT
map(tempx, tempy)=readint(1)
solids(tempx, tempy).x1=readint(1)
solids(tempx, tempy).y1=readint(1)
solids(tempx, tempy).x2=readint(1)
solids(tempx, tempy).y2=readint(1)
x1=solids(tempx, tempy).x1
y1=solids(tempx, tempy).y1
x2=solids(tempx, tempy).x2
y2=solids(tempx, tempy).y2
;rendertoimage castle
;box x1, y1, x2, y2,
;rendertoscreen
;tile_to_read=tile_to_read+1
next tempy
print "Loading SOLID TILE DATA PLEASE WAIT "
print "Reading Across X: "+str$(tempx)
print "Total Reads remaining: "+str$(MAPWIDTH-tempx)
percent#=((tempx*100)/MAPWIDTH)
print "Percent completed "+str$(percent#)
ink rgb(percent#*2, percent#, 255)
box 200, 50, 200+(percent#)*5, 60, 1
ink rgb(0, 255, 0)
box 200, 50, 200+100*5, 60, 0
drawimage dk_barrel_(dkcoinframe), 180+percent#*5, 20, 1
sync
cls rgb(0,0,0)
dkcoinframe=dkcoinframe+1
if dkcoinframe=>7
dkcoinframe=1
endif
next tempx
for tempx=1 to MAPWIDTH/2
for tempy=1 to MAPHEIGHT/2
TILEMAP(tempx, tempy)=readint(1)
next tempy
next tempx
for temp=1 to 30
b_barrels(temp).facing_type=readint(1)
b_barrels(temp).x1=readint(1)
b_barrels(temp).y1=readint(1)
b_barrels(temp).x2=readint(1)
b_barrels(temp).y2=readint(1)
next temp
closefile 1
falling=true
mode$="playmode"
ENDIF
[/pbcode]
Of course this is a bit advanced because the loading screen has a progress bar rendering on it as well.
And not only that but also the sprites are read in as well and their positions on the map.
Mick,
Quote
yes think i will take your advice here , i can be a bit of lets just get going , but as i am going to take time on this i will knock one up and your right again it wont be pretty , haha
That'd be first :) ... Anyway, there's a lots and lots of ways to externalize the 'game' data from the program. Many of which are more hassle than they're worth. The easiest solutions store the minimal amount of level/character entity info in the file. I'd prolly use a markup format (Text files) rather than a binary format, as it allows the 'level maker person' to make changes easily. (NotePad).
So depending what you're aiming at, you'd define the animations, character types, level layouts, world properties and level all externally. Ideally, the structures are set out in some human readable form. Basically you load the text file(s) into memory, split it each one to an array, then run through it (top to bottom) looking for the action tags. Ideally the tags should make sense to head reader.
; Start Of Section Define
Level-Start
; Time player has to complete level
Time Limit = 60
; etc etc
Level-End
; End Start Of Section Define
Animations-Start
;
AddAnim
{
Name= PLAYER_RUNNING
MaskColour = $ff00ff
Frames =Running1.png,Running2.png
}
AddAnim
{
Name=PLAYER_WALKING
MaskColour = $ff00ff
Frames =Walking1.png,Walking2.png,Walking3.png
}
Animations-END
The program doesn't use this information as is, it imports/parses the materials into whatever arrays/structures inside the game. So the actually programming isn't really any different. With one HUGE exception, resource are dynamically allocated. Making the program a lot more expandable.
Food For Thought,
* Entity Example (Loading Game Levels) (http://www.underwaredesign.com/forums/index.php?topic=3680.0)
* Combine two words to make an array?(Sprite Animations) (http://www.underwaredesign.com/forums/index.php?topic=3784.0)
* Thesius XIII (http://www.underwaredesign.com/forums/index.php?topic=1896.0)
http://www.ogmoeditor.com/ (http://www.ogmoeditor.com/) or http://codeboje.de/list-of-2d-map-editors/ (http://codeboje.de/list-of-2d-map-editors/)
then you can just get on with the game
Hi all
well lots of help here thanks guys
LemonWizard , thanks for code have looked through it and given me a few ideas ,
BlinkOk , thanks for link to level editor , i have just installed that and will give that a go , just going to read the tutorial , ahh more there now loads to choose from , well thats tomorrow taken up ,
Kevin , thanks for code snippets and advice on level/map editor
well today i have spent most of the day just doing that , trying to make a level/map editor , well tried 2 differant ways but then ran into problems if i wanted a large map/level
then ironically , i tried making a map editor using the map commands and that seems the best at the moment its basic but can be added apone , though i have one small problem with that , but dont think at this stage its a worrie
but someone there might see what im doing wrong , if i can explaine it properly
ok here goes , if you load the map editor up , at the moment im using 64x64 pixels per tile on a screen res of 1024x768 so 16x12 tiles, yep rather large
so to start just do a 16 tiles across by 12 tiles down by 1 screen across by 1 screen down
now use mouse to select tile to use from above tiles , then place them on grid layout by pressing mousebutton 1 , delete tile if placed in wrong place by pressing mouse button 2
you can use arrow keys to move map if you do a large one later on , but try this first to see my problem , i have 17 squares by 13 instead of 16 by 12 , i have just the little white box of the image to fill tiles not needed
ok once your map is done , just do a screen border to start , then press spacebar to save the file , this will be data1 file
now copy that file to the platform v1 folder overwriting file already there
load up platform v1 and run , you man always falls from top of screen to bottom , so make sure he has a block to fall on
then just use the arrow keys to move him , all very basic movements at the moment
the saved data1 file contains first the map x amount and then the map y amount , then all the tiles
the trouble i have is in the map editor v1 i need to get rid of the unwanted row of tiles x and y
and onced saved will load ok into platform v1 program , but its not a major worry , but would be nice to clear up
ok bed long day
thanks again guys
mick :)
Looking at the editor I'm not sure why you've got map level and array to mirror the level. But anyway, I suspect the sizing is different because array bounds are inclusive->inclusive and map levels are inclusion -> exclusive. So an array of 10 items, actually has 11 valid indexes (0,1,2,3,4,5,6,7,8,9,10 ) Where a level that's 10 tiles wide say, has only 10. 0,1,2,3,4,5,6,7,8,9
In the editor, what i'd prolly do is set up areas of gadgets. So one area would be the block palette (like you've got), another might be help window. Some just text drawn to a image and splodged in front. Where Key short cuts.. Another might be menu dialog Since this is simple GUI, when the user clicks or moves the mouse, it's important the programs reaction is relative to the area. So when over the block palette clicks, this only affect block selection and not drawing. Same goes for any other windows.
Anyway, ideally the two program would use the same include files, which is something you've never done before. An include is just a chunk of code, generally fully functions or declarations (types/ arrays / constants). Having them both share code, makes programming a 1000 times faster. You write once and the once both sides share the changes.
Hi all
well thanks again to all ,
i did try all the level editors and the D2Dmapeditor was the nearest i could use i think ,
i will come back to that a little later and give it a full try out , if not may continue with mine
but for the time being now i want to get use to the map commands and suss out what i can and cant do , what is easy for me to do and what will be to hard for me to get to grips with and go the easy root,
QuoteLooking at the editor I'm not sure why you've got map level and array to mirror the level
oh dear , oh yes i have taken the grid array out now and used the peektile command to get the tile info out to save as file
ok while tinkering around today i was wondering if theres an easy way to get my man to jump up one tile at a time , while standing under say 3 tiles on top of each other and say while on second tile still be how to move left and right on that tile
and jump up one more tile even though that tile is directly above him , as in picture
hope i have explained that well , would i have to do a map with differant levels to do that ?
i have include code , so i want him to move along first stack of tiles walk in front of them . and jump up one tile level even when there are 3 tiles above hes head and land just one level up from where he was
is that possible without being very complicated anyones help would be appricated
thanks
mick :)
here is a little dude i made ages ago (he's in the PB banner), run, jump and stand (the stand one is a stand + look around)
i'm not sure if the run is too fast for what you want but if it's ok you're welcome to use him
(http://www.underwaredesign.com/screens/PlayBasic/Games/ForFoxsSake/run-1.gif) (http://www.underwaredesign.com/screens/PlayBasic/Games/ForFoxsSake/stand.gif) (http://www.underwaredesign.com/screens/PlayBasic/Games/ForFoxsSake/jumptest.gif)
originals: run (http://i93.photobucket.com/albums/l75/blinkok/run-1.gif) - stand (http://i93.photobucket.com/albums/l75/blinkok/stand.gif) - jump (http://i93.photobucket.com/albums/l75/blinkok/jumptest.gif)
Hi all
thanks for little spaceman BlinkOk , i have hime now , as this platform as changed a bit since day one , i just wanted to try a few things out , things i can get to grips with
i started at a 64 pixel square block , now i find thats not really ideal , think a 32 pixel square is the way to go next time maybe ,
but i am going to stick with 64 and do a game on that , i have decieded to use my own map editor and ad to it as needed , still in a simple form
i am not good enough to do a flash looking one , but was definitely a good call from Kevin , would be a nightmare without one , can draw map in seconds rather than hours
just added a save reload save map to editor , with ad other things as i go , can use this on other map projects
ok i have now come up with this , as doing this game on the fly as well , multi level either one long level at 1 screen hight or a 3 or 4 screen by 2 or 3 down
proberly going for a title of garden capers or foxes dilemma's ,
you are required to do a few garden tasks while dodging hedgehogs , snails , worms etc , dripping water ,
taskes to be added , but errecting fence panels , painting fence , cutting edge , planting seads etc
quick screen shoot below , will pop back when more done
mick :)
Hi All
well starting to take shape now , but does now start to looks very mario ish , proberly not a bad thing ,
anyway , its now full on this game with now sidestepping , lol
one thing i see is that these tiles soon mount up , should have enough soon to do the bathroom , lol
mick :)
looking very nice mick. luv the colours.
micky4fun, this screen-shot is pretty good!
Hi all
yep thanks BlinkOk and ATLUS , well its really looking like a mario game with the pooyan fox , lol , but its given me a good insight into the map commands thats for sure ,
yes colours are bright and bold , which look nice ,
has its a mario sytle playformer , i am trying to keep the game moving as much as possible , so the idea of mending fence and then painting it , is going to be just painting it , otherwise think you will be to long on one part of screen doing 2 things ,
just getting all the graphics together so i have what i need to do levels , then will start to do baddies and moving platforms etc , then get them to be plotted in the map editor program i have done
dont know how long this game is going to take , lets see
Quoteideally the two program would use the same include files, which is something you've never done before.
erm dont think i will be upto that , this will have to be done in main program i think
ok video time , lol , well this time it looks better in real life than on video
http://www.youtube.com/watch?v=exq9ATuF4sI
if you look carefully you will see fences change colour when passed by , brush and walking to be added
ok back soon :)
Quoteerm dont think i will be upto that , this will have to be done in main program i think
Nope. All you do is create two folders. One called
game the other for
editor for example. The game source code + media gets put in the Game folder. The Editor source code goes in the editor folder. For anything that the editor needs to share with the game, you #Include it (picture bellow). Same goes for files.
In the attached example there's the two projects. Both projects share the a common source file in the game project folder called "Map-Engine.pba" , that source consists of all the code to load/display and save if need be a map. You'd obviously 'format' the load and save data however you need. Within this file it also defines universal constants such as the block width, height etc. These are hard coded into the example for clarity, even they don't really need to be.
Since the file is shared, then the game/editor can both benefit from changes made to the map library source code.
Hello Micky4fun!
The game looks very nice! Especially the movement of the clouds
are very living! Jumping looks fine.
I am curious how you develop the game further.
Bye
Sigtrygg
cool micky4fun. the character movement is pretty smooth.
looking forward to your progress.
stevmjon
i realize a spaceman is pretty useless for this one so i did a quick fox. hope it's ok.
if you're working on something then no probs.
(http://i93.photobucket.com/albums/l75/blinkok/walk.gif)
let me know if you wanna use it and i'll do jump and land (and any others you need) frames as well
Hi all
Ok thanks for code snippet Kevin ,
thanks stevmjon for your comments , still looking out for your platform game , hope you are still getting a chance of getting it back on track , lots of hard work i know , very time consuming
also thanks to sigtrygg for comments to , well cheating a bit at the moment with clouds , just a tileimage command with a looped cloud effect , shame i cant use this in game as will only tile resolution of main screen and when camera starts moving then it soon disapears off screen , so either a tileset of clouds needed or a few sprites
well BlinkOk , yep your fox fits the bill perfect , he will do as is at the moment , lets get the game going first to see if i need any other frames etc
yep 64x64 is great ,
been slow last week and this week as loads of people off work and im covering for them , but trying out and doing what i can
ok heres you fox in game picture is 800x600 but game is 1024x768 if you look carefully you may be how to see the paintbrush he is looking for , back soon
mick :)
looking very cool mick. it's got a bit of a mario meets sonic vibe.
just thinking that it might be easier if the tiles in the sky were 32x32
so they would line up with the 64x64 tiles.
Mick,
It's looking really good.
Quote
also thanks to sigtrygg for comments to , well cheating a bit at the moment with clouds , just a tileimage command with a looped cloud effect , shame i cant use this in game as will only tile resolution of main screen and when camera starts moving then it soon disapears off screen , so either a tileset of clouds needed or a few sprites
There's no support TileImage in the camera, so if want to tile something you either render the fragments relative to the cameras position (see sparkler) or just draw it immediately prior to rendering the camera scene over the top. The latter is prolly easier. You could use sprites, but if the play never interacts with the parallax, then it's not worth it.
[pbcode]
; ---------------------------
; make some simple backdrop images
; ---------------------------
cls 0
Circlec 32,32,32,true, $00333333
GetIMage 1,0,0,64,64
cls 0
Circlec 64,64,64,true, $00555555
GetIMage 2,0,0,128,128
; ---------------------------
; make the cameras
; ---------------------------
Cam=NewCamera()
CameraCls Cam,Off
; lock the frame
Setfps 61.7
; ---------------------------
; main loop
; ---------------------------
Do
; draw one layer of backdrop first in immediate mode
Xpos=GetCameraX(Cam)/4.5
Ypos=GetCameraY(Cam)/4.5
TileIMage 1,Xpos,Ypos,false
; draw another layer just for simething to look at
Xpos=GetCameraX(Cam)/2
Ypos=GetCameraY(Cam)/2
TileIMage 2,Xpos,Ypos,true
capturetoscene
clsscene
// draw game scene stuff
mx=mousex()+GetCameraX(Cam)
my=mousey()+GetCameraY(Cam)
SpanAngle#=wrapangle(SpinAngle#,1)
For lp =0 to 36
x2=MX+Cos(SpinAngle#+LP*10)*100
y2=MY+Sin(SpinAngle#+LP*10)*100
linec mx,my,x2,y2,$00ff00
next
DrawCamera cam
MoveCamera Cam,1,0
Sync
loop
[/pbcode]
You can find a function call CustomTileIMage in the Sparkler demo (http://www.underwaredesign.com/forums/index.php?topic=3176.0) demo, which shows how to draw only whats needed to fill the camera/screen viewport.
Hi all
Thanks for code snippet , that works fine , i did try that way but i did not include the CameraCls Cam,Off command so it did not show back ground as i did not grasp what this command did , easy when you know how
Ok back to game for an hour or so as bed looms
mick :)
Hi all
time still short this week , but will crack on weekend a bit , heres a little feeler to try out , just a static screen at mo , but will scroll soon
use arrow keys to paint fence
foxes pixels to platform to be tightened up later , so he may overhang a bit
also baddies to be done when all map laid out
mick :)
very nice micky4fun =)
Hello Micky!
Game looks great!
I am looking forward for more! :)
Sky moving looks very fine!
Greetings
Sigtrygg
Looks really good, but it's impossible to play here, way too fast..
We can't assume a any system has Vsync enabled (or is even supported for that matter), as it's frequently disabled in video card drivers. Therefore, it shouldn't be used a frame rate limiter. To detect if a video card diver is actually waiting from the top of each frame during a sync (flipping the screen buffers), we can time the lenght of each frame. Systems that are waiting, will give us steady delta of 16/17 ticks (or more) per frame assuming a 60 frames per second video refresh at resolution. Systems that don't wait will end up with an average delta inside a millisecond or so. Allowing our program to detect the environment upon which it's running.
[pbcode]
// request vsync
ScreenVsync true
// array to hold the clock ticks at the start of each new frame
Dim SyncTicks(30)
// flip the buffer 30 times to collect from information
// about the the users system
For lp =0 to 30
Cls 0
Sync
SyncTicks(lp)=timer()
next
// Calc the average delta time per frame
TotalTicks=0
For lp =1 to 30
TotalTicks+= SyncTicks(lp)-SyncTicks(lp-1)
next
SyncAverageDelta#=TotalTicks/30.0
// If the delta is bellow say 5 ticks per frame, then it's highly unlikely this
// system has vsync enabled or supported
if SyncAverageDelta#<5
print "Doesn't Support Vsync"
else
print "Has Vsync"
endif
Sync
waitkey
[/pbcode]
nice work mick. it's lookin great.
if you're interested i could make up some tiles for you. (actually i already have)
but it's up to you as always. no biggie if you wanna do them yourself
Hi All
sorry yep i will put the option to disable screenvsync and set fps in game ,
though i could use code snippet to do it automatically ,
btw the new way code snippets are done does look good , but when i copy it , ie highlight it and copy it and then paste it into PB , it needs a bit of editing around to get it working
the old code snippet worked straight away , but i think i read that you are going to do a copy button !
yeh BlinkOk any tiles that you can supply would be great ,
thanks ATLUS its coming along
sigtrygg , yeh the tileimage makes this quite simple as long as the image begining and end line up , its called something but i cant remember what , think Kevin or BlinkOk will know
thanks
mick :)
Quotebtw the new way code snippets are done does look good , but when i copy it , ie highlight it and copy it and then paste it into PB , it needs a bit of editing around to get it working
the old code snippet worked straight away , but i think i read that you are going to do a copy button !
your using IE ? (LInk (http://www.underwaredesign.com/forums/index.php?topic=3912.msg26004#new))
ok no worries mick. the only thing about these tiles is you need to be able to overlay tiles one on top of the other some times and some are animated.
(you might need me to merge the bridge edge tile and the start of the bridge. just let me know how you wanna deal with that)
(http://i93.photobucket.com/albums/l75/blinkok/test.png)
ANIMATED VERSION (http://www.swfcabin.com/open/1346968619)
note: i just bunged all the images in the .rar file. some may not be tiles
ps: forgot the dark tiles
pps: background image in rar is wrong
ppps: let me know if you need any other animations or tiles
pppps: can you make the water transparent using a blend (normal blend)? is that gonna work?
ppppps: just had a thought; if you make the bg2 image 1000px wide rather than 1200px it will add more variation to the background in combination with bg1
pppppps: added stuff for the paint brush
ppppppps: jump animations
Hi All
Quoteyour using IE
yes version 9 , though i have tried it since and it seems fine now ,
Thanks BlinkOk for tiles and gfx's , all fantastic , fox nice n sharp now , will have a muck around weekend and see how i can imply them ,
see what i come up with ,
not tried any tile animations yet , will look on how to load animations gfx's into a map block cell
Quotepppps: can you make the water transparent using a blend (normal blend)? is that gonna work?
dont know if i can do this , dont know if there is a way to make a tile semi transparent , of if there is another way to do water effect
but will look into this
mick :)
Hi all
well ive started to do some animations blocks a little stumbling though , in the example i have copied from the example folder , cut down version , i include below ,
"" i can animate a block , starting from image position 0 to 10 , so 10 frames , but say i want to start from position 20 of the image and goto position 30 , in the forward motion , how do i do that so it loops nicely ?""
haha i have sussed this out now , so no worries on that , just the Constant z thing please
also what is Constant z=$80000000 needed for what does that do i know it dont animate without it ? , can i change value , or is this the value required , is there a decimal value
[pbcode]
Setfps 75
LoadImage "212.bmp",2
width=32
height=32
ThisMap=GetFreeMap()
CreateMap ThisMap,2
MakeMapGFX ThisMap,2,width,height,34,$ff0000
MapAnimQuantity ThisMap,10
For lp=0 To GetMapAnims(ThisMap)
ThisAnim=GetFreeMapAnim(thismap)
CreateMapAnim ThisMap,ThisAnim,10
For lp2= 0 To 10
PokeMapAnim ThisMap,ThisAnim,lp2,10+lp2
Next
ResizeMapAnim ThisMap,ThisAnim,10
MapAnimFrameRate ThisMap,ThisAnim,15
MapAnimType ThisMap,ThisAnim,1
Next
MapAnimQuantity ThisMap,678
CreateLevel ThisMap,1,10,10
Constant z=$80000000
For lp=0 To 10
PokeLevelTile 1,1,2,1,z
PokeLevelTile 1,1,2,2,3
Next
LevelTransparent 1,1,1
LevelAnimated 1,1
Repeat
Cls 0
DrawMap 1,1,x#,y#
UpdateMapAnims ThisMap
Sync
Until EnterKey()
DeleteMap 1
WaitKey
END
[/pbcode]
any help on this would be great and save me lots of time
thanks guys
mick :)
Quotelso what is Constant z=$80000000 needed for what does that do i know it dont animate without it ? , can i change value , or is this the value required , is there a decimal value
it's the sign bit in a 32bit integer.. These days we use the
PBMapAnim_Mask constant when tagging a tile as being an animation index, rather than a block index in the map.
Quote
The PokelevelTile() function will store either Tiles Index or Animation Index directly into a level array.
Animation Note: When play basic draws a level, it distinguishes between normal block and animation indexes tiles by performing a Bit TEST on value. Normal block indexes should be stored as positives values (from 0 to the number of blocks this map has). To store an Animation index, the index needs to be OR'd with the PBMapAnim_Mask constant. This will appropriately tag this value as animation index, rather than a block index.
I.e. Poking an animation index into a level.
PokeLevelTile MyMap,MyLevel,TileXpos,TileYpos, MyAnimationIndex Or PBMapAnim_Mask
as for what integer it is, it's this
[pbcode]
print $80000000
print PBMapAnim_Mask
sync
waitkey
[/pbcode]
made a quick mock up,
BlinkOk, again very good style!
thanks atlus. looks like kevin has the transparency working too. nice work
Hi all
ok thanks Kevin , see you have a nice mock up running looks very nice you would have a complete game within a few hours , haha , any chance of the code so i can see how the transparency works within the tiles ,
blinkOk will get to work today starting a larger level off , take it that the water part of the level will only be here and there within the level
thanks mick :)
ps
just tried a few different animations for water and coins , so i set the animation mask to $80000000 for first animation seqence that i have set up then $80000001 fro the next and so on, thats works ok here
but still need help with transparent blocks or water effect please
thanks
mick :)
As you can see, there's nothing to it, although you'll have to convert the png's to ARGB format. Just load and re-save them in Paint.net or anything that defaults ARGB format pngs.
[pbcode]
#include "framesheetanims"
Type tFrameSheets
Coin
FoxWalking
Water
EndType
Type tGameImages
BackDrop(2)
Clouds(2)
Dirt(10)
Trees(10)
EndType
Dim FrameSheet as tFrameSheets
Dim GameImage as tGameImages
Path$=currentdir$()+"Media\"
; Tell it load AFX formatted frames
FrameSheetCreationType(2)
FrameSheet.Water =LoadSequentialFrameSheet(Path$+"water####.png",1,9,0)
FrameSheetCreationType(8)
FrameSheet.Coin =LoadSequentialFrameSheet(Path$+"coin####.png",1,9,-1)
FrameSheet.FoxWalking =LoadSequentialFrameSheet(Path$+"walk####.png",1,9,-1)
GameImage.Backdrop(0) =LoadNewFXImage(Path$+"Bg2.bmp")
GameImage.Backdrop(1) =LoadNewFXImage(Path$+"Bg1.png")
GameImage.Clouds(0) =LoadNewaFXImage(Path$+"cloud1.png")
GameImage.Clouds(1) =LoadNewaFXImage(Path$+"cloud2.png")
GameImage.Dirt(1) =LoadNewImage(Path$+"dirt tile left.png",8)
GameImage.Dirt(2) =LoadNewImage(Path$+"dirt tile.png",2)
GameImage.Dirt(3) =LoadNewImage(Path$+"dirt tile right.png",8)
GameImage.Dirt(4) =LoadNewImage(Path$+"dirt dark.png",2)
GameImage.trees(0) =LoadNewImage(Path$+"tree1.png",8)
GameImage.trees(1) =LoadNewImage(Path$+"tree2.png",8)
GameImage.trees(2) =LoadNewImage(Path$+"tree3.png",8)
Screen=NewImage(800,600,2)
Spin =NewAnim(FrameSheet.Coin,2)
Water =NewAnim(FrameSheet.Water,2)
FoxWalking =NewAnim(FrameSheet.FoxWalking,2)
;Setfps 50
Do
RenderToImage Screen
PlayerX#+=1
ScreenX#=Mod(PlayerX#*0.10,800)
Xpos=-ScreenX#
DrawImage GameImage.Backdrop(0),Xpos,0,false
DrawImage GameImage.Backdrop(0),Xpos+800,0,false
img=GameImage.Backdrop(1)
ScreenX#=Mod(PlayerX#*0.25,800)
Xpos=-ScreenX#
DrawImage img,Xpos,GetSurfaceHeight()-GetImageHeight(img),true
DrawImage img,Xpos+800,GetSurfaceHeight()-GetImageHeight(img),true
ScreenX#=-Mod(PlayerX#*1.5,800)
DrawImage GameImage.Clouds(1),Screenx#+0100,150,true
DrawImage GameImage.Clouds(1),Screenx#+0100+800,150,true
DrawImage GameImage.Clouds(0),Screenx#+0500,60,true
DrawImage GameImage.Clouds(0),Screenx#+500+800,60,true
BlockHeight =64
Xpos =0
Ypos =GetSurfaceHeight()-BlockHeight
DrawDirtString("012444423000000",xpos,ypos)
DrawTree(0,XPos,Ypos)
Ypos-=BlockHeight
DrawDirtString("00122222230000",xpos,ypos)
DrawTree(1,XPos+128,Ypos)
Ypos-=BlockHeight
DrawDirtString("0000012430000",xpos,ypos)
DrawTree(2,XPos+256,Ypos)
Ypos-=BlockHeight
DrawDirtString("000000123000",xpos,ypos)
DrawAnim FoxWalking,400,300,true
DrawAnim FoxWalking,500,350,true
ThisFrame =StepAnim(Spin)
GridImage ThisFrame,400,ypos,3,1, true
ThisFrame=StepAnim(Water)
Width =GetImageWidth(ThisFrame)
Ypos =GetSurfaceHeight()-GetIMageHeight(ThisFrame)
For lp=0 to 800 step width
DrawAlphaImage ThisFrame,lp,Ypos,0.5,true
next
rendertoscreen
DrawImage Screen,0,0,false
setcursor 0,0
Sync
loop
psub DrawTree(index,XPos,Ypos)
ThisIMage=GameImage.Trees(Index)
drawimage ThisImage,Xpos+32,Ypos-GetImageHeight(ThisImage),true
EndPsub
Psub DrawDirtString(s$,xpos,ypos)
For lp =1 to Len(s$)
Index=mid(s$,lp)-asc("0")
ThisIMage =GameImage.Dirt(index)
if ThisImage
drawimage ThisImage,xpos,Ypos,true
endif
Xpos+=64
next
EndPsub
[/pbcode]
I wouldn't actually do it like that, but hey it's mock up.
Quote
80000000 for first animation seqence that i have set up then $80000001 fro the next and so on, thats works ok here
Just
or the animation index with the
PBMapAnim_Mask constant.
AnimatedTileValue = MyAnimIndex or PBMapAnim_Mask
PokeLevelTile Map,Level, Xpos,Ypos, AnimatedTileValue
Quote
but still need help with transparent blocks or water effect please
crack open the help, scroll down to images and you'll find
DrawAlphaImage
i have no idea what an ARGB format .png is. can you post an image so i can look at it?
is it a 32bit .png rather than an 8 bit .png?
yep, saving them as 32bit should do it.
hi all ,
was having a few problems but think i have sussed one out , so i have cleared this message and will get back asap
and continue
yep sussed one problem out , yesterday went so quick , got stuck for a while on one thing and other , no hair left now , anyway been stuck on the water effect for a ages , i was going to use tiles in the map , but as its at the front of screen and staying there all game , i tought i do the drawalphaimage but it slow the game right down , i then made an fx image to render the game gfx's to but it was not right , kept displaying wrong and was slow anyway , as im using the map commands not sure where the rendertoimage and rendertoscreen and drawimage commands go in program , or even thats the way to go
for the moment i have use a sprite , tried the drawalphasprite but same issues as well drawalphaimage , so proberly really simple , so if some one can help and maybe pop it into where it should go that will save loads of time for me
BlinkOk as you can see with demo , the background image bg2 needs some sky added to it or shall i just ad a blue to it , i have my image behind it at moment, think i need to lift it up a bit as well
also as you can see think i need a extra fence one before painting and one after , thought that watering some flowers as well , once watered they grow ,
will need creatures that fox has to avoid on platforms as well
the water is running fast as the moment will slow it down later
at the moment i have not added fox with brush animations or jump/land frames but will do
also the boulder needs to be bigger all round as the fox hovers over the right hand side of it as im using the checkmapimpact command
thanks BlinkOk
ps wanted to ad , i have used my first function command , as last
mick :)
ok all sounds cool mick.
looking at the demo i don't think you need transparency on the water. i think it looks ok as is.
if you go back to my fist post, i posted and update for the bg2 image that has a sky
no worries on the npc's and flowers. i'll get onto it
i'll fix the boulders as well.
i'll make something for the painting fences too.
using functions will revolutionize the way you program mick. you can start making things really modular and not have to worry about the entire program when solving simple problems. congratz
just a thought but if you make the tile editor fairly easy to use and understand you could post it and people from the forum could create levels for the game. first we need
to sort out all the game play, NPCs and tiles though.
ps: i attached a 32 bit water animation if you still wanna muck around with transparency and the bg2 image
Hi all
yep thanks blinkOk , i forgot about the new bg2 , yep that works fine
ok hopefully Kevin might get the water transparency done for me , must be straight forward ,
yes will try and make the map editor staright forward to use , at the moment using 2 level within map , main walking level ie platforms and other for backgrounds ie paint brush coins and main body of platforms so fox can walk in front of them
mick :)
try setting spritedrawmode to 4 and then spritealphalevel to 0.5 (for transparency).
i'm poking around the doco for tiles mapping atm. just trying to make the gfx fit into that model.
*EDIT* you're right! it's mind bendingly slow. let me tinker some more
hi all
Quote*EDIT* you're right! it's mind bendingly slow. let me tinker some more
yep i need to create and fx image the render to that then render to screen and draw that image , can easy do this normally , but with drawmaps and sprites and other commands i dont really understand even reading about them all day and trying demos in demo folder i cannot for the life of me get it right , spent all day on this , so had little time to do graphics conversion to my gfx map gfx's
then run into problems with my map editor its running so slow as i added more sprites at top of screen , i dont know why as i hace had 1000 sprites running on the platform game program bouncing all over the screen and it runs full speed , and 84 sprites on map editor as grind it to 13fps , yet it looks like i have done it the same as my game , anyway got a bout 30 mins to do this little demo , still gold blocks clouds and other small bits missing , its just a 3 screen size little demo , still have jump and water and other bits to muck bout with , no enimies yet either
so demo and map editor below
ps would be good to get map editor running full speed as i think i going to need 3 or 4 levels with a map to get every thing in , also going to be quite a long level , i know its rather basic , but thats all i could do im affraid !
mick :)
mick that is absolutely bloody fantastic! luv it
don't worry about the transparency it looks fine the way it is.
i might try to render it as a tile.
looking at the implementation of tile management it might be best to make EVERYTHING a tile (even the trees) what do you think?
ps: i dont see the tile editor
Hi all
Quoteps: i dont see the tile editor
its map editor right below the platform file ,
yeh its coming along , shame i wasted a day on the water and tring to see why map editor dont run full speed ,
yep i have put trees as a tile , so all tiles would save me time cutting and pasting
thanks for your efforts blinkOk
mick :)
couple questions;
1. is there a reason the tiles have a transparent color of black?
2. how do you overlay tiles like when a platform edge has another platform behind it?
Quotethen run into problems with my map editor its running so slow as i added more sprites at top of screen , i dont know why as i hace had 1000 sprites running on the platform game program bouncing all over the screen and it runs full speed
you're trying to rotate sprites with video memory images..
ie.
; load image directly into graphics cards video memory.
loadimage "feeler.bmp",1
then later on the sprites are set to 'rotated' rather than blitter mode (none rotated)
for a=1 to image_width*3
tiles(a).sprite=getfreesprite()
createsprite tiles(a).sprite
spritedrawmode tiles(a).sprite,2 ; Here you're telling the sprite engine to use the rotation when drawing this sprite
spritecollisionclass tiles(a).sprite,2
spritecollisionmode tiles(a).sprite,6
next a
Rotation (texture mapping) is implemented by CPU, it can't read video memory at anywhere the same speed as system memory (20->30 times slower). See -> Economizing Image Blitting (drawing!) (http://www.underwaredesign.com/forums/index.php?topic=1799.0)
hi all
Quoteis there a reason the tiles have a transparent colour of black
yes because im stupid , i left the MakeMapGFX MyMAP,main_tiles,64,64,image_width*3,rgb(255,255,255) as black as transparent , did not think of changing the rbg to 255,0,255
i have done so now , kinda skipped this somehow , no brains , lol
Quotehow do you overlay tiles like when a platform edge has another platform behind it?
i have 2 levels in the map at moment , they are mylevel3 this is forground tile screen and mylevel5 the background tile screen , v3.txt and v5.txt
if you load these in map editor , v3 or v5 you will see how i have done it , but think im going to need 3 or 4 levels in the end so fence can be in front of trees or other rocks as well etc
Quoteyou're trying to rotate sprites with video memory images..
derr , did not even know i did this , how many times did i read through program and did not even see it in the program,
yep i know that rotating video memory or blending images will slow program right down without using a fximage and even rendering to a fximage then render that image to screen
now i may run into problems if i want to rotate some sprite in the platform game ,
Kevin i did have a look at your Platform Game Movement Based on Ray Intersection but im affraid it looks beyond me , so i will stick to the way im doing it as im just about getting away with this
mick :)
ps here is the map editor running full speed now
haha , i can see what i should have done if i wanted to keep the spritedrawmode to rotated , after grabbing the images
getimage i must then preparefximage
now runs at full speed even when left as rotated , i have took the rotate mode out as not needed
this also works fine in the platform game if have the waves as rotated the program runs fine , but if i use spritedrawmode 4 alpha still very slow , looking at examples and reading about alpha draw mode
i know i have to render the backgrounds and map to a fx image then draw the wave sprites on top of that image the draw the fx image to screen , but its still painfully slow
so dont know what i am doing wrong , anyway as you say BlinkOK think the waves proberly look better as they are , but would be good to know how it should be done as in this game for future projects
ok last day off today then i have 5 days long shifts at work , so hopefully wont waste today
mick ;D
Hello Mick!
I had a look at your new platformer game-demo.
It is fantastic! Congratulations! :)
It works great and it is very funny! I hope you
find time to work further with that game.
Sigtrygg
Hi all
Yes thanks Sigtrygg , well mainly thanks to BlinkOk with he's superb graphics , the graphics here fit the game so well
well im trying my best to get this game running and playing as well as i can , but sure someone else could easy convert it to run even better , level design is going to be a big part of it i think
im trying to put in as much time as possible to do this game without the other half leaving me lol , oh and a bus hitting my car today did not help , had to that out
well to get the images overlayed as below pic, i will be using 4 levels within the map
level 1 " front level , platform , boulders, the platform the fox walks along"
level 2 " trees , this sit behind platform level"
level 3 " fence , sits behind both tree and platform levels
level 4 " rocks , ie mud part sits behind all levels , give the feeling that the mud backs and levels are full of mud etc"
think that will do it
mick :)
Hi all
BlinkOk , just trying bits and bobs , just wondering roughly how many screens long the game should be ? ,
so far main objectives are
#1 getting paint brush and painting fence
#2 getting watering can watering flowers
#3 collecting coins for points etc
#4 picking up carrots for points etc
maybe 1 or 2 more , ie collecting rubbish , dont know how i am going to that one at the moment , but i will try and pick it up as i go along , sorry could not resist ,
or cutting hedge or mowing grass , some thing along them lines
doing this while avoiding baddies ,
will try a few moving platforms as well if i can or suit game maybe ?
mick :)
ok that all sounds good.
so the general idea is it's messy and you have to clean it up.
moving platforms sounds good
ps: sorry bout the missus and the bus ;-)
Hi all
yep BlinkOk lol no worries but nice red marks on car , yep just some litter here and there , just something else to pick up ,
will try a moving platform tomorrow if i get time at work , but the next 3 days after im really tired down ,
today i did a little bit of tiding up and re-labeling of game so its a bit easier to follow ,
i have included a demo here of how the levels will be done ,
as you will see there are 4 levels to the map
you can use the level editor to edit your own , to load my levels just run editor and then at promp press y to load level , the levels are
platform , trees , mud , fences
and to save adjustments press space and then enter name and the enter , then just copy the file created to the folder that the platformerv2 folder
there are a few exceptions to where some platforms can go , so a little cheating on the platform level layout is required
Mick,
Looks & plays well, but why on earth edit and store the layers separately ? Doesn't seem very practical to me. What I would assume you'd do, is edit them in parallel ( have a layer toggle in the editor). It could handy to name the layers also, so when dumping the file to disc, just dump the Width, Height fields and then the name, then all the tiles in the first layer.. then all the tiles in the second layer etc. If a layers not in use, just set it's width/height to -1 or something so the loader can simply skip it.
This would allow the loader/saving to be smart about they're doing. If there's 5 layers say, you can just use levels from 1 to 5 as the layers. With say the middle layer being the game play layer. Although commonly there's a collision map layer, separate from the display layer. But you can probably get away with it. Since all the layers would line up, you can clip the backdrop blocks out of view when the foreground tile is solid.
better and better, well done micky4fun and BlinkOk
hi all
BlinkOk
had a little time to muck about with a moving platforms , here we have 4 moving in a circle , still a little tinkering to tighten it all up , but you get the gist , i know paintbrush move down while on platform , but going to use fox with paintbrush image so have no bothered to correct this
just wondering what u think , is worth having the platforms here and there or just stick as it is
Quotebut why on earth edit and store the layers separately ? Doesn't seem very practical to me. What I would assume you'd do, is edit them in parallel ( have a layer toggle in the editor).
just started the simple and quick way , will try and edit the map editor when i get some spare time as if i know how , so it loads and toggles the levels as you say , as yes seems the easy way to do layout of game ,
thanks ATLUS , using your 2d orbit snippit again lol
mick :)
ok no worries mick.
my daughter is in her netball grand final saturday (go sunbeams!). so that's me forked for the weekend as far as this is concerned.
the moving platforms is awesome. especially moving in circles. great job.
i played a demo of this (http://forums.tigsource.com/index.php?topic=27522.0) today so i am totally loaded with ides for power ups, enemies etc.
cya when i'm holding the champions trophy :-D
Hi all
yep no worries blinkOK ,im pretty busy at work these next few days anyway ,
well wish your daughter good luck saturday at netball hope that trophy comes he way,
mick :)
the girls were beaten 37-22.
my daughter had a very good game.
all round it was a great effort and a very good game to watch.
we'll be eating lollies and watching movies all day to commiserate i think
Hi all
Thats ashame , hope all or you was not to disapointed , still great achievement getting to final.
I played bunny land and its quite a good little game , i will try and get the map editor working as Kevin said with any spare time this weekend
but work becons at the moment ,
mick :)
ps , well done that it 20 mins , a bit messy so will tidy it up later , but multi level editor and one output file now done!
Great idea from Kevin , one that even i could manage without to much hassle !
hey micky4fun
this is starting to look really cool. i've never used animated tiles before. i learnt something new.
i am going to have to lift my game now, and release a just as cool demo.
blinkok is a natural at comming up with graphics.
looking forward to seeing your progress, stevmjon.
hi all
Quotethis is starting to look really cool. i've never used animated tiles before. i learnt something new.
i am going to have to lift my game now, and release a just as cool demo.
blinkok is a natural at comming up with graphics
yep thanks stevmjon its getting there , hope you get back into your platform game real soon , looking forward to seeing demo up on forum , well yet again ive been very lucky with blinkOk jumping on board , hes certainly very talented
well heres another little demo , still a few things to iron out in this demo , wont go to far as i will wait for blinkOk ideas powerups and baddies so i can get them in game , but gives a feel of the moving platforms and a few baddies about on grass , they cant kill you yet and you cant kill them either yet ,
ATLUS your 2d orbit code is controlling all platforms and baddies ,
mick ;D
snails! good idea mick. i did a dog and a hunter (he shoots). gotta get my finger out and get this stuff done today
Hi all
Quote. i did a dog and a hunter (he shoots). gotta get my finger out and get this stuff done today
sounds good to me , no rush , im still tinkering around with stuff anyway , got the 2 bugs in game sorted out tonight so all runs as it should , some of the enimies will run along bottom main walk way and fall in river once they come to it , maybe some mystery coins that change into steps to get other stuff , main thing now i think is the level layout once we have all the pieces to game ,
anyway , ile tinker about a bit for time being , all good fun
snails from treasure hunt game , they were getting bored there , lol , think i will return to that game later now i know a bit more about the maps and see if i can get it to control better ,
mick :)
dog & snail. workin on hunter. i have done the fences too
http://www.swfcabin.com/open/1348120049 (http://www.swfcabin.com/open/1348120049)
Hi all
dog and snail look great , love the snail , look forward to the rest , first class job
mick :)
Hi all
just starting to get the levels together , so i have kinda guessed a level at 10 screens across , going to try and put some kind of easy puzzles into the levels, heres the first i have only done 2 screens of the 10 screens so far and will continue this today , i have not put in my snails yet as will do that later when i get the snails , dog , gamekeeper off of BlinkOk as they are animated ,
but just to see if you think this is the way to go or not , so no prizes but find the brush to paint fences ,
wa so tempted to put fish jumping out of water as you cross , but how many times as that been done!
ahh maybe as they turn back to go into water then use them as a stepping stone to get to other side instead of bridge?
mick :)
micky4fun, nice work, i think needed add some obstacles.
Hi all
Quotei think needed add some obstacles.
yes will be adding dogs , gamekeeper , snails on grass platforms as well as maybe other stuff coming out of water or dropping from sky , trying to mix it up a bit so it aint all the same , hopefully maybe watering some flowers and other tasks ,
well had 2 mates over a few hours ago and they played it for aboy 30 mins each and they could not suss out were the paint brush is , so heres a big clue , try the circlar moving platforms , why do they change colour ? , dont think they played mario at all somehow lol
mick :)
here's the snail and dog. i changed the snail a little to conform with the style
if you like i can do just do the shell too so when he jumps on the snail it goes into it's shell (bit like mario and the turtles)
i'll do some jumping fish too
Hi all
Quoteif you like i can do just do the shell too so when he jumps on the snail it goes into it's shell (bit like mario and the turtles)
i'll do some jumping fish too
thanks for snail and dog i will get them into the game tomorrow as its late here ,
yep snail could go off in shell like turtles do once killed in mario . at the moment i am just over half way on level one layout , as it pans out you get some blocks in sky like i had early demo , wonder if keeping the moving platforms in is ok ? and if so maybe they should look a little different to still platform blocks ?
ok thanks again blinkOk
back soon
mick :)
ok i'll have a look at a platform with wings or something like that
Hi all
ok thats great , will break it up a bit , ok long day , will get into it again tomorrow
thanks mick :)
had a shark lying around so i did a quick animation. this will prolly change to a fish or something coz it's out of scale with the other characters
for reference;
demo (http://www.swfcabin.com/open/1348357001)
ps: and a shell
pps: changed the shark to a fish (repeat the first two frames while jumping to wiggle tail, then rotate and fall)
ppps: i did a flying box but maybe it might be better if we just did the flapping wing. what do you think?
just the wings
Hi all
ok thanks BlinkOk , thought i got rid of a problem that arouse when collecting coins or carrots , and then you suddenly changed direction , the stars would come up in wrong place somethimes and also empty carrot patch would appear in wrong place , but i think i have sorted that out for final time now , did a little editing to level one map , and now starting to put in snail and dog , so will get on with that ,
going to have to think of a name for game , as jumping jack flash dont seem right now , lol , ive been calling it for fox's sake , lol
mick :)
for fox's sake is awesome. i luv it!
Hi all
go with that then , haha
ok got a few snails in tonight , carry on tomorrow
mick :)
for fox's sake micky!
(http://i93.photobucket.com/albums/l75/blinkok/splash_zps708fda7d.png)
it would be super awesome if you clicked play and the platform disappeared and he fell down to the next platform and that was the start of the game.
it's prolly too much trouble though. i should have had his tail waving in the wind but i'm forkin lazy ;-)
do you want me to send a screen shot or do you want the bits?
Hi all
looks good BlinkOk ,
i think i will just need play , for foxs sake i will overlay them ,
micky4fun , kazoowee , playbasic av them in mud , i will make tiles out of them i think
yep i will re-do level as it wont take to long and have it as you said so play platform falls in water and sinks and fox falls to next platform and starts game
mick :)
ok here you go. let me know if you need the bigger/smaller or anything else
Hi all
well got a reasonable amount of work in today , heres where i am at the moment , still wondering how long the level should be , this one kinda stops after 4/5 screens , thought this maybe long enough to get all you bonus updates how you did etc , then carry on with next part of that level
you still cannot ket killed or kill anything yet ,
BlinkOk thanks for latest gfx's , not got dog or clouds in yet , wonder if you have anything better for ? box , or other idea for that , just so you know where there might be somthing to get
mick :)
oh yeh space to start
ps small video here
http://youtu.be/64CLa8KCawQ
it looks brilliant mick. excellent work. i'll do a box.
do you want flowers and a watering can?
hi all
hi BlinkOk , yep have a box , flowers and watering can , will break it up a bit more , i did multicolour stars for fence , so maybe could do a fence once painted has a few coloured spots on it
mick :)
this is the fence and fiddling with bits here and there
i'm sorry i've given you stuff in such and awkward format.
must be a pain to chop it up and format it.
i'll try and make it easier from here on
ps: there's an "open" chest image in the 217o.png image you can use (don't know why that isn't in the 217.png image)
pps: updated a little (better fish). there are two frames for going up and two frames for going down
The new version is excellent, only a few niggles, I'd soften the attachment between the camera and the player just a little bit, so it doesn't feel so linear. The only things I'm a bit worried about the character placement and controller stuff has hard coded decisions built into it.
What I'm talking about are loops like this.
[pbcode]
;------------------------------------- enimies controller -------------------------------------------
for lp=1 to NumberofEnimies
dogs(lp).thisangle#=dogs(lp).Angle#
dogs(lp).orbitx#=dogs(lp).mx#+(Cos(dogs(lp).thisangle#)*dogs(lp).RadiusX)
dogs(lp).orbity#=dogs(lp).my#+(Sin(dogs(lp).thisangle#)*dogs(lp).RadiusY)
positionsprite dogs(lp).sprite,dogs(lp).orbitx#,dogs(lp).orbity#
dogs(lp).Angle#=WrapAngle(dogs(lp).Angle#,dogs(lp).spd_rotate#)
if lp<7 ; less than 7 are snails
if dogs(lp).angle#<180 then dogs(lp).increase=0
if dogs(lp).angle#>180 then dogs(lp).increase=10
dogs(lp).animation#=dogs(lp).animation#+0.20
if dogs(lp).animation#>9 then dogs(lp).animation#=0
endif
if lp>6; more that 6 are fish
if dogs(lp).angle#>240
dogs(lp).animation#=dogs(lp).animation#+0.25
if dogs(lp).animation#>9 then dogs(lp).animation#=9
endif
if dogs(lp).angle#<90
dogs(lp).animation#=dogs(lp).animation#-0.25
if dogs(lp).animation#<0 then dogs(lp).animation#=0
endif
endif
spriteimage dogs(lp).sprite,dogs(lp).image+dogs(lp).increase+dogs(lp).animation#
next lp
[/pbcode]
Here's we've a loop that's assuming the position in the array as they character type. So every time we change the characters in the level we've got to alter this code. Which make more maintenance for us and is ultimately error prone.
A much better and easier to maintain solution is to add 'controller type' or "ai type' field to the character structure.
[pbcode]
type plats
CharacterType
thisangle#
animation#
increase
image
angle#
orbitx#
orbity#
spd_rotate#
radiusx
radiusy
sprite
mx#,my#
endtype
[/pbcode]
When we create the character (fill in it's structure) and set it's character type. Let say 1 is a dog and 2 is the snail, 3 could be a chicken, 4 could be horse etc.. So each character type has it's own unique controller type value.
so when we process the characters in the dogs() array, we're looking at each items characterType field to determine what controller code to use. Now it doesn't matter, how many are in the array, what order they're in. or if any have died..
Like this.
[pbcode]
;------------------------------------- enimies controller -------------------------------------------
for lp=1 to Getarrayelements(Dogs())
; check if this character even exists.. If it's zero, it doesn't, so skip it
if Dogs(lp)
; Select What controller code we should run (or character type this thing is)
Select Dogs(lp).CharacterType
; ------------------------------
case 1 ; DOG
; ------------------------------
; if we stored a 1 in the CharacterType field. then it'll run this code
; and when it's done, jump down to the END SELECT statement
dogs(lp).thisangle#=dogs(lp).Angle#
dogs(lp).orbitx#=dogs(lp).mx#+(Cos(dogs(lp).thisangle#)*dogs(lp).RadiusX)
dogs(lp).orbity#=dogs(lp).my#+(Sin(dogs(lp).thisangle#)*dogs(lp).RadiusY)
positionsprite dogs(lp).sprite,dogs(lp).orbitx#,dogs(lp).orbity#
dogs(lp).Angle#=WrapAngle(dogs(lp).Angle#,dogs(lp).spd_rotate#)
if dogs(lp).angle#<180 then dogs(lp).increase=0
if dogs(lp).angle#>180 then dogs(lp).increase=10
dogs(lp).animation#=dogs(lp).animation#+0.20
if dogs(lp).animation#>9 then dogs(lp).animation#=0
spriteimage dogs(lp).sprite,dogs(lp).image+dogs(lp).increase+dogs(lp).animation#
; ------------------------------
case 2 ; Snail
; ------------------------------
dogs(lp).thisangle#=dogs(lp).Angle#
dogs(lp).orbitx#=dogs(lp).mx#+(Cos(dogs(lp).thisangle#)*dogs(lp).RadiusX)
dogs(lp).orbity#=dogs(lp).my#+(Sin(dogs(lp).thisangle#)*dogs(lp).RadiusY)
positionsprite dogs(lp).sprite,dogs(lp).orbitx#,dogs(lp).orbity#
dogs(lp).Angle#=WrapAngle(dogs(lp).Angle#,dogs(lp).spd_rotate#)
if dogs(lp).angle#>240
dogs(lp).animation#=dogs(lp).animation#+0.25
if dogs(lp).animation#>9 then dogs(lp).animation#=9
endif
if dogs(lp).angle#<90
dogs(lp).animation#=dogs(lp).animation#-0.25
if dogs(lp).animation#<0 then dogs(lp).animation#=0
endif
endif
spriteimage dogs(lp).sprite,dogs(lp).image+dogs(lp).increase+dogs(lp).animation#
; ------------------------------
case 3 ; Horse or
; ------------------------------
; ------------------------------
case 4 ; some other character type
; ------------------------------
EndSelect
endif
next lp
[/pbcode]
In this version we're make the code more generic and change resistant. It no longer matters what order the characters are created in, if the character exists, and we can handle every different unique character type with it's only custom controller code.
To get rid of the character type numbers and replace them names we can define a set of constants. This helps in the readability of the program dramatically and it means we can add and change the order of the characters whenever we like.
[pbcode]
Constant CharacterType_Dog =1
Constant CharacterType_Snail=2
Constant CharacterType_Horse=3
Constant CharacterType_SomeOtherThing=4
etc
etc
[/pbcode]
Hello Mick!
Fantastic looking game! Great animations!
You have a hand for atmosphere. I love the snails!
I wish I could handle such map and character
animations. But I hope to learn further. That's
fun for me, too.
Greetings
Sigtrygg
Hi all
Thanks for advice on handling enimies Kevin , now implimented this into game , apart from chickens and horse lol , chickens maybe ?, anyway works a treat , also have added you now can kill enimies when you jump or fall on them , as you can see still loads and loads to do , will do bit and bobs as i go but trying to spend as much time as i can on it
thanks BlinkOk for latets gfx's , they seem to work fine , will let you know what else is needed , you did say game keeper with gun up to you ? and the watering can and flowers , they spring up when watered ?
QuoteI love the snails!
yep Sigtrygg , took me ages to draw these , yeh cousre it did , yep BlinkOk made a great job on the snails my favourites to
QuoteI wish I could handle such map and character
animations.
not a great deal to what i have done really , maybe better ways of doing it , but seems to work in this game , just trial and error you will soon suss it out
mick :)
Quoteyou did say game keeper with gun up to you ? and the watering can and flowers , they spring up when watered ?
yeah i'll get those done today
ps: flowers and watering can.
pps: hunter dude
Hi all
Thanks for new stuff BlinkOk , not got them in game yet , just wanted to post were i am at today , after a little tiding up in code and putting Kevins ideas in code as well ,
just wondering if all the enimies are ok all being purple , as i thought they seem to blend together a bit , what do you think ?
also you can just do the images the size they are if you want , ie dog takes up 64x64 nearly double , this proberly dont matter but may run it quicker on old machine , though it flys on mine at 486 fps
errm bad news if i use watering can may need for animation of him walking with it ? , wont do anymore pick ups that he uses , wont matter with key etc , could have little hud on screen for that
will do the chest opens to reveal paint brush , that not done yet ,
only got a few hours in today,
you can now kill the 15 enimies on screen , but they cannot kill you , proberly have a energy bar at top of screen so when you get touched by enimies it goes down , or something like that
ok thats it i think ,
mick :)
ok mick i'll have a look at the colours and resize the sprites.
Version 9 plays really well, found myself playing through looking for stuff to jump on. Your updated character controller code is much, much better ! - The other part that's worth cleaning up when looking forward is the character creation method.
[pbcode]
NumberofENIMIES=15
dim dogs as plats list
for a=1 to numberofenimies
dogs = new plats
dogs.sprite=getfreesprite()
createsprite dogs.sprite
spriteimage dogs.sprite,401
centerspritehandle dogs.sprite
spritecollisionclass dogs.sprite,4
spritecollisionmode dogs.sprite,6
if a=1 then dogs.radiusy=0:dogs.radiusx=140:dogs.my=685:dogs.mx=560:dogs.spd_rotate#=0.3:dogs.angle#=0:dogs.image=401:dogs.object=chr_snail
if a=2 then dogs.radiusy=0:dogs.radiusx=140:dogs.my=685:dogs.mx=560:dogs.spd_rotate#=0.3:dogs.angle#=180:dogs.image=401:dogs.object=chr_snail
if a=3 then dogs.radiusy=0:dogs.radiusx=100:dogs.my=621:dogs.mx=317:dogs.spd_rotate#=0.4:dogs.angle#=90:dogs.image=401:dogs.object=chr_snail
if a=4 then dogs.radiusy=0:dogs.radiusx=120:dogs.my=109:dogs.mx=225:dogs.spd_rotate#=0.4:dogs.angle#=180:dogs.image=401:dogs.object=chr_snail
if a=5 then dogs.radiusy=0:dogs.radiusx=200:dogs.my=685:dogs.mx=1230:dogs.spd_rotate#=0.4:dogs.angle#=180:dogs.image=401:dogs.object=chr_snail
if a=6 then dogs.radiusy=0:dogs.radiusx=130:dogs.my=557:dogs.mx=1695:dogs.spd_rotate#=0.3:dogs.angle#=180:dogs.image=401:dogs.object=chr_snail
if a=7 then dogs.radiusy=170:dogs.radiusx=0:dogs.my=800:dogs.mx=833:dogs.spd_rotate#=1.5:dogs.angle#=180:dogs.image=421:dogs.object=chr_fish
if a=8 then dogs.radiusy=170:dogs.radiusx=0:dogs.my=800:dogs.mx=898:dogs.spd_rotate#=1.5:dogs.angle#=300:dogs.image=421:dogs.object=chr_fish
if a=9 then dogs.radiusy=220:dogs.radiusx=0:dogs.my=800:dogs.mx=3080:dogs.spd_rotate#=1.5:dogs.angle#=300:dogs.image=421:dogs.object=chr_fish
if a=10 then dogs.radiusy=220:dogs.radiusx=0:dogs.my=800:dogs.mx=3200:dogs.spd_rotate#=1.5:dogs.angle#=180:dogs.image=421:dogs.object=chr_fish
if a=11 then dogs.radiusy=0:dogs.radiusx=200:dogs.my=407:dogs.mx=1984:dogs.spd_rotate#=0.8:dogs.angle#=180:dogs.image=431:dogs.object=chr_dog
if a=12 then dogs.radiusy=0:dogs.radiusx=280:dogs.my=662:dogs.mx=2140:dogs.spd_rotate#=0.6:dogs.angle#=270:dogs.image=431:dogs.object=chr_dog
if a=13 then dogs.radiusy=0:dogs.radiusx=280:dogs.my=662:dogs.mx=2140:dogs.spd_rotate#=0.6:dogs.angle#=90:dogs.image=431:dogs.object=chr_dog
if a=14 then dogs.radiusy=0:dogs.radiusx=280:dogs.my=662:dogs.mx=2140:dogs.spd_rotate#=0.6:dogs.angle#=180:dogs.image=431:dogs.object=chr_dog
if a=15 then dogs.radiusy=0:dogs.radiusx=140:dogs.my=621:dogs.mx=2240:dogs.spd_rotate#=0.5:dogs.angle#=180:dogs.image=401:dogs.object=chr_snail
next a
[/pbcode]
This works, BUT, as the game grows and more characters are added, or changes are required etc etc, it means we're back man handling the codes on a one to basis. If we have a 100 characters in the level, and need to change something.. We're making 100 changes.. Not ideal.. But really this is really a situation to wrap up the 'creation' process for a each different character type the game has into separate functions.
We can give the function/pubs meaningful name and only pass in the 'variables' this character type needs. Anything that's know is preset inside the function. So it's character type, it's sprite, perhaps it's score values in the future and whatever else..
(puesdo code mainly)
[pbcode]
; You can do this with a generic 'add character' routine where you pass all the characters fields into one function..
; but it's generally easier to set up the function/sub up you only pass it the parameter required. So any time you
; every want to add this type of character, you just call the function.
Psub Add_Snail(Xpos,Ypos,RAdiusX,Speed#,Angle#)
; Add to our list called dogs
dogs = new plats
; Set it character type/class
dogs.object=chr_snail
; since all the sprites have the same properties, i've wrapped up the sprite creation code into a generic
; so any time we need a new game sprite, we call it and get a sprite set up the way we require every time.
Image=421
dogs.image=Image
Dogs.Sprite= MakeCharacterSprite(IMage)
dogs.mx=Xpos
dogs.my=Ypos
dogs.radiusx=RAdiusX
; dogs.radiusy=0 ; we when create a type, all the fields in the type are zero, we don't actually need to set to zero explicitly
dogs.spd_rotate#=Speed#
dogs.angle#=Angle#
EndPsub
Psub Add_Fish(Xpos,Ypos,RAdiusX,RadiusY,Speed#)
; Add to our list called dogs
dogs = new plats
dogs.object=chr_Fish
Image=401
dogs.image=Image
Dogs.Sprite= MakeCharacterSprite(IMage)
dogs.mx=Xpos
dogs.my=Ypos
dogs.radiusX=RAdiusX
dogs.radiusY=RAdiusX
dogs.spd_rotate#=Speed#
dogs.Angle=Angle#
EndPsub
Psub MakeCharacterSprite(IMage)
ThisSprite=getfreesprite()
createsprite ThisSprite
spriteimage ThisSprite,IMage
centerspritehandle ThisSprite
spritecollisionclass ThisSprite,4
spritecollisionmode ThisSprite,6
EndPSub ThisSprite
[/pbcode]
Anyway, what this means is we can create our characters more like this.
[pbcode]
; so this
; if a=1 then dogs.radiusy=0:dogs.radiusx=140:dogs.my=685:dogs.mx=560:dogs.spd_rotate#=0.3:dogs.angle#=0:dogs.image=401:dogs.object=chr_snail
;adding this snail
Add_Snail(560,685,120,0.3,0)
etc etc
Add_Snail(560,685,120,0.3,0)
Add_Snail(560,685,120,0.3,180)
[/pbcode]
Not only to we get less code to maintain, what we're actually doing is creating our own 'game interface'. Which is nothing more that hiding the repe3ative code inside functions/psubs. If we cast our minds forward to externalizing the character data to disk, then you only have to store the unique 'fields' of each character type. So in the snails case that's it's X,Y, RadiusX, Speed# and Angle# .
micky4fun and blinkok this game is better and better! you guys is amazing!
Hi All
Thanks for code snippet again Kevin , yes i see what you mean , make it a lot easier to drop them in , if i was cleaver enough i know it could be done in a map editor , but i might have a stab at that if i get a spare few hours see how i go ,
BlinkOk , i have cropped dog images so they are ok , just added clouds , kevins snippets , very slight level change , and few other bits today , so will crack on again in spare time tomorrow .
Thanks ATLAS , well looks a million times better with BlinkOks gfx's and as said before your orbit snippet has come in very handy again for me , used it in egg selector as well
dont just work with circles
mick :)
hey micky4fun
this is entertaining to play. i love the character movements and animation, especially the dog. i like how blinok made it bounce as it walks.
i thought for something to add is a fence counter on screen, so the player knows how many are remaining in the level that need painting.
keep up the good work, as this is really growing.
stevmjon
QuoteThanks for code snippet again Kevin , yes i see what you mean , make it a lot easier to drop them in , if i was cleaver enough i know it could be done in a map editor , but i might have a stab at that if i get a spare few hours see how i go
You've got all the info, it's a matter of tacking it all together. What i'd do in the editor is split the process into two modes. Mode 1 is regular map editing mode, nothing changes. Mode 2 would be character placement mode.
When in placement mode, the level maker can still scrolling around the map but this time we're dropping 'character' markers, rather than drawing blocks on the map. You could load in a single frame (or all frames) of each character type and display them across the top of the map, it'd be just like the block selection.
Depending upon how the character AI works which I think it's mainly circle based. So when you drop a character into the world, you'd be setting it's base/axis position. So we still need to edit it's radius and speed. The dropper could work out the radius by counting the blocks to Left and right under this position. Or you can could manually size a circle. Having it work out the radius from the map is prolly the better idea, given how many characters will need to be placed. Still much easier to programming them hand.
What i would most like do, is include various character editing modes. So there could be a simple drop mode, where you select the dude from the character palette at the top, then splodge them where ever you want around the world. There would also need to be a edit character mode. In this mode, the program wants you to select the character (by clicking on it), once selected, it might show a circle for it's movement path, or display some text message with the speed or whatever on screen in front of you. To alter the values you might just have some keys, or use the mouse wheel/buttons whatever.
Anyway, as for exporting the data. We just save a file with important fields for each character type. So the editor has the characters in an array/list whatever, and we just run through that list to save them out. Much much like changes you've made to character handler.
The character file just needs the character type, and this character position/radius speed whatever. Bellow we have a mock up of how the data is stored, an example saver and loader routine for the 'game' using the wrapped character creation functions. I would make create function for everything. I'd then simply split this code into a separate file and have both the editor and game use the same file.
[pbcode]
Constant CharacterType_ENDOFCHARACTERS =-1
Constant CharacterType_Player =0
Constant CharacterType_Dog =1
Constant CharacterType_Snail =2
Type CharacterInfo
MyType
X#,Y# ; position
RadiusX#,RadiusY#
Speed#
EndType
Dim Character(0) as CharacterInfo
; -----------------------------------------------------------------------
; -----------------------------------------------------------------------
; -----------------------------------------------------------------------
; Save Charcters function in the EDITOR
; -----------------------------------------------------------------------
; -----------------------------------------------------------------------
; -----------------------------------------------------------------------
Function SaveCharacters(Filename$)
Fh=WriteNewFile(filename$)
For lp=1 to GetArrayElements(Character())
if Character(lp)
; Write the character type to the file. So when we read this back, we know what type the next section of data is.
WriteInt fh, Character(lp).MyType
Select Character(lp).MyType
case CharacterType_PLayer
WriteFloat fh,Character(lp).X#
WriteFloat fh,Character(lp).Y#
; Starting position plus whatever else it needs to know
case CharacterType_Dog
; write floats, if the fields are floats and integer when they're integers
WriteFloat fh,Character(lp).X#
WriteFloat fh,Character(lp).Y#
WriteFloat fh,Character(lp).RadiusX#
WriteFloat fh,Character(lp).Speed#
case CharacterType_Snail
WriteFloat fh,Character(lp).X#
WriteFloat fh,Character(lp).Y#
WriteFloat fh,Character(lp).RadiusX#
WriteFloat fh,Character(lp).Speed#
EndSelect
endif
next
; put the end of characters marketer at the end of the file, you could also
; just use the files length.
writeint fh,CharacterType_ENDOFCHARACTERS
closefile fh
EndFunction
; -----------------------------------------------------------------------
; -----------------------------------------------------------------------
; -----------------------------------------------------------------------
; Load Characters function which would go in the game.
; -----------------------------------------------------------------------
; -----------------------------------------------------------------------
; -----------------------------------------------------------------------
Function LoadCharacters(Filename$)
Fh=readNewFile(filename$)
repeat
CharacterType=ReadInt(fh)
Select CharacterType
case CharacterType_PLayer
x#=Readfloat(fh)
y#=Readfloat(fh)
// wrap all the player initialization stuff upon
Position_player(X#,y#)
case CharacterType_Dog
; write floats, if the fields are floats and integer when they're integers
x# =Readfloat(fh)
y# =Readfloat(fh)
RadiusX# =Readfloat(fh)
Speed# =Readfloat(fh)
; now we just call our wrapped add dog function.
Add_Dog(x#,y#,RAdiusX#,Speed#)
case CharacterType_Snail
; write floats, if the fields are floats and integer when they're integers
x# =Readfloat(fh)
y# =Readfloat(fh)
RadiusX# =Readfloat(fh)
Speed# =Readfloat(fh)
; now we just call our wrapped add snail function.
Add_Snail(x#,y#,RAdiusX#,Speed#)
EndSelect
until CharacterType=CharacterType_ENDOFCHARACTERS
closefile fh
EndFunction
[/pbcode]
Hi all
thanks Kevin , for advice and mock up , i will give it a whirl when i have a few hours spare , i did get an hour or so but really kept on tring a few things out in game ,
Hi BlinkOk , i have gone with this idea for getting brush , hope that it looks ok , got clouds and larger fish in , but not done all ani frames yet on those , will use both fish i think , only kill larger ones on way down i think , that bit not done eithet yet , tried a few things with water as it would run different depending which way you ran ,
thanks stevmjon , yep was going to do a way of counting fences say 100 per level and 100 coins or there abouts so you know theres some left , yep BlinkOk keeps suprizing us with all the good gfx's that for sure
back soon
mick :)
heres an uptodate version ,
Mick has an update on the previous page!!
graphics update! coloured NPC's;
(http://i93.photobucket.com/albums/l75/blinkok/screen-2.png)
animated (keep an eye on that dog! he's nasty) (http://www.swfcabin.com/open/1348878114)
i'm thinking this is everything except foxy with the watering can.
Hi all
Thanks BlinkOk , good idea for dog looks fantastic , brilliant gfx's all round they dont get better than this :),
Quotei'm thinking this is everything except foxy with the watering can.
yep should be it i think for this level , just the other 49 to go , hahah
yes think thats enough to get game done , maybe some score gfx's and life bar maybe , as 1 hit and dead i think seems harsh
ok i have already put new gfx's for enimies in game , also enimies change speed every end turn , and some staggered end turns as well
will crack on now and get deeper into game , and post when something is ready
mick :)
Looking great, only thing you may wanna add is water splashing when you or the fish go in/out of the water...
Excellent work Mick, lots of nice touches. The way you're going this might well turn to be one of the best games written in PB...
QuoteLooking great, only thing you may wanna add is water splashing when you or the fish go in/out of the water...
yeah. there are a few areas where we could add little touches like that; water splashing, paint splashing etc
hey mick do you think you could make the snail like the turtles in mario? where you stomp on the snail and then push the shell to knock other enemies off
i'm thinking i might do an end boss as well. maybe a huge bear. are you up for that?
ps: hud stuff
(http://i93.photobucket.com/albums/l75/blinkok/hud.png)
Hi all
OldNESjunkie , thanks for comments , yep could drop them in at some stage , all adds to the feel of the game .
Yep not going to bad at the moment Kevin , its kinda getting there , but still early doors at the moment , lucky enough BlinkOk is about to help with great gfx's, as i said theres no real rush for this so got time to muck about with a few things/ideas to the best of my ability
some take a lot longer for me to suss out than others and some once done are crap , lol , so waste time on nothing , but all good fun
Ok BlinkOk thanks for Hud , yep will try snail shell as in mario turtle , will do it so only kills enimies that are visible in camera then delete it
i dont mind the big boss thing as long as its fairly simple to do , how to kill him , what does he do etc
ok plugged away a bit again today but will post update when more done
mick :)
Hi all
Quotehey mick do you think you could make the snail like the turtles in mario? where you stomp on the snail and then push the shell to knock other enemies off
a bit like this BlinkOk , its not quite right yet ran out of time , but depending on how far to one side of shell it will go in that direction , also will knock off others it hits
get a bit of time tomorrow to perfect it and add other stuff , gamekeeper hud etc , if you have an idea for your end of level boss in what happens or how you kill him etc ?
mick :)
lookin very good mick. i think the direction control might need a bit of work (sometimes i hit it on the left and it goes to the left rather than the right) but the basic idea is working great.
just an idea; i thought the dog would sniff about until the fox was on the same platform. then the dog goes all crazy chasing directly after the fox.
i'm running the boss stuff around in my head at the moment. here's is what i have so far. (a very rough mockup)
(http://i93.photobucket.com/albums/l75/blinkok/bear1.png)
the bear would wave his arms around, maybe slapping his paw down on the platforms.
snails are dropped from the pipe onto the top platform.
foxy has to stomp on the snails and the shoot them onto the head of the bear.
he's in danger on the top platform from the snails and also from the bear on the lower platforms.
he's also buggered if he falls off a platform
most of the bear stuff would be frame animated animated i think, maybe a little image rotation/movement or something like that.
what do you think?
ps: i made some crumbling platforms (http://www.swfcabin.com/open/1349049491) too if you want
pps: made it a little easier to implement
Hi all
Ok BlinkOk , yep boss seems fine as long as its not to much maths stuff for me to handle , he could spit out food or something from hes mouth at different angles as well maybe
as there maybe more levels the bear would av to vary a bit ?
here is the shell thing done and the dogs that walk then speed up when you are near and facing dog
is this roughly as we are going to have it ?
will now ad hud , coins , watering can flowers and extend level , maybe fight boss after 2 or 3 normal levels , eg level1 pt1 pt2 pt3 then boss ?
mick :)
Mick,
Version 11 is excellent! Really like the jump on the snails/kick shells mechanic and the searching dogs is nice touch also..
Quotehe could spit out food or something from hes mouth at different angles as well maybe
as there maybe more levels the bear would av to vary a bit ?
cool. sounds good
Quoteis this roughly as we are going to have it ?
it's just about right. i would have the dog go into attack mode and stay in attack mode going directly toward the fox until he kills him or until the fox gets off the platform.
this means the player will have to deal with the dog differently than the snail. so each enemy will require a different approach from the player. right now i think it's all
a bit too easy (maybe i've been playing it too long though)
Quotemaybe fight boss after 2 or 3 normal levels , eg level1 pt1 pt2 pt3 then boss
yes
the snail is absolutely spot on! i shot a snail there and it cleaned up 3 or 4 other enemies on 2 or 3 different platforms. very nice work
Hi all
Thanks Kevin , its plodding along , all mainly to BlinkOk's gfx,s and input , wont rush it though just taking my time ,
Ok blinkOk will do dog as you sujjested , sound good to me , yep does seem on the easy side , but you cant get killed yet and maybe just 2 /3/4 hits and you dead might make it a lot harder
boss , could have bear banging his stomach and then something comes out of mouth , or he throughs something at you , ? picks up something ?
ile let you muck about a bit with that
mick :)
this is the bear so far. i think it can all be done with frame animations. we my have to flip them for right left sides though.
(http://i93.photobucket.com/albums/l75/blinkok/bear.png)
Animated swipe (http://www.swfcabin.com/open/1349219854)
the swipe animation is 10 frames. you may have to re-position it every frame.
you'll prolly have 4 or 5 of these. one for each platform level. they can be flipped for either side of the bear.
the head will have a 8-10 frame animation moving sie to ide as well.
is this approach ok?
Hi all
yep BlinkOk that looks fine to me , av it so the fox can jump over hes arm to get out of way , or jump to another platform
mick :)
Quotethe fox can jump over hes arm to get out of way , or jump to another platform
yeah the fox could jump over the bears arm (i might make it swipe back and forth too). i added heaps of jumping fish to the bottom platforms (http://swfcabin.com/open/1349244515) so the bear will swipe the top 2 layers of platforms
the rest will be fish. the idea being that the fox cannot stay anywhere for long
ps: i have no idea why that .swf animation is so small
Hi all
yep that sounds fine , fish will make it harder ,
Quoteps: i have no idea why that .swf animation is so small
lol so small on mine i cant see it , i have tried link on 3 pc's all have latest flash on them , but will no gfx's at all
mick :)
would it be a big pain in the arse to make a layer that goes IN FRONT of the player (fox)?
it'd be about as hard as setting the capture depth. CaptureDepth, in other words trivial.
yeah but has mick implemented it that way? i thought he was using levels to display the various layers
yep, it's camera based.
hi all
Quotewould it be a big pain in the arse to make a layer that goes IN FRONT of the player (fox)?
no thats ok , reason i have not expanded level to far yet,
Quoteit'd be about as hard as setting the capture depth. CaptureDepth
ahh thats handy , did not see this command
ok well spent a day or two mucking about with dog chasing fox thing , i tried so many ways of doing it and all looked pretty rubbish , so i left it this simple way as it was one of the better ones , what do you think will this way do ?
also may need a little advice from Kevin , i was going to do say one level split into 3 , then boss
so about 5 screens per level so i can get in 100 coins , 100 fence pieces without cramping them in to mush ,
now which way should i go , do a level at 15 screens plus boss , of just do them all seperate at 5 each then reload part 2 , 3 etc ?
also at the moment fox dies and goes back to begining , now once level is complete if was thing of doing what they did in mario , the black circle thing where it starts big and goes right in to where mario is and then they switch level and open black circle up again , whould this be ok ? or something else , ?
right just incase this seems ok , is there a easy way of doing this circle thing ?
ok thats about it , heres the dog chasing fox thing
mick :)
Quote
i was going to do say one level split into 3 , then boss
so about 5 screens per level so i can get in 100 coins , 100 fence pieces without cramping them in to mush ,
now which way should i go , do a level at 15 screens plus boss , of just do them all seperate at 5 each then reload part 2 , 3 etc ?
I don't think it'd really matter for the block data, as you can create the 'world' as one big long level (of how many layers it has), then load this all data into memory at the start of the game or start of a new world.
Now when the player goes to start World #1, Level #1, you could copy the 'rect' of blocks into the display levels.. and your done. To make this simpler, i'd add a marker chunk to the block data (in the header). So you can tag the start (left hard block) of each level. Assuming they're stored left to right in the editor..
level 1 within this world will no doubt start at column 0, level 2 might start at column 250 from the left (i've no idea), level 3 might start at 623 etc etc. So levels can be as short/wide as they need be. There's no point externalizing the game data, only to hard coding this stuff into the program.
The editor could use the 'level markers' to tag dropped characters as belonging to each level. So if you add entity creation to the editor, which personally is a must if you want to have a more than 3 levels. Which i think people will be expecting.
Quote
also at the moment fox dies and goes back to begining , now once level is complete if was thing of doing what they did in mario , the black circle thing where it starts big and goes right in to where mario is and then they switch level and open black circle up again , whould this be ok ? or something else , ?
There's a few ways that come to mind, in the Missile Attack & TwinTrix (from memory) uses shape to create such an effect. You plot a circle around the player using Cos()/Sin() (ie. polar coordinates) Then link this these coordinates as edges in the shape. To invert you add one final edge, that's off the screen.
Could do the same thing with TRI/ GrouaudTri/TextureTri, just by plotting to two circles (inner & outter) at say 10 degree intervals, then connect the coordinates.
[pbcode]
AngleStep#=10
For angle#=0 to 360 step AngleStep#
InnerX#=CenterX#+Cos(Angle#)*InnerRadius
InnerY#=CenterY#+Sin(Angle#)*InnerRadius
OutterX#=CenterX#+Cos(Angle#)*OutterRadius
OutterY#=CenterY#+Sin(Angle#)*OutterRadius
etc
next
[/pbcode]
Polygon Ring (http://www.underwaredesign.com/forums/index.php?topic=3929.0)
Also, rather than manually drawing font characters, spent a minutes and make a little conversion program that runs through the characters, make a bitmap font from them and then saves them. once save you can then just load the crf and use the Print /Text commands to draw stuff.
conversion code..
[pbcode]
path$="C:\MicksGames\platform12\gfx\hud\"
; load the font frames into image memory
For lp =1 to 11
LoadFXIMage path$+"FOnt"+Digits$(lp,4)+".png",lp
next
; get the size of the first frame/character
Width =GetImageWidth(1)
Height=GetImageHeight(1)
; -------------------------------------
; Mask colour our images are using
; -------------------------------------
MaskColour = $00ff00ff
; -------------------------------------
; Create Bitmap front from images (FX formated)
; -------------------------------------
CreateBitmapFont 2,Width,Height,4
fontmaskcolour 2,MaskColour
TempImage=NewImage(width,Height,2)
chrlist$="1234567890x"
For lp=1 to 11
RenderToImage TempImage
; clear our temp image..
Cls MaskColour
drawimage lp,0,0,false
Thischr=Mid(chrlist$,lp)
GetFontChr 2,ThisChr,0,0
next
; set the widht of the X characterso it's little thinner
FontChrWidth 2,asc("x"),Width*0.75
rendertoscreen
; demo this mini font
setfont 2
print "01234567879xxx"
; save the font with what ever name
SaveFont Path$+"Hud-Numbers-Font.crf",2
Sync
waitkey
[/pbcode]
So the code required in the game is now just.
[pbcode]
path$="C:\MicksGames\platform12\gfx\hud\"
; Load the HUD font.
LoadFont Path$+"Hud-Numbers-Font.crf",2
; Set this is the current output font
setfont 2
; draw some stuff
print "01234567879xxx"
text 200,200,"345234562"
Sync
waitkey
[/pbcode]
Quoteso i left it this simple way as it was one of the better ones , what do you think will this way do ?
looks fine to me
Quotethe black circle thing where it starts big and goes right in to where mario is and then they switch level and open black circle up again , whould this be ok ? or something else , ?
that sounds really nifty
is it me or was that last demo a bit choppy?
Hi all
Quoteis it me or was that last demo a bit choppy?
in what way , scrolling ? platforms ? it seems fine for me
mick :)
ok it's prolly me but i can't check right now. will prolly muck about with it tomorrow
Hi all
ok heres where i am now , kinda got a levels in 6 screens width , want to keep them not to long per part level , as you can see there are plenty of coins in this first level
so what i may do as other levels will have platforms in sky , is have maybe only 50 coins on some and have the counters for coins and flowers and carrots and fence count backwards so how mant left rather than got.
this is the first level so only coins and fences , will start to add others in other levels , no gamekeep in this first level
once you get to end of level nothing happens , but will do level pt1 complete and then carry on
BlinkOk no rush on end of level boss , i have got extra front layer in game now and can use capturedepth as well
Kevin thanks for helping with black circle thing i would have no idea how to do this , now in game but just black
hope this plays ok
mick :)
sounds cool mick.
should we do something at the end of the level? a house or something?
maybe when you get all the coins a key appears somewhere and you collect the key and it lets you in the house.
anyway i got distracted working up another tilemap for a spooky level;
(http://i93.photobucket.com/albums/l75/blinkok/spooky-1.png)
gotta do something about that far background. the platforms don't pop out enough.
ps: tried to demo again and it's fine. i must have had something running in the background
This project looks really amazing!
Good work guys :)
On my Computer there are issues with the graphics though. I see the pink parts that should be transparent and when i cross the first bridge, the level disappears but i can still see the background and the enemies.
I'm using Version V1.64i. Any ideas?
Looking forward to seeing how this comes along!
QuoteI'm using Version V1.64i. Any ideas?
Yep.. here's a few (http://www.underwaredesign.com/forums/index.php?topic=1774.msg19590#msg19590) (Scroll down)
Mick,
The new versions good, spent a while jumping from the platform to platform only to find there's nothing to actually get to. I'd still look at detaching the camera from the player. Like so, curvevalue edges one value towards another. The bigger the divider the smaller the step. Gives it a cheap inertia feel, could do the same for the player.
[pbcode]
if player_dead=false
CameraX#=curvevalue(playerx#,camerax#,20)
PositionCamera 1,CameraX#-(GetScreenWidth()/2)-40,0
endif
[/pbcode]
Hi all
Quoteshould we do something at the end of the level? a house or something?
maybe when you get all the coins a key appears somewhere and you collect the key and it lets you in the house.
yep that sounds the ticket ,
spooky level looks great , so level one as is , with normal kinda house at end of level ,
then level 2 spooky level with spooky house at end , or something like that
Thanks knieb , yep you need to upgrade to get it to run properly
Quotespent a while jumping from the platform to platform only to find there's nothing to actually get to.
i take it you mean at end of level , yep still goto do a bit on that
QuoteI'd still look at detaching the camera from the player
yep your code lmakes it look better thanks
mick :)
hey blinkok
your graphics look great. you are very good at graphic design and layout. did you learn through observation or from books?
hey micky4fun
you are growing your code and learning quite well. this is becoming a fun game.
stevmjon
Quoteyour graphics look great. you are very good at graphic design and layout. did you learn through observation or from books?
just observation and a lot of help from some very clever people out there on the interwebs (one in particular)
ok i had a little brain fart on the game play side of things.
let me be clear up front; please don't think you have to incorporate this! it is just a suggestion
this is what i'm thinking;
the dude does 3 things (all the while avoiding enemies);
1. get the paintbrush and paint stuff (thereby getting points)
2. collect coins (thereby opening the chest that reveals a key to exit the level)
3. collect the key and exits
if he gets hit by an enemy he loses his brush
when he paints...HE PAINTS EVERYTHING!!
(http://i93.photobucket.com/albums/l75/blinkok/spooky1.png)
Animation (Click "Play flash full screen" to see more detail) (http://megaswf.com/s/2490010)
i'm thinking the changes would be;
1. Add particle effect while foxy walks (this is very easy, no more difficult than your floating stars)
2. When paint touches platforms and objects their image changes to the "painted" state and points are added (one point for just a platform)
3. gui changes to be "Life", "Coins" and "Points" (Paint brush rather than fence)
4. this way we can avoid the watering can
Again this is just a suggestion. no biggie if you think it's too much trouble to implement (I know the enthusiasm wains as these projects progress).
Hi all
yep BlinkOk that all seems fine to me , just hope i can do it all , think most of it is straight forward ,
yep getting rid of watering can seems a good idea , gui was going to get messy with fence , flower etc ,
so whats happing is the level we have already staying but in new form or are we going with new design ?
did not get much time today as been nursing my mum over the last few days , she has a bad leg infection ,
but did get around to doing a few floating platforms that sink if you stay on them to long
anyway , let me know how and what level we are staring on etc
mick :)
sorry to hear about you mum mate. hope she gets well soon.
Quoteso whats happing is the level we have already staying but in new form or are we going with new design ?
i'll make the changes for the "sunny" level too. so tiles there will have a "painted" state too
Quotebut did get around to doing a few floating platforms that sink if you stay on them to long
did you see the crumbling platform i did earlier? that might look cool there
Quotejust hope i can do it all
you'll be fine. if you have any probs just ask
Hi all
yep thanks blinkOk,
ok i will just tinker around till new gfx's for level one , yep grabbed falling platform , will use them someware in first level
mick :)
graphics. i put most of it in the tiles image (300.png). you might have to copy/paste a bit but i thought that would be the easiest way. let me know if it's not
i hadda redo the trees so i included unpainted tree images in the directory as well.
i think there's a few block images there too
and the paint brush in the hud.
oh and the "play" wording on the play button is a little smaller.
did you wanna use the jump and fall images for the fox?
anyway. let me know if i missed something or you need anything else
You are welcome micky4fun =)
How about jump down, like that jump + down and our fox jumping into down platform?
Congratulation for your good team-work!!!
Very impressive graphics and very nice ideas!
Greetings
Sigtrygg
Hi all
QuoteHow about jump down, like that jump + down and our fox jumping into down platform?
yep i see how this plays and works , thanks for idea on that ATLUS also thanks for youtube upload :)
Thanks Sigtrygg , yep its a no rush job so dont mind going back and forth , BlinkOk is coming up with the goods here thats for sure
well used Kevins camera idea , looks better for that , spent a few hours today re-mapping map gfx image and matching up non painted and painted grass as rocks where a little over on painted image
no worries just a few cut and paste's ,
BlinkOk what i did as you can see is added a shadow to non painted fence and painted fence at bottom and move fox up 2 pixels as he did not look like he was walking past fence when they were painted
he looked to walk over them , think you know what i mean
so scoring is points for fence , platform painted , and coins , must collect 100 to get key , but dont have to get all the fences or platforms to continue , its just the coins that are important ?
ok heres a quick demo on what i did today just to see if it looks ok , or if you want to change what i did to fence , still no paint spraying from brush will do that tomorrow and only some of the platforms chance at mo , you have to get brush as usual first , i have not fully tested this yet so could be a bit buggy
mick :)
The new version is good, the painting mechanic works well, reminds me some Disney game. Like the floating platform also, such touches definitely make it more rewarding for the player.
You could clean up the media loading somewhat by making a little function that loads the 'left' frames and then creates the Right facing frames during loading. Which helps in number of ways, like less image data for you to man handle (ie, you don't have to make the rotated versions) and potentially quicker to load. Since the second frame doesn't have to fetched & decompressed from disc.
[pbcode]
; to load fox becomes
LoadCharacterAnim("gfx/fox/f0001.png",9,100,150 )
Psub LoadCharacterAnim(BaseFile$,Frames,IMageStart,RotatedIMageStart, Format=2 )
For lp =1 to frames
FileName$=replace$(BaseFile$,"0001",digits$(lp,4))
; load in whatever format
LoadImage Filename$, ImageStart+lp, Format
; Copy this image to the rotated image slot
CopyImage ImageStart+lp,RotatedImageStart+lp
; flip the pixel data on the X axis to make the rotated image
MirrorImage RotatedImageStart+lp,1,0
#print filename$
next
EndPsub
[/pbcode]
man this is the bomb mate! the sinking platform at the end scared the sh!te outta me.
it is really starting to prove a challenge too. all round great work mick!
QuoteBlinkOk what i did as you can see is added a shadow to non painted fence and painted fence at bottom and move fox up 2 pixels as he did not look like he was walking past fence when they were painted
he looked to walk over them , think you know what i mean
brilliant! looks 1000% better
to micky4fun
i love the behaviour of the dog. made me laugh. now the characters are getting smarter. looks cool.
stevmjon
Hi all
Thanks Stevmjon , probably a better way of doing it , but this seems to work ,
its getting there BlinkOk , well you would not believe it i spent all day just doing the paint splash thing , tried about 5 different ways and settings but this one seemed to be the best i could come up with , dont think its as pretty looking as yours , but seems ok what do you think ?
you can paint everything apart from moving platforms and a odd tree that i know about its on different level thats why ,,
will now get on with doing this level completely , so it does not matter how many less or more fences there are , just scoring for platform painted and extra for fence , just the coins are main part
will also look into ATLUS idea of down jump as well , i still have gamekeeper to muck around with , i have kept the jump and landing frames out so far as they did not look quite right , seemed to flow better as is , but on back burner , got crumbling platform to muck about with as well , so plenty to keep me going ,
just need idea for house level at end , a key to get in / unlock door etc , maybe start at bottom and work to while avoiding things , like donkey kong ? maybe ,
or could keep house level for next level as its a haunted level , and just do a platform thing for this level , key for box at top ?
mick :)
The painting looks pretty good. If you're going to recycle lots of sprites, then i'd be tempted to recycle them rather than create/delete them constantly. Anyway, noticed a logic error in the main loop with the particles. The particles being the stars and circles things, where they don't seem to be posited before they're drawn the first frame. So if you move fox to to top left hand corner of the world and walk you can see the particles being drawn for a frame up in the left hand corner.
Easy fix, just grab the Stars and circles for each loops,wack them in a function at the bottom, then make sure you call the function before the DrawAllSprites in the main loop..
Excerpt from main loop.
[pbcode]
Render_Particles()
DrawMap MyMap,front,0,0; front
CaptureDepth 20
drawallsprites
UpdateMapAnims MyMap
Drawimage ffs,97,177,0
DrawMap MyMap,trees,0,0; trees etc
DrawMap MyMap,fences,0,0; fences etc
DrawMap MyMap,platforms,0,0; main level
DrawMap MyMap,mud,0,0; mud etc
[/pbcode]
Render Particles Function
[pbcode]
Function Render_Particles()
for each stars()
if stars.count#>0
stars.y#=stars.y#-stars.speed#
stars.count#=stars.count#-stars.speed#
positionsprite stars.sprite,stars.x#,stars.y#
ELSE
deletesprite stars.sprite
stars = null
endif
next
for each cir()
if cir.y#<cir.count#
cir.yspeed#=cir.yspeed#-0.1
cir.y#=cir.y#-cir.yspeed#
cir.x#=cir.x#-cir.xspeed#
cir.count#=cir.count#-1
positionsprite cir.sprite,cir.x#,cir.y#
ELSE
deletesprite cir.sprite
cir = null
endif
next
EndFunction
[/pbcode]
You can short cut some typing by using the += and -= operators.
example,
[pbcode]
Function Render_Particles()
for each stars()
if stars.count#>0
stars.y# -=stars.speed#
stars.count# -=stars.speed#
positionsprite stars.sprite,stars.x#,stars.y#
ELSE
deletesprite stars.sprite
stars = null
endif
next
for each cir()
if cir.y#<cir.count#
cir.yspeed# -=0.1
cir.y#-=cir.yspeed#
cir.x#-=cir.xspeed#
cir.count#-=1
positionsprite cir.sprite,cir.x#,cir.y#
ELSE
deletesprite cir.sprite
cir = null
endif
next
EndFunction
[/pbcode]
Also, swap the LoadCharacterAnim with this version, the existing version is passing in a Frames Variable, but the For/NExt Loop is hard coded to run from 1 to 9,, it Should be from 1 to Frames
[pbcode]
Psub LoadCharacterAnim(BaseFile$,Frames,IMageStart,RotatedIMageStart, Format=2 )
For lp =1 to frames
FileName$=replace$(BaseFile$,"0001",digits$(lp,4))
LoadImage Filename$, ImageStart+lp, Format
CopyImage ImageStart+lp,RotatedImageStart+lp
MirrorImage RotatedImageStart+lp,1,0
next
EndPsub
[/pbcode]
Quotei spent all day just doing the paint splash thing , tried about 5 different ways and settings but this one seemed to be the best i could come up with , dont think its as pretty looking as yours , but seems ok what do you think ?
it's better than mine that's for sure. looks awesome.
i'll get onto the house key thing.
house and key ( i thought the coin over the chest would communicate that the player needs to get coins to open it, if you have another idea let me know cause i dunno if this method makes it very clear)
still need to get the bear boss together. let me know if you need anything else
ps: forgot the door on the house
pps: if you want the fox to walk into the house you'll need two images of the open door house (see house.rar)
Hi All
ok blinkOk i have grab images , thanks , house looks good , will get them into level asap , so once entered house the game will goto a in inside the house level ?
ive just finished the moving platforms so when landed they get painted as well , dont know if i will bother as could be a bit indepth to get grass moving platforms painted as well ,
think i will use them after fox as key and is on way to house with no paintbrush ,
also thought , if it was just about collecting the 100 coins to get key , then as coins are already out on playfield , the fox would not have to bother to get brush to move onto house
so what i have done now is the coins will only appear when you have collected the brush , if you lose brush coins disapear , you need to get brush again to carry on where you left off with coins
so that way you will have to paint most of the floor , platforms and fence to get all coins and upti you for bonus points if you want to paint more
the last demo had a few collision issues , you would collide without touching enimies , now put that back as it should be,
what i will do now is get this level completly done so you walk to house door and post it up ,
will let you know how the chest coins thing goes , thanks for the amazing gfx's so far blinkOK , hope its not taking up to much of your time
Kevin , thanks for your new code snippits , i know what you mean about being posited before they're drawn , did not relize that and see what you mean by in top left hand corner when at top far left you can just see the paint ,
ok lets get on mick :)
Quoteso once entered house the game will goto a in inside the house level ?
nah. i think that we can just make that the end of each level. i'll do another one for the spooky levels
Quotedont know if i will bother as could be a bit indepth to get grass moving platforms painted as well
nah i wouldn't bother. i might turn the particle effct off when he's on a moving platform though
Quoteso what i have done now is the coins will only appear when you have collected the brush , if you lose brush coins disapear , you need to get brush again to carry on where you left off with coins
so that way you will have to paint most of the floor , platforms and fence to get all coins and upti you for bonus points if you want to paint more
this sounds great!
when your done with this level i'll try and make a tile set for the spooky level and overlay that on the sunny level.
Hi all
ok BlinkOk
Quoteso once entered house the game will goto a in inside the house level ?
nah. i think that we can just make that the end of each level. i'll do another one for the spooky levels
right ok with you now , thats fine
Quotewhen your done with this level i'll try and make a tile set for the spooky level and overlay that on the sunny level.
ok yep would be great if they just overlaid , but i can always tinker about with code a bit , will get cracking and get this level done so you know the exact layout of tileset
as it keeps changing at mo
mick :)
Quotebut i can always tinker about with code a bit
as far as i can see the only thing to change (program wise) will be that the clouds in the background will become the fog in the foreground
i think i'm done with the spooky level.
ghost = dog
skull = snail
fireball = fish
bats = hunter
Animation (not scaled so much) (http://megaswf.com/file/2507056)
Hi all
All looks fantastic , I'm still tapping away , I av PM you blink ok
Mick
i have to say,it looks very nice!
Hi all
Hi monkeybot , yep BlinkOk id coming up with the goodies here thats for sure , making it nice and easy for me to get into gear and get game going
i have been distracted a bit with one thing or the other , but im still tapping away every spare minute,
anyway heres the game so far not a lot has changed , i have posted this up so blinkOk can see what im doing and spruce some boxes up a bit
well see if you can suss it out how to collect coins , its quite easy enough , end not done yet but plenty of ideas just hope some work
mick :)
haha. that's brilliant mick. i'll do some doodles for the next boxes.
Hi all
thats ok then BlinkOk , i have a few simular things towards end of that level as well , but wont give to much away till i do it as i might not work as i want it to , lets just see what happens and what you think , i will get more time sunday now to crack on with it
mick :)
This is AMAZING game micky4fun!!!
ok i'm not sure this communicates well but i used a circular arrow as the switch. if you think the question mark would be better then i can change it. i think the paint/coin switch is ok.
what do you think?
this is shaping up really well.well done mick.
Hi all
Thanks BlinkOk , yep they are fine , in game now , im still getting stuck in as much as possible with all happening at mo , well got gamekeepers firing bullets in at last as well as otherstuff , should not be to long till this level is complete , then just some testing and sounds to add , will post to you first BlinkOk for any other comments or gfx's changes , looking forward to the spooky level
Thanks ATLUS and monkeybot , its not exactly as i want it but this was only going to be a test for using maps and cameras , so to get this far aint bad and your comments are welcome
well back to game for a little longer
mick :)
Hi all
well BlinkOk , here is a outline for the complete level one , just the house missing at end , ran out of time today and some values need a little tiding up , but think you get the gist
also have not tried the jump down thing yet , but all in good time ,
ok you need 99 coind to open chest with key in at end near bridge with blocks missing and there is only 99 coins , you need to paint 99 or more fences , not platforms ,, there is more than 99 fences as well but even more platforms thats why i did it this way , once you get coins and big key , you will lose paintbrush as you have key now , this is to open very last chest/button or house door
dont think you will do it first go , you got 3 lives then ends , so need to re-run at the moment as i aint done ending and resets yet
good luck
mick :)
lookin good mick.
got past the falling platform after about 10 tries. i think we might need something to indicate a crashing/falling platform.
i think i might re-do that little fish. it doesn't really fit in with the other stuff now
i lose three lives and then it goes to a pattern with three chests in it and locks up. looks like a mini level to me. i figured you were still working on that bit.
this is just my opinion but i think if you make the coins trigger stuff to get to the end of the level and just make the paint add to a high score then it's easier to understand.
the incentive to paint stuff is that the player can end up in the high score table.
all in all this is really starting to provide a really fun challenge. very nice work mate.
Hi all
Quotethis is just my opinion but i think if you make the coins trigger stuff to get to the end of the level and just make the paint add to a high score then it's easier to understand.
ok no worries i will move a few things about ,
Quotei lose three lives and then it goes to a pattern with three chests in it and locks up. looks like a mini level to me. i figured you were still working on that bit
yep thats your 3 lives , its says end , but only a quick ending and it will lock up as i aint reset any values for a restart yet
so you need to re-run program
ok i will work on a few bits and bobs
mick :)
The latest demo is really good, it's nice to see some new bits appearing. Getting worried about how much of this your hard coding in the program though. Beyond just the object creation stuff, there's code that's changing specific blocks in the map. One alternative would be to implement an object type with change list mechanic. So for things that trigger actions in the map, like changing a switch or open doors or whatever.. There's a trigger object with some type of the action tag in it. If the trigger action is the 'change blocks', then it the AI calls a routine to poke a list of blocks into place. The user would define the list of the blocks and position the triggers in the editor. Same goes for the players starting position, end of level positions etc etc etc. Externally defining this stuff means that you can tweak the game without having to alter the code and even while it's running. Speed up development time dramatically.
pipe and spikes
tip: load up source code and change lives=3 to lives=20. hahahahaha
Hi all
thanks for spikes BlinkOk , i will use them in another level of the garden part as with the tunnel bit , could do a mario bonus single screen level thing there ,
i have now re-arranged the game a little ,
when you die you keep the coins and paint brush you have already got , as re-doing that again could be a bit boring and also would av to start miles away if right up other end of game
altered ending bit a little , made it so when it you dont lose so much of a life , but can change this back again ,
what i need to do now is
scoring , sound , ending of level one , reseting all values when 3 lives are up or to start next level , some moving platform when you av brush do not get painted so will av to work that one out as they are wide sprites and a few other little bits ,
but here is mainly level one complete
QuoteGetting worried about how much of this your hard coding in the program though
yep theres lots im affraid , but im hoping i will get away as this wont be a large level game , i will try to address this if needbe or on my next platform game , will try and do more work with the editor , but time at the moment is very limited and i maynot have the skill to do it either , lets see what happens , but thanks for all the help and input so far it has helped bundles :)
anyway heres level one ver nearly complete now
mick :)
In Windows 8, this game run very slow :-(
Hi all
QuoteIn Windows 8, this game run very slow :-(
erm , i was tempted to update one of my pc's today to windows 8 , so thanks for the heads up , might not bother now
mick :)
Hi Micky4fun, you are welcome =)
this is epic mick. great work! still haven't gotten to the end :-D
Hi all
Quotethis is epic mick. great work! still haven't gotten to the end :-D
yep not to bad blinkOk , did not want to go to far on a level as thought it might be to much and as there will be other levels same kinda size , but can do mini level screen in some other levels
still having lots of problems at work as PM so time is kinda tight right now , but getting on with much as possible , just may change sinking grass platforms a bit as would like them to have paint on them as with normal moving platforms , but should get this level wrapped up very soon
ps i getting to use to it do it in one life every time , lol
pss shame win 8 runs slow though
mick :)
Hi Mick,
Just been playing this. Great retro fun! Keep up the good work! ;D
Baggey
made it!
i reckon the loony tunes circle in/out would be a good ending animation
Hi all
Quotemade it!
i reckon the loony tunes circle in/out would be a good ending animation
yep BlinkOk you did well and with 5 lives left out of the 3 you get , lol
i hope you have not been cheating
the loony tunes ending would look great i think as well , i had a go at it but im pretty crap of sorting any code that works , my efforts slow and not right
my code lines 388 to 400 and using the last function in program does not work as we need it to , just get to house with or without coins and you will see it working , well sort of
i have now made my life and programming a bit easier for painting the moving grass platforms by making them a smaller , so a few little changes , the fish that did not look right i have removed ,
done a 10 and 50 point scoring gfx when you paint a platform you get 10 points and 50 for platform with fence , dont know wether to do say 100 and 200 for killing enimies as well , what do you think
mick
Quotei hope you have not been cheating
waaaaaaa! me.... cheating! ;-)
Quote10 and 50 point scoring gfx when you paint a platform you get 10 points and 50 for platform with fence , dont know wether to do say 100 and 200 for killing enimies as well , what do you think
yes definitely. the more variation in scoring the better
Hi all
QuoteJust been playing this. Great retro fun! Keep up the good work!
Thanks baggey , having fun programming this one , keep up the good work on the speccy emulator , looking forward playing some good old games on this
Ok BlinkOk will go ahead with more scoring options and gfx's , think this is what we are looking for for ending thanks to Kevin , think we need some ending wording , like" thats all foxy"
or something like that and level complete or something , in some kinda font , you know more about that than me
anyway trying to program in the dark aint easy , as i forgot the treats for the kids this year , trying to pretent im out .
mick :)
Quotethink we need some ending wording , like" thats all foxy"
haha. awesome. will do
done. if you need it bigger or bent the other way then let me know
Hi all
yep seems fine,
think will get door to close after fox enters house,
http://www.youtube.com/watch?v=b0lrd_uJNpo
mick :)
looks good mick. i think i might do some numbers for the pop-up scoring.
just to make it consistent with the hud. if that's ok?
Hi all
yep thats fine BlinkOk
mick :)
Hi all
well been trying a few things within the game , i tried the downward jump , but it was a bit yes and no , i seem to make quite a few mistakes and ended jumping off lower playform into water without really meaning to do it , just seemed more natural to fall down off higher platform ,
BlinkOk , i have done all the scoring gfx's but as you say would be nice to have numbers in consistent with rest of hud , so i will replace mine with new ones once done , just adding some sounds now
think we will have to have a high score table once finished , say top 5 scores , will muck about with that and ending and restarting game once dead , give me a few days and ile post what i have done
mick :)
Hi all
well been 2 days on just trying different name entry for hi-score table , well 2 days of spare time that is ,
anyway did not know which way to go , do a static name entry like Sigtrygg HellEagle game , or a moving one , wonder what you think we should do here ?
i have come up with quite a few ideas for a moving one , but the one that seemed to work best was the 360% one as shown
it is in demo , just get killed 3 times to get on screen , nothing works yet , jump up on END when at top of screen to play again
thought this might fir in as a water mill or something like that , the fox is on the spindle and when he walks it turns the wheel , i have not used rotate sprite on spindle yet so just imagine it , lol
could be a complete wheel with buckets on with letters in them can se smaller if required , just some idea here BlinkOk maybe could draw something better or other idea or just static screen for input ??
if you play till end of game no need to collect coins it will show ending of level , think might need a " level complete " in same writting as "thats all fox"
once complete game is now ready to load next level , at the moment just press spacebar when thats all fox comes up to replay level again
mick :)
looks good mick. it this like a mini level. looks good anyway.
i may not be able to work on this for a little bit but i'll make sure i keep an eye on things
ok i just got it. it's for entering a name
Hello Mick!
The circle-input looks much more nicer than static input!
It's great as you have done it! I think you should take it.
Greetings
Sigtrygg
Hi all
ok blinkOk no worries will plod along , will get a few more levels into game
thanks Sigtrygg , yep i will try and go with a wheel type input for hi-score , may just keep it simple as the gfx i do might be out of place
anyway see how it goes , will post when this is done and a new level is added so maybe a week or two down the line
but sure to continue tapping away at this
mick :)
ps i have gone with this i think
well done Micky4fun!!!
it looks very cool mick. well done mate!
Nice little touch! with the high score "ring piece" thingy ;D
Oh, Im Liking the "Top of the fox" idea as well!
Keep tho's finger's, a typing! ;)
Baggey
Hi all
yep thanks , BlinkOk i have changed the font for score so it matches hi-score screen as well , and so it can be seen in the night level as well
hope you dont mind ,
thanks baggey and ATLUS as well , its coming alone slowly , dont wont to sound like a broken record but still having to look after mum quite a bit
anyway still geting a bit in here and there
well this is the name extry screen and hi-score display , i have used a cut down and modifyed version of Sigtrygg hi-score table , so thanks to Sigtrygg for posting that.
https://www.youtube.com/watch?v=ZON94ObKv4o&feature=plcp
ok on with level 2 now
mick :)
excellent man! maybe use the background & clouds from the game as the background for the high score. just to tie it in with the game a little more.
hope your mum gets better soon too.
hows this for a high score background
Hi all
wish you would pull your finger out BlinkOk , took you over 2 minutes to come up with that , lol
how on earth can you do it that quick ? , took me 2 days at least to do mine
yep that will fit in like a glove , will just re-position the input circle and hi-score names and scores and will be the nuts
thanks for that BlinkOk ;D
mick :)
no worries mick! i'll try harder next time ;-)
I couldn't agree more!
The highscore wheel with that back drop. Will look very good indeed ;D
Baggey
It's still works slow in Win 8 and when i alt+tab plz see on screenshot :'(
Hi all
QuoteIt's still works slow in Win 8
thats ashame , well maybe a way around that for win 8 users , but maybe a while before i update
ok think i have pretty much done the ending , name entry , hi-score and restart screens now as shown
did do just a little editing on your picture BlinkOk , hope it looks ok
so at last onto level 2
mick :)
it looks superb mick. only problem is i'm not at the top of the list. you know with my 8 lives i can beat anyone! ;-)
Looks Great Mickeyforfun ;)
Baggey
Hi All
well had a time out from game as so much happening , anyway im back on track now so started level 2 ( night level ) as pic's show , hopefully get stuck into game now , so some more updates soon
i did over the last few weeks install windows 8 on one machine of mine , and yes this game as with all others ran at about half speed , so looks like the games are for windows 7 or less
anyway hope everyone had a fantastic xmas and happy new year to you all
mick :)
looks good mick. nice colours
Looks great, Mick!!
Have a happy new year, too! :)
I've just read about JJF and watched your vidz, Micky. It's a real professional-looking piece of games programming, and I saw with a smile that the original version came out in 1983, like I did ;D
Hi all
Thanks bmorris , yep its coming along and its not to bad , but looks quite professional thanks mostly due to the great gfx's by BlinkOk ,
anyway now the hols are over hope to get some more time on this now , here is a video of the crumbling platforms in level 2 , hope to get complete level 2 done really soon now
mick :)
that looks great mick. you are really starting to building in a lot of different challenges and variety.
awesome! awesome Mick!
very nice!!
Hi all
yep thanks all for comments , very welcome , its getting there
Well Level 2 is taking a bit longer than i tought , trying to add a few extra bits while not making it to complicated for me or player , so just a few bits to make it slightly different to level one
here is yet a couple of more videos , level still needs some tweeks and enimies put in and parts need to change when painted but gives a feel of part of level 2
hope to get a full 2 level demo up in next few days
mick :)
looking forward to playing this mick. the vids look great
Hi all
at last got a level 2 demo ready so here it is , code needs a bit of tiding up and still some things still need doing , i will let you suss it out on what to do , but pretty much the same as level one , its very much the same thing , so i might be how to sweeze one more level out with these gfx , to enter name on scoreboard use left right and down keys to enter name
BlinkOk , dont know if the level 2 backgrounds may need a little tweeking in colours or moon/stars maybe
also as all enemy are killerable , wonder if say a hedgehog or something else on grass/platform that cant be killed so you must dodge it
just thinking aloud here !
i will tidy do last few bits to this level just a bit of tidy up then think about level 3 , there may be one or two things i forgot as i have rushed this today to get it up on here
one more thing this is a looping level 2 , so once collected all 100 coins and enter house , after red ring ending just press space to restart
mick :)
man that is hard! i luv it!
backgrounds are cool. nice idea blurring the distant bg. i though they were a little too saturated but when i play it everything stands out just fine.
i'll have a crack at a hedge hog too
Hi all
BlinkOk ,
Quoteman this is hard
when making the games i play them so much and i find this and level one easy , lol , just that im used to it i suppose
dont want to make it to easy as it will be all over to quick, lots of things can be changed to make easy/harder , bullet fequency speed , how many gamekeepers etc
so plenty of options there ,
i have now linked level one and two together , will now start on level 3 with what i have , i kept the way of getting the brush the same in first 2 levels , might try something different on level 3
see what happens and the end house is in same position in both levels to , will move in 3
the moving objects in game really use the same code , i could use re-arrange the code for moving them so some use less complicated code as they dont require it
anyway i will have a tinker about , i expect to have all completed in a few weeks and will post a video walkthrough as well i think
Quotei'll have a crack at a hedge hog too
i will leave that to you , just a thought really
mick :)
Hello Mick!
Great looking level!
Cool, how the stairs collapse and how platforms tilt!
I am looking forward to play the whole game! :)
Mick,
Plays well, in terms of difficulty it seems fairly balanced to me, only taking a few goes to complete the level. How many levels is the game going to have ?
Hi All
thanks Sigtrygg ,
QuoteCool, how the stairs collapse and how platforms tilt
well thanks to BlinkOk for falling platform/stairs gfx's make that easy
QuotePlays well, in terms of difficulty it seems fairly balanced to me, only taking a few goes to complete the level. How many levels is the game going to have ?
well i am a bit suprised how well its coming out , as it was only ment to be a muck about trying the maps and camera , and also using a quite large 64x64 tile , thought a 32x32 would be they way to go really , but this seems fine
as for how many more levels , think i will get another out using what i have , it could get a bit all the same kinda thing , maybe how to sqweeze another 3 using secret rooms etc , so 5 in total
BlinkOk , just wondering if you still have any images ghost level at all , i might be how to make another new type of level out of that
i dont want to ad any of my own as it will look well out of place , i did try a wood log , but it was rubbish , lol
ok i will plod along with level 3 now , my mums in hospital at moment so will be spending free time there , but will still get a bit in as i can
mick :D
I've played the level now. It's a triumph! It's very professional, and the difficulty is about right (certainly for me). I read in the earlier comments that all the enemies are killable, but I must confess there were a few I couldn't get at...
A coupla comments/suggestions. Firstly, when the Fox walks, the water speed changes dodgily, so maybe something could be done about that. Secondly, when the Fox is idle, he's totally stationary, and I was thinking there could be a little animation (or a set of them) that occur after, say, every five seconds of idleness. He could waggle his tail, or shake his head, etc.
The filling in of platforms to jump on reminds me of Super Mario World, and the line at the end (the cartoon pun) put a smile on my face :)
QuoteBlinkOk , just wondering if you still have any images ghost level at all
yeah i still have that one. i'll see if i can generate some tiles/gfx from it
Hi all
well that would be great , give us a chance to do some more levels in the game that wont look so repetative
mick :)
Hi all
Yep sorry thanks bmorris , all points taken on board , yes there are a few gamekeepers that you cant get to in the level , on purpuse
i did think the water motion was pretty crap once moving but will sort this out when all levels are done
just starting to get level 3 together , but been quite a stressfull time at the moment , as mensioned before my mun is in hospital and not in a great way at the moment so most time spent there
but doing as much as i can considering ,
Kevin , wondering what im doing wrong here , im trying to render the game to image 1500 as in edited code below , but i cant seem to get the maps to be displayed no matter how hard i have tried
and i have spent 2 days trying , its proberly so simple i cant see it ? , so if you get a few mins maybe you can have a peep
thought it might give me more options on further levels
thanks
mick :)
ps code is edited code and not full game
Quote
wondering what im doing wrong here , im trying to render the game to image 1500 as in edited code below , but i cant seem to get the maps to be displayed no matter how hard i have tried
and i have spent 2 days trying , its proberly so simple i cant see it ? , so if you get a few mins maybe you can have a peep
thought it might give me more options on further levels
If image 1500 is an FX format, then it to stands to reason that the map blocks should be FX also, but there not. See
MakeMapGFX There's tutorials on such subjects over in the Economizing Image Blitting (http://www.underwaredesign.com/forums/index.php?topic=1799.0) thread.
Hi all
QuoteIf image 1500 is an FX format, then it to stands to reason that the map blocks should be FX also, but there not
Thanks Kevin , nope went staright pass that , did not notice , i was concertrating on the other commands , thinking they must be some how in the wrong order
mick :)
Hi all
well just a very quick update , still trying to squeeze in time , most is really just experimenting with one thing or the other , i have re-mapped levels 1 and 2 map gfx image so theres 28 images before they repeat painted , give room to add extra tiles for platform , also now made the water part of the map rather than just a image stuck on top of map , also added an extra level in map for coins , so i can easy overlay coins on trees fences , were before they had to have there own space
BlinkOk , i think i will need different gfx's for the switch boxes , as they seem a little odd on the new level as shown in this part level 4 video , think a question mark in new switch would be ok
(the rising platform would allow you to carry one going right , not yet done)
theres no rush as can use level 1's boxes for moment and just overlay new ones , thanks , i will send level once completes to you
well will get level all done before posting next , including new enimes
mick :)
Edit: please use the YouTube Tags when posting videos
looking good mick. i'll have a look at the switches.
i've been doing a little tinkering as well;
(http://i93.photobucket.com/albums/l75/blinkok/construction_zpsfe6bd1a8.jpg)
Hi all
OMG , you certainly have, another stunning level design ,
love the workman and saw , your teasing me now , lol
well that looks like another 3 levels , going to be quite a game i think
i will get much in as i can to try and catch up with you
mick :)
looking very nice blink.
awesome blinkok.
i haven't integrated the graphics into micks new code yet but here is a very very short vid to show the movement;
That looks fab :D
Hi all
very nice BlinkOk , looks great cant wait to get this into game , just completed this level apart from dropping in enimies hope to do that tonight/tomorrow
think we might need a new house for this level as dont quite look right , a spookie one maybe?
will send level once complete
mick :)
ok no worries mick. i think i had some purple (break apart) rocks too
that's a house and a spikey dude on back order
Hi all
ok thanks BlinkOk , no rush as its taking its time comimg together , well not quite got level4 finished today
so tomorrow/saturday will be done will need some tweaking here and there if to hard
anyway will get it to you asap
heres a short video of begining
mick :)
nice level design mick. i like those little joins you added to the platforms. it breaks them up nicely and adds a bit of variety.
Hi all
i will continue this game soon as i can , but alas some very sad news my mum meet the boss at the end level and did not make it though .
mick :(
Dear Mick,
I feel sorry to hear this from you!
I wish you and your family much strength for the next time
and hope that there will come back lucky days sometime for
you.
Sigtrygg
Mick,
My deepest condolences go out to you and your family..
im so sorry to hear mate.
our prayers are with you and your mum.
sad news mick.
i wish you all the strength.
stevmjon
My condolences Mick. I hope you'll be able to come through this okay.
Hi all
Hi guys thanks for your support , its been very hard , and a bit sudden to be honest , but things happen
at least i have this to play around with and over the last few days its really really help me along ,
so i have now all but done the 3rd level of the game , just a bit of tuning up here and there , but this is pretty much it
BlinkOk , thanks again for all the gfx's for this game , its pushed me forward , i was thinking maybe the lights on the bridges could flash maybe and when painted be really dull just another idea , also the switches may need to be touched up so gfx's go with this level,
i have not used the cannon on this level , will use it on next i think
anyway here it is , feedback welcome , water/fire scrolls properly now , fox still non animated when still , you will play level 3
if you complete level 3 then press space at end to re-play level 3
if you lose all 3 lives you will re-start on level 1 , so just end program and run it again
its not easy , but its level 3 and can tame it down
mick :)
no worries mick. i'm downloading it now. i did have the lights glowing a bit early on so i'll go back and have a look at that.
no that we have three worlds (i've got another one in my head) i thought i might see if i could do a map.
i've added a trapdoor and a rollover switch so we could make some puzzle type sections.
i also added a tile that you have to paint to walk on (which gives the paint brush a bit of functionality);
(http://i93.photobucket.com/albums/l75/blinkok/tile_zps5d199028.png)
playing now. there goes my sunday!
did you get my last message? im not sure if i hit send on it or not
BOO YA!
(http://i93.photobucket.com/albums/l75/blinkok/win_zps5526e003.jpg)
Hi all
yep just got your last message BlinkOk , thanks for that , i had a very quick go , but its well past my bed time , not had a great deal of sleep lately
so i will have a good look at it in the morning , but it did look very good to me
ideas about map seems fine to me to , will look at the trapdoor and switches in morning as well
well you made it to then end then !
mick :)
huh ncie game! But in win8 it's still slow run =(
Win8 seems to have issues with DirectDraw, I'm guessing it was removed and is emulated by DX11??
Quote from: ATLUS on March 14, 2013, 01:41:44 AM
huh ncie game! But in win8 it's still slow run =(
well, you've got everything you need to find out why.. so why not try ?
Quotewell, you've got everything you need to find out why.. so why not try ?
so you're not going to fix this then?
Quoteso you're not going to fix this then?
fix what ?
Quotefix what ?
performance under win8
Quoteperformance under win8
and where specifically are we looking ? - Beyond that, I don't have a Win8 install nor the same hardware as ATLUS anyway.
My opinion is it's driver related, moderns drivers have generally awful legacy 2D support. The early Vista->Win7 one's were much the same..
so when do you expect to be able to support your product under win8?
Having been preoccupied for the previous week or so, I've now got round to playing the latest level of Fox. It's comparably good to level 2, so I haven't got much to add, but I'll make the following remarks. The bit where you unlock the chest by means of the rotating platforms is nice; the coins were rotating a bit fast for my liking; and at the place where some vertically moving platforms come down to the level of the lava/water, even though it's fine as it is, a possible (slightly evil) idea would be for them to go a pixel or two further down, to take a teeny bit of life off Fox.
wicked idea mr morris. i like it!
if anyone else has win8 could you take a moment to run the demo and see if it is performing poorly for you as well
Hi All
thanks for the ideas bmorris , the just touching the lava idea sounds good to me , will put this into game , i have slowed coins down to half the speed now , yep they did look fast
yes BlinkOk all my games run about half speed under win 8 on my other pc
about half way through the builder level now , here is a short video of a small part of game so far , will get more work into game over weekend
so hopefully soon get complete level done ,
mick :)
EDIT: please use the YOUTUBE tags in future...
that looks great mick. heaps of stuff going on. i reckon it would take me about a month to beat that level ;-)
Quote from: BlinkOk on March 21, 2013, 09:11:18 PM
wicked idea mr morris. i like it!
if anyone else has win8 could you take a moment to run the demo and see if it is performing poorly for you as well
BlinkOK,
I have the same slow performance under Win8 Pro 64-bit as well, hence my post above. It seems Direct Draw is the issue with Windows 8, I saw it somewhere, but been awhile since I read about it. For instance, with Bejeweled 3 on my setup it refuses to 3D accelerate the game.
Quote from: BlinkOk on March 21, 2013, 09:11:18 PMif anyone else has win8 could you take a moment to run the demo and see if it is performing poorly for you as well
FPS = around 02 on my new (bought a few days ago) laptop with Windows 8.
Also on Windows 7 try activating Task Manager and going back to the game and you're in for an unpleasant... black surprise.
thanks guys. clearly this needs looking into
Hi all
seems all my programs run very slow on win 8 , well unplayable , but im not that bothered as i dont really like win 8
but here in the uk all new pc's and laptops come with win 8 now , so anyone buying a new pc/laptop will
have big problems with PB
ok ive been off on holiday for a week , and the level takes a bit longer than i tought to finish , but i have done it now , going to play test
it for any adjustments then post very soon
mick :)
Hi all
well a little longer testing than I thought , but here is the next level of the game , big thanks to BlinkOk first of all for yet more superb gfx's for this level
its a bit tricky this level but I can do it easy enough with 1 life , so lets see what others think as with all other levels can be easy tinkered with
as I doing game I can see theres lots of places I can use less code in , so I will do that once all game is done as I will see full layout by then
scoring still needs to be fully complete in whole game but some is in there as is
once level is complete just press spacebar on that's all fox to go back to level 1
ok onto next level in a day or 2 as other half needs me to do a few bits for her
mick :)
This is looking and playing great!
keep up the good work chaps!
Hello Mick!
Very nice level again!
First it was a bit difficult, but after playing some time
I got a feeling for the moving platforms and then it went
further...
So, I think it is not too difficult. Graphic is great and funny,
too! This will become a round funny game! :)
Bye,
Sigtrygg
superb work mick. really challenging and fun level. i luv the saws moving across.
it would be interesting to see what people think but i thought when you jumped on the saw leaving the blade, if you jumped on it again or touched it, it would reduce your life rather than shooting off.
something to up the difficulty a little. what do you think?
i still have to do a couple enemies for the ice level and a map too.
overall i really think it's coming together. all the pieces are there and they are working and very robust
only had quick look, but it plays pretty good.
Hi all
thanks for all the comments from everyone , all taken on board
seems to be coming along nicely , code not pretty but just done some tiding up this morning , lots need moving about and some can be reduced
I think I will re-map the map gfx's so they can be interchangeable with any level and will map the ice level into game as well
thinking we now have 4 themes so 2 levels of each will give us 8 levels which could be enough maybe ?
anyway will get as much done asap , just looked been on this 6 months how time flies ,
mick :)
ps looks like I need to get some kind of light snow routine from some ware to put in this level maybe?
4 themes x 2 levels sounds ok.
maybe if we re-post the level editor we could get some of the guys on the board to create some of levels?ice level is looking great. i have nearly finished the enemies for it
Quoteps looks like I need to get some kind of light snow routine from some ware to put in this level maybe?
there's a thread around here where someone has already done that
Quote6 months
6 months! we gotta shore that up!
Hi all
Quotemaybe if we re-post the level editor we could get some of the guys on the board to create some of levels?
yep can do but its very basic , think might need to had a few options on it later to make it easier to create levels
also as Kevin said a lot earlier in the post , I also need to get into the level editor a way of picking the enemies and placing them into map and exporting their position and movement into the main game
rather than hard coding them in the main game
so think I will get the ice level done asap and then move onto updating or try updating the map editor to do the above
also was thinking of trying another way of detecting when player hits the platforms in the map , but at the moment its working fine the way levels are mapped
lots of things to try and do , but getting there bit by bit
ok will look up forums for snow code
mick :)
I've just been playing the latest file. Not much to say, other than that it was as good as usual. Regarding a level editor, that would definitely be welcome, although I can imagine a lot of work would be necessary in making it. NB, I myself would seriously consider designing a level or two for the final game :)
QuoteI myself would seriously consider designing a level or two for the final game
awesome!
Hmmm had a quick look at this. The program as it stands, isn't really setup to be editor firendly. It'd possible to remove the hard coded limitations and externalize the levels from the game code, with only a conceptually shift.
Example: Entity Loading Example #2 (http://www.underwaredesign.com/forums/index.php?topic=3680.msg27090#msg27090)
Ideally, a games 'Load_Game_World" function would be given a level file name, where it's load the entity spawn points, the blocks/maps, world constants, animations etc etc all from that definition. So designers can create new levels without having to modify the source code all the time.
this is my take on it;
(http://www.underwaredesign.com/screens/PlayBasic/Games/ForFoxsSake/For-Foxs-Sake-Editor_Mock-Up.jpg)
original image (http://i93.photobucket.com/albums/l75/blinkok/editor_zps5df47f6a.jpg)
all the images on the left would be loaded from a text file that points to the images and describes their function.
the user would "draw" platforms by clicking on the appropriate platform and simply clicking and dragging in the window to draw the top of the platform.
the editor would fill in the lower parts (if necessary) automatically.
you could place characters where you want them to spawn and then drop animations on them to define various properties of their movements.
the editor would then create a tile sheet for the level (slicing any larger images as necessary), a tile map and a spawn and motion map
(personally i would try to put it all in the tile map)
yeah, as has been previously suggested the easiest option for the 'level designer' is to have everything in the one editor, the more automated the better really. The mapping + entity dropping are pretty trivial, but I think the conceptual stumbling block for mick is that he's got hard coded actions all through the program.
For stuff like the block modifications upon some collision, or toggle switch, the list of things (tiles in this case) are passed to the Action handler, which runs through and does whatever the task. Actions could be things like writing tiles to the map, triggering other states, level skips, object creation etc etc.
yes. definitely requires a rewrite.
Hi all
Quoteas has been previously suggested the easiest option for the 'level designer' is to have everything in the one editor
yep i can see that is they way to go , but programming an editor to do this is proberly beyond my scope , but what blinkOk as drawn up looks excellent
so i might just have to carry on as i am with this project , lucky enough i did manage to do just a simple level editor for this as without out it the game would have not got this far
anyway i see what happens will tinker around with my editor when i have done enough levels for this game , think i will try and get 8/12 levels out of it , will take a little time but
have nigh on everything needed now to do this i think
so i have been doing the ice level , may do things a little different , as the bear is quite large , you have to hit hin twice or hit he's head only to kill him
as with penquins when hit you then maybe slide on there poo as its on the ice , also fox now slide a little before stopping as he's on ice , make the moving platforms that little harder
heres the first part of level
mick :)
ps what button at top do i need to insert video , i used insert hyperlink?
Quotebut programming an editor to do this is proberly beyond my scope
I doubt it, It doesn't have to look pretty or even be particular smart! - All it needs to do it let the designer place characters on the map and tweak the attributes.
If the spawn data was externalized, you could probably add dropper tool/mode in a matter of an afternoon. A few hours invested up front, will no doubt shave weeks, if not months from the production time.
Quoteps what button at top do i need to insert video , i used insert hyperlink?
Forum Custom Tags / Forum Questions (http://www.underwaredesign.com/forums/index.php?topic=3911.0)
QuoteAll it needs to do it let the designer place characters on the map and tweak the attributes
this is true. all you need to to is drop the sprite and save the location and a couple other numbers. it's just spitting out numbers. you can do the rest in the game
Quoteps what button at top do i need to insert video , i used insert hyperlink?
if you edit one of your posts that kevin has changed you will see exactly how it looks
ps: that level is looking sweet! i have changed the backgrounds and added an eskimo. they are in the latest update i sent you
Hi all
thanks BlinkOk , I have sussed the youtube bit out now , I thought I had to use a button in post , lol oh dear
well I will try an editor when I have done all the levels as its not that hard placing all the moving platforms/enemies as I am doing at the moment.
the most time is coming up with the ideas and level design , placing them don't take long , its only my job getting in the way
well the ice level is neary complete , I have spent most of my time re-doing the way the fox is handled on the platform
this has now allowed me to do more stuff with bigger platforms etc , there is loads of tiding up that I can do , but will leave most till game is complete as don't want to move stuff now that I might need to
move back on other levels
just wanted to share this with you , it was my birthday yesterday and got a birthday card of my brother , he's wife does birthday cards , they surprised me with this
it looks a lot better than this image shows , its all in 3d , multi layer card , that does not really show in picture here , they got the image off of my youtube video
quite good I thought ,
will post ice level very soon
mick :)
haha. very cool card mate. happy birthday too.
Happy Birthday Micky.
Hi all
Yep thanks guys ,
ok heres the ice level a few things i will change later , will make them ice keys that open the paint chest rather than gold
the penquins poo you can slip on but does not kill anything after , still lots of tiding up and slight re-arrangement of enimies
but other than that think this is the level
any comments welcome
mick :)
ok mick i just downloaded it. it looks great. the sliding is a great idea and the snow makes it look fantastic. back to playing it (there goes my day!)
New demo's looking good and happy Birthday for the other day..
Okay. Just wow. You've done some great work Micky. I'm really super impressed. How long have you been working on this project now?
A year? Hehe.
It's pretty nice to see playbasic running a game with graphics like this. How'd you get such good graphics in the first place? Must've had some very very nice art!
=p
Anyhow. GOOD JOB. :D
I'm really super impressed. Now... the kicker. MULTIPLAYER LEVELS?
I bet you, I could incorperate a multiplayer level thing for the game.
It might be tricky and messy though at first.. I've messed around ALOT with Multisync and I recently found the best way to get almost 0 latency with player and player movement...
Actually I'll share it here. A trick with multisync I discovered from experimenting is not to overload the message stack with a constant player X and Y update. There should actually be a timer that helps decide how often to update. Playbasic runs it's code several times a milisecond.. or once a milisecond.
That's 1000 messages on the message stack a second for multisync to handle. It can keep up but I found, the less frequently I sent a message via multisync the less lag I experienced.
I tested through hamachi, using a simple program that keeps track of another player's movements. I got roughly 1-10 ms of lag. At most.
So yeah ^^; I can definitely help. I'm incorperating a system into all my games pretty soon (it's been in design for 3 years almost) for lagless multiplayer gaming experience, using multisync.
I can code some of that into your project if you want. But I need to know what your system variables are, and how you're storing the player's locations.
Also what flags or checks you're using. For example... switches I saw in the video. If hit by one player, obviously the ID of the switch along with some
other crucial information about what object that switch must be effecting will be required to be sent over to the other player.
I bet I could achieve some decent synchronization. I don't know how willing you are to give me the source code, which is why I'm asking.
Just an idea but honestly I really could (over a few weeks likely) make this into a really great multiplayer feature game (as well as single player)
QuoteI don't know how willing you are to give me the source code, which is why I'm asking.
the source code is in the .rar file lemony dude. just download and code away!
Hi all
yep LemonWizard , just jump in , if you need to know how I am doing something just ask I will try and explain as my code is very messy and could be hard to follow
as for the graphics , BlinkOk has done all the wonderful Gfx's and animations and I have used HeyHey code for the snow effect
I am going to slightly change this level to get the player flowing a bit more , and get the player to be a right screen depth when jumping up over a bridge post he is behind it at the moment
I will then start another level in the game also will muck about with ways im doing things to see if theres an easier way or a way that I can do more things
anyway will be tinkering around with game over next few days
BlinkOk , its plodding along at the moment , don't think theres going to be much more on the gfx's side that's needed maybe 1 or 2 things later if that's ok
Here is a couple of more video's
mick :)
Hi All
thought I better get an update to what's happening with game , well time is short at the moment , been really busy
but have managed to get most of another ice level done , should have a demo of complete level in the next day or 2 so will post that up
screen below
thought I would mention here though , I did have a few hours spare last night and caught up with a film that I got for present , wreck it ralph , well worth a watch if into video games , as film is full of old video game characters qbert , who remembers him ? , loads and loads more
anyway back very soon
mick :)
Hi all
well bit more than I thought to do , but just about squeezed it in before bed , not fully tested by me so might be a bug or 2 ,
some collision updating been done since last demo , some moving platform paint routines done so not whole platform gets painted when fox is on it
scoring still need to be fully done , but here is level 8 ,
think I am going to have 2 levels of each theme so 8 in total as this is taking quite a while now and I have other game ideas I want to try out
they may or may not work out but want to give them ago , before I get to old , haha
so I will do another building and ghost level make it a bit harder so will take a while to do all levels
anyway here is level 8 demo
mick :)
looks good mick. ill check it out tomorrow
Another great level, Micky. Btw, is the game inspired by Psycho Fox on the Master System? (I never had an SMS, and I've only just discovered the game.)
Hi all
Quoteis the game inspired by Psycho Fox on the Master System?
Thanks bmorris , nope I have never heard of the Master System , lol , no sorry I have never seen Psycho Fox , but just looked it up now , I can see why you might think that
no I just really started to have a look at the map and camera functions in PB , I started this as a kinda sonic game , I just used the fox character from my pooyan game as a start then BlinkOk game up with this fox and we went from there , I must admit I do like platform games so this really suits me , learnt a hell of a lot from this project , all of which will help once I finish this to do yet another platform/puzzle game I hope , among others I want to try ,
this game as proved hard designing the levels as I have done it in a style where there is no walls or anything to stop you going left/right or up only the ground stopping you going down
so doing puzzles and blockages is hard , so I have not bothered with them, but the next platform will have them in. also level map is quite long as well , not easy filling it all up.
and the map editor im using does not let you drop in the enemies/platforms I hope to fix this on next project , also would maybe have you shooting at the enemies as well , will have to see how this all goes
but for the time being im doing the last 2 levels to get this finished as soon as possible , im on level 4 now , ghost level pt2 , then just one more building level to finish it , end screens to do
demo mode to do as well as sounds so still quite away to go ,
the thing I found with this game is once one level is done , its very hard to start from scratch to start another level , weird !
anyway thanks for all the comments
back soon
mick :)
PsychoFox on MS is an awesome game. There are two remakes for the MegaDrive (Magical Flying Hat Turbo Adventure and DecapAttack - the former is a much better looking game, although only released in Japan). FFS is not really like any of these, other than it's a scrolling arcade platform adventure.
This game really is shaping up very nicely. Very nice indeed :D
Probably said it before, but it reminds of Andrew Braybrook / Grafgold game Fire & ICE on the Amiga..
Hi all
yep can see it looks like Fire & Ice a lot , probably had that game on the Amiga them years back , my favourite platform on the Amiga was superfrog
well another fire level is well under way so hope to have that completed very soon , small video of part stage below
mick :)
loving all the little variations mick. looks sweet
Hi all
well time going fast , anyway got another level out and here it is , bit hard this one , you wont do it first go , so BlinkOk crank up then lives
made this level a bit harder as only 8 levels and will be to easy to do , think you could get an extra life at certain score etc
still lots of tiding up and plenty of values can be changed , still scoring to do properly
any comments welcome , will get going on 2nd building site level over the next day or two ,
I have updated the collision yet again , but still some changes can be made , you still can get away with some things , this is intentional at the moment
Quoteloving all the little variations mick. looks sweet
well trying to vary it as much as I am capable of , but not that easy to do , anyway hope there's a few new things in this level
don't know how you can do the gfx's so quick , this coding takes some time , think as someone said earlier that fox could be more animated when he is still
anyway leave that to you if you have the time to do anymore animations , ok that's about it for now I think
hopefully will all be done very soon
mick :)
this one's gonna take a while to crack. those crumbling tiles are deadly!
haha. just had to relax a little (and add about 10 lives)
Good work guys, watching your videos is very inspirational! I like the part with the platforms moving down / looping when reaching the bottom, the crumbling tiles etc! Gives me ideas for my ow project :)
@mick Good call, Super Frog was great fun, I never managed to play past the first few levels though, slow reflexes I guess!
why has heyhe's (i think) thread "my new game" been deleted?
Hi all
just wanted to keep forum , well BlinkOk mainly informed on whats happening with game as he as put in a lot or hard work gfx's side
well doing it as i can , as i am now out of work after 31 years in the same retail job , im trying to find work at the moment and its not easy and tacking up a lot of time , just writing my CV was a something i never done before , anyway , level 8 in almost done so theres not lots to do to get a full playable game finished , its been ages in the making when a month or so all could av been done , well just been a bad year i think
i have been looking about forums still , did like ScottieB battlezone a lot it looks excellent , but seems have to a stop at the moment ?
ok back soon i hope
mick :)
sorry to hear about that micky.
it's been a tough year alright mate. hopefully it can only get better!
as always there is no rush here, so don't stress yourself, take as long as you want and good luck with the job hunting
That's not the best news.. Hopefully things pick up for you soon.
Hi All
First of all thanks for all comments and personal messages wishing me luck guys ,
sorry this as taken so long to get done , but doing it as much as I can
this level took a little longer than I thought to finish and its the final level so have 8 in total , anyway here it is , still some things to finish off , will now tidy up code a bit , wont go mad as it works as it is
I will look where I can improve parts of the game , add some sounds and other bits needed to get it all finished , will make it a bit harder so when you get hit you lose a bit more life
I did what said BlinkOk , I have made it so when you kill moving saws the inside saw stays where it is and you can lose energy if you hit it , well have fun
parts of the game require certain amount of gold coins before you can move on , so make sure you get them all , when done goes back to level 1 , so just re-run to play again
mick :)
awesome mr fun. i'm away today so it will take me a couple days to get to this.
ps: you are an evil man micky! do you know how many foxes were killed to make this game? and a lot more will go before i finish this level too!
Played the new update the other morning, don't think I manage to get through it..
Quoteyou are an evil man micky! do you know how many foxes were killed to make this game? and a lot more will go before i finish this level too
lol , erm I am still on my first fox , hope you aint killing them all BlinkOk
Quote
Played the new update the other morning, don't think I manage to get through it..
oh dear , thats the trouble me non stop playing levels I do it easy with one fox , could take a few yellow saws out near paintbrush wheel that might help ,
did not want to make it to easy though as it wont last long
not to sure if there should be some kinda timer in game as you could just stand about and take you time doing levels , will have to think about that , or have your energy go down slowly even if you don't hit anything and at certain points in game you hit a block to add some extra energy , something to think about again
just putting in sound , I started a bit overboard I think, having the saws get louder as they get nearer to you and sound coming out of either left or right speaker depending where the saw was to you.
but decieded not to go that way and just keep it simple , a bit 8 bitty with the sounds
also found some small glitches on this level and others to , for instance once saw come out of yellow saws if you jump up and down on it quick nothing happens , so fix that , I know there is other bits that need doing in other levels , but that's straight forward , but got the main guts of game now , just wrapping it all up will take a week or so I would have thought
im really looking forward to doing something similar another platform game I think , but more thought out and maybe up/down than left/right , we will see
mick :)
ps tried the .exe of this game on a few pc's and plays fine on them , right down to a Pentium dual core 2ghz win xp machine , an Athlon 1.66 single core did struggle with it though
played about the same speed as my mates quad core amd pheonom machine with windows 8
Mick,
Quote
oh dear , thats the trouble me non stop playing levels I do it easy with one fox , could take a few yellow saws out near paintbrush wheel that might help ,
did not want to make it to easy though as it wont last long
Unfortunately that's just what happens with familiarity, so getting the balance right for new players was always going to be difficult.
Having a bit of pick through the code again and there's a lot of redundancy in the program, which is throwing away performance. Even though the program runs about 200fps (without vsync frame cap) on my 8 year old athlon system, the further down you go the more these things get magnified. There's some areas where some easy gain can be made though.
Examples,
Parallax The scrolling backdrops seem to be oversized. Drawing transparent pixels aren't free to render, so if there's 3 layers and the second layer is 1/2 transparent then an easy gain is to clip the sections so they still overlap. The slower the gpu the higher the potentially gain in fill rate.
2 layer brute force example
[pbcode]
path$="beta_v4.0\gfx\"
Layer1=loadnewimage(path$+"background\bg1.png")
imagemaskcolour Layer1,argb(255,255,0,255)
Layer2=loadnewimage(path$+"background\bg02.png")
Do
; simulate parallax movement
Xpos# =mod(Xpos#-1 ,GetImageWidth(Layer1))
Xpos2# =mod(Xpos2#-0.5,GetImageWidth(Layer2))
; draw the two fields
DrawImage Layer2,xpos2#,0,false
DrawImage Layer2,xpos2#+GetImageWidth(Layer2),0,false
DrawImage Layer1,xpos#,0,true
DrawImage Layer1,xpos#+GetImageWidth(Layer1),0,true
text 0,0,fps()
Sync
loop
[/pbcode]
2 layer brute force example clipped
[pbcode]
path$="beta_v4.0\gfx\"
// load front image and trim it up, removing about 40% of it
TempIMage=loadnewimage(path$+"background\bg1.png")
Width =GetImageWidth(TempIMage)
Height =GetImageHeight(TempIMage)
Crop=320
Layer1=NewImage(width,Height-crop)
CopyRect TempImage,0,crop,width,Height,Layer1,0,0
DeleteImage TempImage
ImageMaskColour Layer1,rgb(255,0,255)
TempIMage=LoadNewImage(path$+"background\bg02.png")
Width =GetImageWidth(TempIMage)
Height =GetImageHeight(TempIMage)
Crop=20
Layer2=NewImage(width,Height-crop)
CopyRect TempImage,0,0,width,Height-crop,Layer2,0,0
deleteimage tempimage
Do
; simulate parallax movement
Width=GetImageWidth(Layer2)
Xpos2# =mod(Xpos2#-0.5,Width)
; draw the two fields
DrawImage Layer2,xpos2#,0,false
DrawImage Layer2,xpos2#+Width,0,false
Width=GetImageWidth(Layer1)
Xpos# =mod(Xpos#-1 ,Width)
Yoffset=GetScreenHeight()-GetImageHeight(Layer1)
DrawImage Layer1,xpos#,YOffset,true
DrawImage Layer1,xpos#+Width,YOffset,true
text 0,0,fps()
Sync
loop
[/pbcode]
The second example is about 10% faster and is using approximately 3 meg less data in GPU's video memory with no real effort. Video memory is a finite resource and one we can't afford to waste. While on the subject, I feel it'd be better not to load the parallax images into memory each level as video images. Rather load them into memory as FX images, then copy the pixel data to the Video image when required. On legacy systems with small video caches, this could make the difference between is working or crashing.
I don't recall what indexes the parallax uses, but say image 1000 is layer 3, image 1001 is the second. So make a little function to copies the data down. Eg.
[pbcode]
Function Init_Backdrop_Images(Layer3,Layer2)
Width =GetimageWidth(Layer3)
Height=GetimageHeight(Layer3)
CreateImage 1000,Width,Height
CopyREct Layer3,0,0,width,height, 1000,0,0
Width =GetimageWidth(Layer2)
Height=GetimageHeight(Layer2)
CreateImage 1001,Width,Height
CopyREct Layer2,0,0,width,height, 1001,0,0
EndFunction
[/pbcode]
Redundancies One of the things that can cripple a programs performance is computational redundancy, so things like falling through impossible decisions or computing a value multiple times where the result hasn't can have dire affects on performance.
Here's an example of falling through a impossible decisions.
[pbcode]
if playerx#<2940 and game_scene=1 then player_xpos#=550
if playerx#<3400 and game_scene=2 then player_xpos#=550
if playerx#<2720 and game_scene=3 then player_xpos#=550
if playerx#<4700 and game_scene=4 then player_xpos#=550
if playerx#<2650 and game_scene=5 then player_xpos#=550
if playerx#<4356 and game_scene=6 then player_xpos#=550
if playerx#<3240 and game_scene=7 then player_xpos#=550
if playerx#<4350 and game_scene=8 then player_xpos#=550
if playerx#>2940 and playerx#<4790 and game_scene=1 then player_xpos#=2940
if playerx#>3400 and playerx#<6100 and game_scene=2 then player_xpos#=3450
if playerx#>2720 and playerx#<6810 and game_scene=3 then player_xpos#=2725
if playerx#>4700 and playerx#<8258 and game_scene=4 then player_xpos#=4700
if playerx#>2650 and playerx#<6820 and game_scene=5 then player_xpos#=2650
if playerx#>4356 and playerx#<7618 and game_scene=6 then player_xpos#=4390
if playerx#>3240 and playerx#<8100 and game_scene=7 then player_xpos#=3240
if playerx#>4350 and playerx#<9370 and game_scene=8 then player_xpos#=4750
if playerx#>4790 and game_scene=1 then player_xpos#=4790
if playerx#>6100 and game_scene=2 then player_xpos#=6170
if playerx#>6810 and game_scene=3 then player_xpos#=6810
if playerx#>8258 and game_scene=4 then player_xpos#=8258
if playerx#>6820 and game_scene=5 then player_xpos#=6820
if playerx#>7618 and game_scene=6 then player_xpos#=7710
if playerx#>8100 and game_scene=7 then player_xpos#=8100
if playerx#>9370 and game_scene=8 then player_xpos#=9600
[/pbcode]
To execute this tiny fragment, the code is one big fixed cost operation. In other words, no matter what
game_scene is equal to, it's falling through at least 96 operations. We can reduxe that by grouping the code into blocks that act upon
game_scene Ex.. So we grab the expressions that compare
game_scene and pull them together.. Making this,
[pbcode]
if playerx#<2940 and game_scene=1 then player_xpos#=550
if playerx#>2940 and playerx#<4790 and game_scene=1 then player_xpos#=2940
if playerx#>4790 and game_scene=1 then player_xpos#=4790
if playerx#<3400 and game_scene=2 then player_xpos#=550
if playerx#>3400 and playerx#<6100 and game_scene=2 then player_xpos#=3450
if playerx#>6100 and game_scene=2 then player_xpos#=6170
etc etc..
[/pbcode]
If we screen on the leve, we cut the work load in half.
[pbcode]
if game_scene=1
if playerx#<2940 then player_xpos#=550
if playerx#>2940 and playerx#<4790 then player_xpos#=2940
if playerx#>4790 then player_xpos#=4790
endif
if game_scene=2
if playerx#<3400 then player_xpos#=550
if playerx#>3400 and playerx#<6100 then player_xpos#=3450
if playerx#>6100 then player_xpos#=6170
endif
if game_scene=3
if playerx#<2720 then player_xpos#=550
if playerx#>2720 and playerx#<6810 then player_xpos#=2725
if playerx#>6810 then player_xpos#=6810
endif
if game_scene=4
if playerx#<4700 then player_xpos#=550
if playerx#>4700 and playerx#<8258 then player_xpos#=4700
if playerx#>8258 then player_xpos#=8258
endif
if game_scene=5
if playerx#<2650 then player_xpos#=550
if playerx#>2650 and playerx#<6820 then player_xpos#=2650
if playerx#>6820 then player_xpos#=6820
endif
if game_scene=6
if playerx#<4356 then player_xpos#=550
if playerx#>4356 and playerx#<7618 then player_xpos#=4390
if playerx#>7618 then player_xpos#=7710
endif
if game_scene=7
if playerx#<3240 then player_xpos#=550
if playerx#>3240 and playerx#<8100 then player_xpos#=3240
if playerx#>8100 then player_xpos#=8100
endif
if game_scene=8
if playerx#<4350 then player_xpos#=550
if playerx#>4350 and playerx#<9370 then player_xpos#=4750
if playerx#>9370 then player_xpos#=9600
endif
[/pbcode]
This version now only falls through 16 operations (8 compares and 8 IF branches). When a match is met, it's falling through another 8 operations in the that branch. So about 24 operations in total.
This type of chunk of code could replaced with typed array really, but my point is these little code redundancies have a very nasty habit of building up and chewing through extra processor time. If you have say only 100 characters in a level and there's say wasted 100 operations updating each character each frame, than that's easily 10000 operations going down the drain.
Here's an example of a calculation redundancies,
[pbcode]
ThisTile = PeekLevelTile(Mymap,fences ,(playerx#-32)/64,(playery#-32)/64)
ThisTile2 = PeekLevelTile(Mymap,platform ,(playerx#-32)/64,(playery#+32)/64)
ThisTile3 = PeekLevelTile(Mymap,front ,(playerx#-32)/64,(playery#-32)/64)
ThisTile4 = PeekLevelTile(Mymap,trees ,(playerx#-32)/64,(playery#-32)/64)
[/pbcode]
So here we're computing the Tile the player is over every time we peek the level. So there's 4 operations to compute the X/Y coordinate once. So the fragment is at least 20 operations.
[pbcode]
PlayerTileX#=(playerx#-32)/64
PlayerTileY#=(playery#-32)/64
ThisTile = PeekLevelTile(Mymap,fences ,PlayerTileX#,PlayerTileY#)
ThisTile2 = PeekLevelTile(Mymap,platform ,PlayerTileX#,(playery#+32)/64)
ThisTile3 = PeekLevelTile(Mymap,front ,PlayerTileX#,PlayerTileY#)
ThisTile4 = PeekLevelTile(Mymap,trees ,PlayerTileX#,PlayerTileY#)
[/pbcode]
Now we're down to about 10 operations.
In this loop, we're reading the sprite index and pulling the image from the 3 times more than is necessary.
[pbcode]
for each mp()
if getspriteimage (mp.sprite)=311 or getspriteimage (mp.sprite)=301 then spriteimage mp.sprite,310
if getspriteimage (mp.sprite)=361 then spriteimage mp.sprite,360
next
[/pbcode]
ie.
[pbcode]
for each mp()
ThisSprite=mp.sprite
ThisImage=getspriteimage (ThisSprite)
if ThisImage=311 or ThisImage=301 then spriteimage ThisSprite,310
if ThisImage=361 then spriteimage ThisSprite,360
next
[/pbcode]
Reading the sprite Index into a variable, means we don't have to query the list structure every time, same with the reading the image index. So there two less function and two less type reads at least. More if there's a match. Calling a function is one of the slowest things a program can do in management loop like this, as even though the call has a tiny cost, it's quickly magnified the more iterations of the loop that are required.
This same type of redundancy error occurs in the update routine here...
[pbcode]
for each dogs()
if dogs.object=chr_fish or dogs.object=chr_snail or dogs.object=chr_dog or dogs.object=chr_gamekeeper or dogs.object=chr_fire or dogs.object=chr_blades
dogs.oldorbit#=dogs.orbitx#
dogs.thisangle#=dogs.Angle#
dogs.orbitx#=dogs.mx#+(Cos(dogs.thisangle#)*dogs.RadiusX#)
dogs.orbity#=dogs.my#+(Sin(dogs.thisangle#)*dogs.RadiusY#)
positionsprite dogs.sprite,dogs.orbitx#,dogs.orbity#
dogs.Angle#=WrapAngle(dogs.Angle#,dogs.spd_rotate#)
endif
Select Dogs.object
etc etc
[/pbcode]
This is pulling the Object type from
dogs.object at least 7 times per object..
[pbcode]
ObjectType=Dogs.Object
if ObjectTYPE=chr_fish or ObjectTYPE=chr_snail or ObjectTYPE=chr_dog or ObjectTYPE=chr_gamekeeper or ObjectTYPE=chr_fire or ObjectTYPE=chr_blades
dogs.oldorbit#=dogs.orbitx#
dogs.thisangle#=dogs.Angle#
dogs.orbitx#=dogs.mx#+(Cos(dogs.thisangle#)*dogs.RadiusX#)
dogs.orbity#=dogs.my#+(Sin(dogs.thisangle#)*dogs.RadiusY#)
positionsprite dogs.sprite,dogs.orbitx#,dogs.orbity#
dogs.Angle#=WrapAngle(dogs.Angle#,dogs.spd_rotate#)
endif
Select ObjectTYPE
etc etc
[/pbcode]
This executes about 40-45% faster.
But it's quicker to pull the state from an array, gets rid of the any calculations and just pre computes it..
[pbcode]
; character states
Constant chr_dead =1
Constant chr_snail =2
Constant chr_fish =3
Constant chr_dog =4
Constant chr_split =5
Constant chr_gamekeeper=6
constant chr_bullet =7
constant chr_fire =8
constant chr_blades =9
; table of what objects use the Swing controller AI
Dim Use_Swing_AI(100)
Use_Swing_AI(chr_fish)=true
Use_Swing_AI(chr_snail)=true
Use_Swing_AI(chr_dog)=true
Use_Swing_AI(chr_gamekeeper)=true
Use_Swing_AI(chr_fire)=true
Use_Swing_AI(chr_blades)=true
; Dog up type
Type TDog
Object
EndTYpe
DIm dogs as tDog list
For lp =0 to 100
Dogs =New tDog
T=Rndrange(chr_snail,chr_blades)
Dogs.object=t
next
Do
cls
frames++
startinterval 0
Counter=0
for each dogs()
if dogs.object=chr_fish or dogs.object=chr_snail or dogs.object=chr_dog or dogs.object=chr_gamekeeper or dogs.object=chr_fire or dogs.object=chr_blades
Counter++
endif
Select dogs.object
endselect
next
t1#+=EndInterval(0)
print t1#/frames
print Counter
startinterval 0
Counter=0
for each dogs()
ObjectType=Dogs.Object
if ObjectTYPE=chr_fish or ObjectTYPE=chr_snail or ObjectTYPE=chr_dog or ObjectTYPE=chr_gamekeeper or ObjectTYPE=chr_fire or ObjectTYPE=chr_blades
Counter++
endif
Select ObjectTYPE
endselect
next
t2#+=EndInterval(0)
print t2#/frames
print Counter
startinterval 0
Counter=0
for each dogs()
ObjectType=Dogs.Object
if Use_Swing_AI(ObjectTYPE)
Counter++
endif
Select ObjectTYPE
endselect
next
t3#+=EndInterval(0)
print t3#/frames
print Counter
Sync
loop
[/pbcode]
Hi All
ok thanks Kevin , I see what you mean about the more operations in all the examples , I seemed to have used this way of doing it
for each mp()
if getspriteimage (mp.sprite)=311 or getspriteimage (mp.sprite)=301 then spriteimage mp.sprite,310
if getspriteimage (mp.sprite)=361 then spriteimage mp.sprite,360
next
quite a bit in different ways in different parts of my code and the logic if player#>550 and game_scene =1 etc , I see how it can make more operations
I will go through my code and change it to a more practical way of being calculated
as for the background scrolling I see what you are saying there to , I would have not had a clue how to do it this way , I will go through your example later on as well
I can see that all this will squeeze out a few extra frames , which all helps
mick :)
The easy way is to load up the pictures in your favourite paint package clip them off, which is a better solution than loading into memory then clipping them in the program.
Quote
I can see that all this will squeeze out a few extra frames , which all helps
On newer systems it might only win back a few extra frames, it's the older systems that will benefit the most.
That's coming along very nicely,bloody tricky though!!!
Hi all
thanks monkeybot , cant make it to easy you will do all the levels in 5 mins lol , but then again not impossible , well its all done apart from full testing and slight game alterations to maybe make it a tad easier , properly in the way of energy top-up when a level is complete , so I will post full game tomorrow I would have thought or day after depending how long testing takes
BlinkOk if you have a look at it and see if we need any gfx's touches to it , maybe at end of level when it says well done action continues you might want to change txt gfx or something
mick :)
will do mick
Hi all
well well at last nearly a year and I have a fully playable game for testing , made it slightly easier by getting an extra life when level is complete max 3 lives and you start with full energy bar
some sounds still need finding and replacing , but this takes time to find them , please have a good play and see what you think
there is a screenvsync toggle on main screen before you start use F1 and F2 keys to toggle , will show in upper left corner of screen
you will not master straight away but over time is fairly straight forward
download here
http://rghost.net/48370855
password is playbasic
run For Foxes Sake.exe
will post code once a bit tidy up
mick :)
Hi All
Hi BlinkOk , wondered if you had a chance to have a play and if you thought there was any code or gfx's changes that you might want me to do ?
I will over the next week round game off fully , but job hunting is my main goal at the moment , not easy at my age
will get around to starting a xmas project I think , hopefully this xmas lol
well would like to thank a lot of people on here for helping me get this game to how it is now , BlinkOK being one of them for all the gfx's
without you all would not been as good as it is
hopefully some people will see just how good Playbasic is , even a novice like me can do something like this with help from forums of course
not the best game in the world , but seen a lot worse on android market that's for sure
mick :)
no worries mick. i'm a bit busy atm. prolly get around to it at the end of the week or on the weekend. hope that's not too late.
as always it's a pleasure to work with you mick. always fun and easy going. looking forward to more of it in the future
just had a crack at it. the sounds are fantastic! really nice.
I've finish first level then i get House what can i do to get next level?
Hi All
ATLUS , when you have all 100 coins the house door opens just go in and keep walking , next level will load
BlinkOk , Yep hard to find some good sounds , will look to see if I can find 4 sounds for the background of each ie fire , snow , grass , building
mick :)
It's turned out pretty good, certainly well worth a play through..
I did it, thanks micky4fun, very nice game!
Hi All
QuoteI did it, thanks micky4fun, very nice game!
Thanks ATLUS , well you have another 7 levels to do lol , most of the enemies are using your 2d orbit snippet , so if they get you its only your own fault lol
mick :)
Mick,
Can you post a bundle of say 8 or so screen shots (png) from the final game, including the levels, intro bits and pieces.. Just zip them up and attach them here.
Hi All
WARING , a playsound command on level 5 of release with no attached sound will end game , oops sorry , sould have tested longer
this is now fixed !
Kevin , here are some screenies of the levels and score entry screen , I will post an update of game later today or tomorrow with some extra tracks of background music added as well as playsound fix
then I think its done unless BlinkOK wants me to ad anymore ,
mick :)
is there a link for the fix?
Hi all
yep BlinkOk , here is the fully working game with 3 extra stage music tracks , will now tidy code up a liitle and post code
will also try and upload a few videos to show how to make it a bit easier , its fairly easy now anyway , I complete all levels with still 3 lives
heres link
http://rghost.net/48521062
password playbasic
then press get link and it appears below
mick :)
i get this...
ERROR
The requested URL could not be retrieved
While trying to retrieve the URL: http://rghost.net/48521062
The following error was encountered:
Zero Sized Reply
Squid did not receive any data for this request.
Generated Sun, 01 Sep 2013 21:01:17 GMT by pcl-iwfcache03.plus.net (squid)
worked ok for me monkey dude. maybe you miss typed the password or something
cant even get to download the file blink.
just tried again...
weirdeties
Hi all
monkeybot , I just tried link seems fine , maybe your browser ?
in password box type playbasic
then press get file
then it will disappear and display download as show in picture , then press download and that's it
mick :)
p.s anyone can download this even if you don't have playbasic , its a stand alone .exe
*deleted*
Thanks mick.That one worked
Very nice Mick it plays very well and nice one of the gfx blinkOk!!
Top Banana!!!
Hi all
well did not get much time to tidy up code as I have managed to get a job in retail , gone down the ladder a bit , but hey its a job , so some studying to do over the next few weeks , hope I can hold it down
anyway thought I would post code as is so if anyone wants to amend it or just skip levels they can
level can be skipped by altering lines 315 and 316 just type in level number , but game will start with the start platform so will look a little odd
right thanks again to all that helped on this game and hopefully in a few weeks get back into doing something for xmas
same password as before playbasic
http://rghost.net/48643591
mick :)
sorry i haven't gotten to this yet :-(
congratz on the job though and good luck with it
Hello Mick, hello BlinkOK!
Great funny game! Congratulations! This was a very fertile teamwork! :)
It is so difficult to find good artwork which is free in use.
My little sun loves the game too! Of course I know how much work it was!
And there are no many programmers who really finish a game.
Good luck with you new job! I hope you will still have time for coding and further
projects ;)
Best wishes!
Sigtrygg
hey mick, is it ok if i post this over at tigsource?
Hi BlinkOk
yep mate post where ever you like , its as much as everyone's game on the forums as mine and you did most the work I would have thought with all the gfx's
got most the coding off of other members help / contributions
mick :)
still have not finished this puppy! i get an error on the second lava level. did not get to print the message but i think it's a boundary error (i was jumping off the top of the screen)
the line number is in the screen shot.
Hi all
Thanks BlinkOk for finding this error , a cap I forgot to put in if the player ends up on very top of screen and jumps over laver falls
so if you edit that line to this
if on_platform=1 and playery#>59 then ThisTile5 = PeekLevelTile(Mymap,coins,(playerx#-32)/64,(playery#-60)/64)
so really just inserting" and playery#>59 " this will stop this error happening , so you will have to re-compile game to get a bug free .exe
hope this helps ,
Quotestill have not finished this puppy
lol you will do it, I find it quite easy now and do it with all 3 lives still intacked ,
mick :)
no worries. thanks mick
added a FFS (http://www.underwaredesign.com/?page=programs.For-Foxes-Sake) page on UW the other day.
Hi All
Thanks Kevin , great stuff , with more time and effort probably could have made it better , but it did seem to go on for ages getting this one out , anyway its done now
mick :)
Hi all
Thought i would let you know i have put 7 of my games up at
http://gamejolt.com/profile/micky4fun/112285/
I av altered some to make them more playable or eaiser
I will upload a few more of them in a day or two
Mick
How many are there now ?? Must be around over ten.. I noticed the other day, some of the off site links to your older games like "let it be" are now dead. It's probably time you got your web site up and running. At least then there's one place to find your stuff.
Hi all
well its about 13/14 I think , but some are quite simple and probably not worth counting , think I will get about 10 onto that site that's worth playing for a bit
gave me a chance to round them all up as I had to dig some of them out myself , and one I lost lucky enough a mate had a copy
as for my own site , It would be very basic and just pointing anyone to another site seems the easy way for me lol
I will now burn them all to a cd so I have a copy myself of them all
thought also it may show a few other people what can easily be down in PB , seems the few people I have spoke to on that site has never heard of it , which is a shame :(
also the people I did speak to seemed very keen on an one click multi platform programing program , which maybe seems the way things are these days
with all the phones and tablets about.
mick :)
QuoteIt would be very basic and just pointing anyone to another site seems the easy way for me
Doesn't need to be complicated. Grab an off the shelf template, draw up some logos and write some copy. The generation can be done in PB and just upload the static pages. Writing the copy is probably the most time consuming part of it. For downloads you can still have them hosted all over, at least then there's a single place people can find your stuff.
Quote
also the people I did speak to seemed very keen on an one click multi platform programing program , which maybe seems the way things are these days
with all the phones and tablets about
There's loads of the them out there, always has been. It's much easier for people to click together something in a high level designer write it from scratch.
you got a couple of reviews over at gamejolt. the second one is quite funny too. havent checked the first one yet (http://gamejolt.com/games/platformer/for-fox-s-sake/18050/)
doing a C# course. hoping to learn unity and mono game eventually. we are learning xna right now.
as a project i did a platform editor for "for fox sake". it doesn't output in a format for micks game yet. i hope to do that after the course.
if you have a look in the levels/level1 directory there is a file called "garden_world.wlf". this file contains definitions for all the graphics in the level so as long as you conform to the 64x64 tile size you can substitute (or add) any graphics you want.
all in all it's very rudimentary and buggy
http://www.mediafire.com/download/oqp1gptsw60oh3b/platform_editor.zip (http://www.mediafire.com/download/oqp1gptsw60oh3b/platform_editor.zip) (windows only sorry)
xna is an obsolete api but if you would like to have a look at it all the components are free;
Visual c# express 2010
http://www.visualstudio.com/en-us/downloads#d-2010-express (http://www.visualstudio.com/en-us/downloads#d-2010-express)
XNA gamestudio 4.0
http://www.microsoft.com/en-au/download/details.aspx?id=23714 (http://www.microsoft.com/en-au/download/details.aspx?id=23714)