Welcome, Guest. Please login or register.

Login with username, password and session length

 
Advanced search

1411281 Posts in 69324 Topics- by 58380 Members - Latest Member: bob1029

March 28, 2024, 09:32:21 PM

Need hosting? Check out Digital Ocean
(more details in this thread)
TIGSource ForumsCommunityDevLogsChain Diver
Pages: 1 [2] 3
Print
Author Topic: Chain Diver  (Read 5087 times)
EmilMeiton
Level 0
***



View Profile
« Reply #20 on: July 31, 2020, 04:54:28 AM »

I'm reviving this from the grave.

Revamped the whole algorithm and have a new idea that I think will work nicely to bring everything together.

The algorithm is the same for most of it but written in a more optimized and hopefully easy to read way.

New idea/concept is someting I'll probably post about soon enough but I'd like to add some complementary visuals once I do.

In the meantime. Here's a working prototype exported to webgl from unity:
http://emilmeiton.com/Sweeper/1/index.html
Controls are just keyboard arrows at the moment. You try to get to the pink square.

The prototype is a very basic first step but I feel it important to have something to playtest early!
If you find anything you suspect is a bug please tell me!
Logged
EmilMeiton
Level 0
***



View Profile
« Reply #21 on: August 02, 2020, 09:56:59 AM »

Very small update but I implemented - what I call - a chain mechanic. Basically it means you can backtrack on your path/chain which will be relevant later for score counting (smaller chain/path equals more points).

I'm taking time from when my one year old is sleeping to get some work done on this game. As long as I keep the habit I think it'll work out!

Here you can try the chain mechanic:
http://emilmeiton.com/Sweeper/2/index.html
Controls are still just arrow keys on your keyboard.
Logged
EmilMeiton
Level 0
***



View Profile
« Reply #22 on: August 29, 2020, 12:56:16 AM »

Started to experiment with the visuals of the game. Going for very few colors and low resolution so that I don't spend too much time at this stage. I think it'll be enough to see if I can make the game fun.

It's still very much a work in progress. I just doodled some clouds out for example and I'm not happy with the "stones" in the level yet. But I feel confident in a lot of what's happening here. I'm curious if y'all have any thoughts or ideas!

The idea is to flesh out the visuals with these heavy constraints and once I can make myself happy with this (and those playtesting) I'll look into making more advanced graphics (adding more colors or even going vector/3D if it seems nice)
Logged
EmilMeiton
Level 0
***



View Profile
« Reply #23 on: August 29, 2020, 10:06:31 AM »

Slight update

Testing out other colors, improved look of the "sky background", removed gradient and tweaked the blocks below
Logged
JobLeonard
Level 10
*****



View Profile
« Reply #24 on: August 29, 2020, 10:16:33 AM »

I love the style of the last two updates! Got completely stuck in the demo, should I be able to collect all red dots with the right path?
Logged
EmilMeiton
Level 0
***



View Profile
« Reply #25 on: August 29, 2020, 10:26:21 AM »

Thanks!

No the red dots are mines/deathtraps. If you go into them you restart the level. If you mean the orange spheres they are "stickies" that you get stuck on top of.

I do want to add a "counter" which will tell you the optimal amount of steps to solve a level. So you can try and aim for the highest score Smiley

I also experimented with some vignette and glow in photoshop but to not have a wall of almost the same picture in the thread I'll hide it in a regular link:
http://emilmeiton.com/Sweeper/4colorLevelTest5.jpg?fbclid=IwAR3yosiFlQg7X_c8E8UtSyDzWm-bvIhYClhVExsPnAR3mnYIs_35jkign5Q
Logged
JobLeonard
Level 10
*****



View Profile
« Reply #26 on: August 29, 2020, 11:42:09 AM »

I probably should mention tha I'm red-green color blind, heh... Wink

Ah, going for that CRT phosphorous afterglow look I see?
Logged
EmilMeiton
Level 0
***



View Profile
« Reply #27 on: August 29, 2020, 02:59:02 PM »

Maybe going for it. Well see.. If I add colors in the future it doesn't make much sense to do it though.

I hope to make the game work with less colors first and then we'll see Smiley
Logged
EmilMeiton
Level 0
***



View Profile
« Reply #28 on: September 06, 2020, 03:09:52 PM »

Was thinking about how to get the "move counter" implemented. Since I calculate how many steps are the optimal amount to get to the goal I wanted to incorporate that into the game somehow. I think this is important to increase the challenge... Like beat it with this amount of moves and get extra points.

Meanwhile I made a slightly newer version of the graphics were I added some bends to the chain (like if some moves have occured) shown here:
and I realized that the 90 degree bends of the chain looked a bit off.

Then it occured to me that I could have the player character add small cogwheels at any empty space it landed on (thus connecting the cog to the chain which explains the 90 degree bends somewhat). And instead of counting how many moves you do you count how many cogs you are placing in the level!
I also realized that the "permanent" cogs (that I formerly called stickies since you get stuck on top of them) are adding an extra layer of complexity to the game since you don't add any cogs on top of them (since they are already there).

I just implemented that in my prototype:
http://emilmeiton.com/Sweeper/5/index.html
Would love to hear your thoughts if you try the latest prototype and how you percieve the challenge of keeping your "cog count" as low as possible
Logged
JobLeonard
Level 10
*****



View Profile
« Reply #29 on: September 07, 2020, 04:26:24 AM »

I think the confusing bit is that people might want to try to collect all the cogs in the level.

