Technical issues with my game

Get help using Construct 2

Post » Sat Jan 18, 2014 2:29 pm

https://www.dropbox.com/s/4wb280i50dyyk8x/Galah%20Panjang.capx

(Current progress of my game)

Firstly, I have tested my game on my tablet - a Nexus 7 - but it lags every time I play. From the debug, the frame rate is currently on 60fps. How to fix the lagging issue?

Secondly, how to bring score you gain from a level to the next and add them all up at the end of the game for highscore??

Thirdly, how to set animations with the Drag & Drop behaviour? Like when I drag my character up, I want it to animate walking forward animation.
B
6
Posts: 35
Reputation: 375

Post » Sat Jan 18, 2014 3:29 pm

Quick answers while I download your capx.

For every level create a global variable, level1score,level2score, etc.
Create a globalvariable totalscore and set it to level1score+level2score+.. etc.

You could have your animation play on isdragging, but I guess you'd want the player to face the direction of the drag. This can't be done by just the drag&drop behaviour, so it would be easier to drag an invisible sprite and give the player bullet-behaviour aim it at the dragging and move in the direction of the drag and use bullet behaviour speed is not 0 for doing the animation.

There are other solutions, but this one comes to mind quickly.

ok, download complete, let's check.
I told my dentist I had trouble with my teeth and asked her to fix it without looking in my mouth..
B
54
S
16
G
8
Posts: 6,160
Reputation: 19,775

Post » Sat Jan 18, 2014 4:04 pm

As for the performance:
You are using quite big sprites without there being a reason for it.
I'm not sure that's the issue, but it might be.
I told my dentist I had trouble with my teeth and asked her to fix it without looking in my mouth..
B
54
S
16
G
8
Posts: 6,160
Reputation: 19,775

Post » Sat Jan 18, 2014 4:11 pm

Also you are using a 13MB, nine and a half minutes long sound/music-file, seems a bit overkill to me.
I told my dentist I had trouble with my teeth and asked her to fix it without looking in my mouth..
B
54
S
16
G
8
Posts: 6,160
Reputation: 19,775

Post » Sat Jan 18, 2014 5:10 pm

[QUOTE=LittleStain]

For every level create a global variable, level1score,level2score, etc.
Create a globalvariable totalscore and set it to level1score+level2score+.. etc.[/QUOTE]

Do you mean local variable for the individual scores??

Also, the music files are something temporary I put in to test out. Haha. And since they are .wav files, they are kinda big. I made the visuals high-definition to get more marks in my grade :P

Unless I should reduce the resolutions to save file size??
B
6
Posts: 35
Reputation: 375

Post » Sat Jan 18, 2014 5:46 pm

With the music and graphics combined, your game already uses 50MB of memory or more before any actions are performed. Reducing that will never hurt performance.

When I say global variables, I mean global variables and not local variables, the difference between global variables and local variables is that global variables are global and local variables are local.

Global variables can be called everywhere in the game, so if you set level1score to the score the player recieved in level 1 at the end of level 1, you can use this score in level 2, to show the total score by adding the level1score and the level2score and so on.
I told my dentist I had trouble with my teeth and asked her to fix it without looking in my mouth..
B
54
S
16
G
8
Posts: 6,160
Reputation: 19,775

Post » Sat Jan 18, 2014 6:23 pm

Sorry, forgot music streams so it won't be in memory, but using 250x250 sprites where 2x2 sprites would work just as well (collision purposes) is a simple way to up the memory usage and I would recommend changing those.

I told my dentist I had trouble with my teeth and asked her to fix it without looking in my mouth..
B
54
S
16
G
8
Posts: 6,160
Reputation: 19,775

Post » Sun Jan 19, 2014 6:16 am

2x2 sprites? But I can still enlarge it enough for the layouts right? And if it's that small, the collision polygons will be smaller as well?? The current size makes collisions clunky - like the between the Characters and Enemy.:P


http://s220.photobucket.com/user/RedBrick17/media/Construct%202%20final%20year%20project/levelScoreamplevelComplete.png.html?sort=3&o=0

Is this how you meant by the levelScore??

Also:

http://s220.photobucket.com/user/RedBrick17/media/Construct%202%20final%20year%20project/activeLevelNumber.png.html?sort=3&o=1

I make the green Button to function on activating the next level. The thing is, after I finish the first level, it did bring me to the first level, but the second time around, it brought me back to the first level. Do I need to add "1" after the "activeLevelNumber"?

EDIT: I tried the On Dragging animation; still not working properly :P

http://i220.photobucket.com/albums/dd69/RedBrick17/Construct%202%20final%20year%20project/DragAnimation.pngPaletteRider2014-01-19 10:49:30
B
6
Posts: 35
Reputation: 375

Post » Mon Jan 20, 2014 1:20 pm

I have made some slight update on the Animation event - got the animation to work on 'IsDragging'. But, the angles to start the specific animations are still clunky. I'm not sure how to set the angles for the IsDragging...
B
6
Posts: 35
Reputation: 375

Post » Tue Jan 21, 2014 8:06 am

Bump
B
6
Posts: 35
Reputation: 375

Next

Return to How do I....?

Who is online

Users browsing this forum: No registered users and 6 guests