Also, currently the number of used cogs is persistent across levels, which would break the whole scoring mechanism: if I finish the first one with nine cogs instead of the minimal six, it's already impossible to finish the second level with the minimum number of cogs.

Also, obviously this is a prototype, but in a real game it would be nice to be able to immediately retry a level if you finish it, or even better: undo your last few moves Baba Is You style so you can try to find a more efficient path.

I think it works well otherwise, because I had a few minutes where I thought the level was impossible before solving it!
Logged
EmilMeiton
Level 0
***



View Profile
« Reply #30 on: September 07, 2020, 09:24:42 AM »

Hmm.. That people might want to collect them is a problem. Maybe I have to introduce them carefully or perhaps change them to some other graphics.

The persistence is a bug. It resets as soon as you make a move.

Since I'm aiming for mobile/touch screens I'm not exactly sure how to do retry and undo but it's something I'll definitely try to accomodate

I'm glad you think it works otherwise!
Logged
EmilMeiton
Level 0
***



View Profile
« Reply #31 on: September 23, 2020, 01:58:14 AM »

Another small update:
- Removed courotine from movement and implemented it straight into update loop (smoother)
- Added some graphics

As usual you can try it out here:
http://emilmeiton.com/Sweeper/6/index.html
Logged
JobLeonard
Level 10
*****



View Profile
« Reply #32 on: September 23, 2020, 02:55:50 AM »

I was trying to give it a spin, but Unity seems to think that my Firefox doesn't support WebGL. Which is factually wrong :/

EDIT: Today I learned that when my laptop is unplugged, the power-saving mode disables WebGL Waaagh!

And Chromium didn't far much better:



The weird thing is that all the previous versions work just fine
« Last Edit: September 23, 2020, 03:04:02 AM by JobLeonard » Logged
EmilMeiton
Level 0
***



View Profile
« Reply #33 on: September 23, 2020, 09:12:20 AM »

Ah, I did an update to the movement.

For those that know unity and c# I basically moved my code from a coroutine to the update event instead. But I made an error (that looks fine on my computer) and I'll need to fix the code to get rid of that jitter thing. Thanks for reporting it to me!
Logged
EmilMeiton
Level 0
***



View Profile
« Reply #34 on: September 26, 2020, 10:23:05 AM »

So, I've now updated the code.  Smiley

What I had before was something akin to:
1 calculate a list of cells that the player is going to move through.
2 move closer to next cell in list.
3 Check if you're close enough to next cell and, if true, go to the one after that one
4 Repeat steps 2-3 until you're finished.

That code was very bad (I thought it was "good enough" since it looked OK on my end  Durr...?) and what happened was that the player moves closer to the next cell but moves so quickly that it skips step 3 and is stuck trying to move closer every frame (making it look like it vibrates).

I've now changed it (just refresh the same page as before) so that for each move you make I have a function that will position the player along the "path" of that move by a fraction value (between 0 and 1) and removing the whole nonsense about being "close enough" to a cell altogether.
Logged
JobLeonard
Level 10
*****



View Profile
« Reply #35 on: September 27, 2020, 06:20:24 AM »

The first version feels a bit overengineered, yeah Who, Me?
Logged
EmilMeiton
Level 0
***



View Profile
« Reply #36 on: October 02, 2020, 01:35:02 PM »

Time for another small update!

I spent some time on improving controls:
- mouse and touch input now possible
- while player is moving you can make an extra move that will be executed once the player has reached its destination

Most of my time was spent on the chain movement though. It was much much harder to code than I anticipated. Right now the chain will expand and contract according to the movement of the player and if you "cut" a point in the chain it will contract to that point (hard to explain but try the newest build and you'll see what I mean if you experiment). Lots of edge cases in the code and instead of trying to make the easiest to read and most performant code I've basically been patching it up as I went along. Maybe not the smartest move but I only have so little time to work on this and it seems to be working now so...  Shrug

Next thing is probably to try and make some kind of animated graphics for the chain... Not really looking forward to it since it seems daunting (especially considering how much trouble I was having with that part of the code so far)

But I'm being hopeful it wont be as bad as I imagine!  Smiley

Here's the latest build:
http://emilmeiton.com/Sweeper/9/index.html
Logged
JobLeonard
Level 10
*****



View Profile
« Reply #37 on: October 03, 2020, 04:18:13 AM »

I'll try it out on my tablet later! Smiley
Logged
EmilMeiton
Level 0
***



View Profile
« Reply #38 on: October 05, 2020, 11:39:18 AM »

So far it wasn't that bad. The chain looks alright for the most part here.
What's missing is animation on the chain. It's supposed to look like it's being dragged by the player and not the way it looks like right now. But that's the next thing on the list!  Hand Pencil

I also just noticed the chain will not look correct when you go into the goal/chest (on that move it will just fail to show up). Will try to fix that until next time as well.

http://emilmeiton.com/Sweeper/10/index.html
Logged
EmilMeiton
Level 0
***



View Profile
« Reply #39 on: October 07, 2020, 12:52:13 AM »

Found a LOT of bugs but I think the logic is sound for the chain now.
I also added teleporters in this build. Graphics for them are very wip. I'm thinking of making them look like some kind of underwater whirlpool in the end
http://emilmeiton.com/Sweeper/11/index.html

As long as I don't find any new bugs (I've been saying this like every couple hours since last update  Beg) it should be ok to start trying to implement animation on the chain.
That'll be a huge milestone for me since the chain feels like a very fundamental thing to get right
Smiley
Logged
Pages: 1 [2] 3
Print
Jump to:  

Theme orange-lt created by panic