shmups.system11.org

Shmups Forum
 
* FAQ    * Search
 * Register  * Login 
It is currently Fri Apr 03, 2020 7:32 pm View unanswered posts
View active topics



Post new topic Reply to topic  [ 24 posts ] 
Author Message
 Post subject: WIP SHMUP : Learn basics
PostPosted: Mon Jan 13, 2020 5:10 pm 


User avatar

Joined: 13 Jan 2020
Posts: 16
Hello,

"A place for people with an interest in developing new shmups."

It seems that this forum is for me ! :)
I'm trying to learn basic skills to made a shmup in UNITY.
I'm not ready to make a whole game so i try to learn step by step the essentials mecanics.

Here is a video of my first attemps :

https://www.youtube.com/watch?v=DSTfL2oWIfc

Please tell me what i should do next !!!
Thanks !


Top
 Offline Profile  
 
 Post subject: Re: WIP SHMUP : Learn basics
PostPosted: Mon Jan 13, 2020 7:27 pm 


User avatar

Joined: 02 Oct 2019
Posts: 15
If you have learned from 0, then you have a very good progress.
The normal thing is to learn to create simple games before more complex projects, you know, learn to crawl before walking.
But in your case you are doing very well.
Congratulations.


Top
 Offline Profile  
 
 Post subject: Re: WIP SHMUP : Learn basics
PostPosted: Mon Jan 13, 2020 7:39 pm 


User avatar

Joined: 13 Jan 2020
Posts: 16
Thx hechelion !
Do you have ideas for my next steps ?


Top
 Offline Profile  
 
 Post subject: Re: WIP SHMUP : Learn basics
PostPosted: Mon Jan 20, 2020 6:44 am 


User avatar

Joined: 13 Jan 2020
Posts: 16
Here is a new video :
bullet & himing missile
https://www.youtube.com/watch?v=0_RF4wz33Jc

Is there a way to include the video directly in the post ?


Top
 Offline Profile  
 
 Post subject: Re: WIP SHMUP : Learn basics
PostPosted: Mon Jan 20, 2020 10:45 pm 


User avatar

Joined: 02 Oct 2019
Posts: 15
The behavior for that missiles look very nice. Congratulation.
The next step?
Learn it about shooters patterns, one thing is the physic of moving, but another thing is make good patterns.


Top
 Offline Profile  
 
 Post subject: Re: WIP SHMUP : Learn basics
PostPosted: Fri Jan 24, 2020 7:34 am 


User avatar

Joined: 13 Jan 2020
Posts: 16
thank you hechelion :)

I read some posts in the forum and i wonder how dealt with enemy spawning. Not just spawn enemies like a lot of tutorials i saw in YT but construct a full level.
As i know, i have two main choices :

1. Make a complete level in the scene who scrolls down to the player and activate enemies (and other prefabs if needed) just before they enter in the camera view.
pros : have a look on the level structure in the editor.
cons : place manually all prefabs at the right place in the scene.

2. Use a kind of timeline script generation (i don't know the right keyword to ask my friend google) to instanciate prefabs in a specific order based on time.
pros : I can easily create text file and test it in game. Have a direct look of what is fun to play. copy/paste interesting sequences to built a full level.
cons : At the moment, nothing because i really want to test it !!!!

I need your advices and if you have any ressources (videos, blogs ...) to make a level with timeline script generation, it will be AWESOME !!


Top
 Offline Profile  
 
 Post subject: Re: WIP SHMUP : Learn basics
PostPosted: Sat Jan 25, 2020 3:02 am 


User avatar

Joined: 02 Oct 2019
Posts: 15
Normally, is better load in memory only what you need so, the timeline script is a most efficient solution over load all enemies at the beginning.

My game used some similar to timeline, but is more scroll advance that time, I have a list or parameters, the first is the scroll position and the rest, are the parameters for the class constructor. So, the enemies always spawn in the same point.
The cons are you need a lot of imagination to build the level, and a lot of time to probe and improve. unless you make a GUI application for this.


Top
 Offline Profile  
 
 Post subject: Re: WIP SHMUP : Learn basics
PostPosted: Sat Jan 25, 2020 10:47 am 


User avatar

Joined: 13 Jan 2020
Posts: 16
hechelion wrote:
My game used some similar to timeline, but is more scroll advance that time, I have a list or parameters, the first is the scroll position and the rest, are the parameters for the class constructor. So, the enemies always spawn in the same point.


Could you share some lines of your code to have an idea of what it looks ?


Top
 Offline Profile  
 
 Post subject: Re: WIP SHMUP : Learn basics
PostPosted: Mon Jan 27, 2020 6:53 pm 


User avatar

Joined: 02 Oct 2019
Posts: 15
9uile wrote:
hechelion wrote:
My game used some similar to timeline, but is more scroll advance that time, I have a list or parameters, the first is the scroll position and the rest, are the parameters for the class constructor. So, the enemies always spawn in the same point.


Could you share some lines of your code to have an idea of what it looks ?


This is the routine that loads enemies in my game.
pLstInvoke is a sort list of a custom structure, where I have the "time" when the enemy will be loaded and information such as the enemy's ID, position and optional parameters that are passed to the enemy's constructor.

Code:
    Public Sub Logic(byVal Ptime as integer) Implements INTERLEVELS.Logic

        'llamada a carga de enemigos
        If pLstInvoke(pIndexInvoke).Time = pTime Then
            Do While pLstInvoke(pIndexInvoke).Time = pTime
                oScreen.LoadEnem(pLstInvoke(pIndexInvoke).ID, pLstInvoke(pIndexInvoke).posX, pLstInvoke(pIndexInvoke).posY, pLstInvoke(pIndexInvoke).Param, pLstInvoke(pIndexInvoke).MinRank, pLstInvoke(pIndexInvoke).NeedBoss, pLstInvoke(pIndexInvoke).Cadena)
                pIndexInvoke += 1
                If pIndexInvoke >= pLstInvoke.Count() Then pIndexInvoke = 0
            Loop
        End If
    End Sub


Top
 Offline Profile  
 
 Post subject: Re: WIP SHMUP : Learn basics
PostPosted: Tue Jan 28, 2020 9:59 am 


User avatar

Joined: 15 Mar 2012
Posts: 996
Is this your actual code?

What scripting language are you using? I thought you were working in Unity so I would expect to see C# given the year as Unity have pretty much deprecated js/boo/unityscript
_________________
facebook: Facebook twitter: n0rtygames


Top
 Offline Profile  
 
 Post subject: Re: WIP SHMUP : Learn basics
PostPosted: Fri Jan 31, 2020 5:11 pm 


User avatar

Joined: 02 Oct 2019
Posts: 15
n0rtygames wrote:
Is this your actual code?

What scripting language are you using? I thought you were working in Unity so I would expect to see C# given the year as Unity have pretty much deprecated js/boo/unityscript


Nop. I don't use Unity. My game is programming over Visual Basic .NET with SFML library. I like to move to C# with core, but first I like to end "Evorales".


Top
 Offline Profile  
 
 Post subject: Re: WIP SHMUP : Learn basics
PostPosted: Fri Jan 31, 2020 5:42 pm 


User avatar

Joined: 13 Jan 2020
Posts: 16
I now understand why i didn't understand your code. :D


Top
 Offline Profile  
 
 Post subject: Re: WIP SHMUP : Learn basics
PostPosted: Mon Feb 24, 2020 4:13 pm 


User avatar

Joined: 13 Jan 2020
Posts: 16
Hello, i want to recreate bullets cancel : e.g. when an enemy is killed, all these his bullets (and only hers) are dying. How to achieve this when there's a lot of bullets an enemies on screen ? (unity, c#)


Top
 Offline Profile  
 
 Post subject: Re: WIP SHMUP : Learn basics
PostPosted: Thu Feb 27, 2020 6:53 pm 


User avatar

Joined: 21 Apr 2012
Posts: 337
Location: West Coast, Canada
9uile wrote:
Hello, i want to recreate bullets cancel : e.g. when an enemy is killed, all these his bullets (and only hers) are dying. How to achieve this when there's a lot of bullets an enemies on screen ? (unity, c#)


In VariaBULLET2D I put this into the system with a simple custom shot modification. A demonstration of the "BulletsToCoins" example:

Image

Of course you can convert the bullets to anything (or repool, or destroy) just as easily.

This is the code used in VariaBULLET2D to make it happen. Obviously it depends on the other code in the system, but might help you figure out how to do it on your own. Coin object is set in the inspector for this shot prefab:

Code:
    public class CoinOnDestroyed : ShotLinearNonPhysics
    {
        public GameObject Coin;

        public override void Update()
        {
            base.Update();

            OnEmitterDestroyedDoOnce(
                shot => {
                    GameObject coin = GameObject.Instantiate(Coin);
                    coin.transform.position = shot.transform.position;
                    coin.transform.rotation = shot.transform.rotation;

                    RePoolOrDestroy();
                }
            );
        }
    }



If you have a ton of bullets that might cancel like this, it'll probably be more performant instead of instantiating/destroying (which is costly in large amounts on a single frame) to have a separate set of frames defined in the inspector, that replace the previous animation frames (turning them into "coins" or whatever)... along with a secondary shot behavior script which is disabled until the conversion occurs, at which point you just disable the previous shot script type and enable the new one (to move the converted shot in some different manner than the original shot).
_________________
ATTN GameDevs: Easily make BULLET HELL patterns visually with VariaBULLET2D!


Top
 Offline Profile  
 
 Post subject: Re: WIP SHMUP : Learn basics
PostPosted: Thu Feb 27, 2020 7:26 pm 


User avatar

Joined: 13 Jan 2020
Posts: 16
That’s nice !! I’m still working on my script and it’s almost finished. I hope...
The way i proceed is :
When an enemy is instanciate, i create a enemyID and mark each emitted bullet.
Then, just before the death of enemy, i launch a function to destroy bullets marked with this id.
My code is messy at the moment but each day a little step. :)


Top
 Offline Profile  
 
 Post subject: Re: WIP SHMUP : Learn basics
PostPosted: Fri Feb 28, 2020 2:20 pm 


User avatar

Joined: 13 Jan 2020
Posts: 16
I would like to work a bit on design. Just before, i wonder which resolution screen i have to choice. I want to avoid size error doing my pixel art because i'm not an artist. Currently i use the pixel perfect camera (in unity)with these settings. I'm not sure if it's good.

Assets pixels per unit : 16
reference resolution x480 y270
upscale render text : not checked
pixel snapping : not checked
Crop Frame : x and y checked
strech fill : not checked

If someone accurate knows, please tell me :)
Thanks


Top
 Offline Profile  
 
 Post subject: Re: WIP SHMUP : Learn basics
PostPosted: Sun Mar 01, 2020 5:30 pm 


User avatar

Joined: 21 Apr 2012
Posts: 337
Location: West Coast, Canada
I always use a pixel per unit (PPU) of 10. For me it's easier to do a bit of mental math when keeping .1 unit = 1 pixel. (if wondering why not just go 1PPU, it's overkill and I've heard is bad for correctly generating physics although not sure if it's a myth or not).

Other than that, I haven't really used the "pixel perfect" camera as I've (over many years) tried many "pixel perfect" setups in Unity, including making my own, and at every point I was disappointed with something that resulted in far from pixel perfect behavior.

But I haven't totally written it off yet. I have a project I'm working on where I have the option to project the camera to a quad, and then scale it up to keep those nice chunky pixels.

But there is a bit of "shimmering" that happens when the pixels don't perfectly land on the grid, producing a subtle aliasing type effect which is visible as shimmering.


I may end up leaving it in as a user enabled "pixel snap" setting, but beyond that I've learned to make peace with the not-so-pixel-friendly nature of Unity.
_________________
ATTN GameDevs: Easily make BULLET HELL patterns visually with VariaBULLET2D!


Top
 Offline Profile  
 
 Post subject: Re: WIP SHMUP : Learn basics
PostPosted: Tue Mar 03, 2020 8:56 am 


User avatar

Joined: 13 Jan 2020
Posts: 16
I still don't know how to choose my ref resolution...
x480 y270 seems to be good to use the full size of an hd screen.
But...
If i want to use a resolution playable on a 1080p hd screen (yoko and tate) and on an arcade monitor (tate), is this resolution the better choice ?
x810 y1080 (ratio 3:4)

I would like to be sure about resolution before starting design, art and so on...


Top
 Offline Profile  
 
 Post subject: Re: WIP SHMUP : Learn basics
PostPosted: Wed Mar 04, 2020 3:27 am 


User avatar

Joined: 21 Apr 2012
Posts: 337
Location: West Coast, Canada
I hear you. I was in the same circumstance recently when starting a vertical shmup project which will end up on lots of platforms, from mobile to console to PC, so I had to set my initial resolution first before doing anything else.

I settled on 480x270 as it scales well in all of the typical HD resolutions and allows the base pixel count I'm looking for.
_________________
ATTN GameDevs: Easily make BULLET HELL patterns visually with VariaBULLET2D!


Top
 Offline Profile  
 
 Post subject: Re: WIP SHMUP : Learn basics
PostPosted: Wed Mar 04, 2020 6:05 am 


User avatar

Joined: 13 Jan 2020
Posts: 16
We are almost two having this res ! (480*270) :)
Do you use the pixel perfect unity package ?

Yesterday i'm looking for an alternative because this res is a bit wide.
I think that maybe 405*540 could be good (not tested yet).
why ? Because it's a ratio of 3:4 and it should be displayed correctly on hd screens.
Correctly because on :
yoko hd -> only black blocks on the right and left sides, full height used. (x810,y1080)
tate hd -> only black blocks on up and bottom, full width used. (x1080,y1440)

and with a 3:4 ratio, it should be also good on older screens... ?
(ps : i'm not interrested on smartphone res)


Top
 Offline Profile  
 
 Post subject: Re: WIP SHMUP : Learn basics
PostPosted: Thu Mar 05, 2020 10:02 am 


User avatar

Joined: 13 Jan 2020
Posts: 16
I'm looking with existing (big INDIE) games to find good looking resolutions.

In Super Hydorah and Celeste, the resolution must be 320*180 because on the picture below (1920*1080) each pixel is stretched to a 6*6 square.
Super Hydorah :
https://game-guide.fr/wp-content/upload ... .44.13.png
Celeste :
https://cdn03.nintendo-europe.com/media ... ste_01.jpg

In Axiom Verge, the resolution must be 480*270 because on the picture below (1920*1080) each pixel is stretched to a 4*4 square.
https://gocdkeys.com/images/captures/ax ... -key-4.jpg

Maybe is more safe for a first dev to choose the smallest res 320*180.
IMO, with this res, pixel art is either shitty either good.


Top
 Offline Profile  
 
 Post subject: Re: WIP SHMUP : Learn basics
PostPosted: Sun Mar 22, 2020 3:54 pm 


User avatar

Joined: 13 Jan 2020
Posts: 16
Hi! New update.
I worked on enemy fire. This should cover a wide range of situations.
I did take a lot of time but if i make a shmup with shitty shoots, well ... it will be a shitty shmup ... :)

Enjoy !
Do not pay attention to the calculation of the fps at the top left corner, it messes when I capture the video from unity.
https://youtu.be/3MEfBRKQT14

Thank you for giving me your opinions as usual! :)


Top
 Offline Profile  
 
 Post subject: Re: WIP SHMUP : Learn basics
PostPosted: Sun Mar 29, 2020 2:45 pm 


User avatar

Joined: 13 Sep 2019
Posts: 135
1 : You need a menu
2 : Game over
3 : Score

Once you have this framework, things will be simple.
Most important.

Learn C++, unity sucks with C# only.
For SHMUPs unity no good, you need something simpler that runs better.
Just tell me 1 good SHMUP thats made with unity ?


Top
 Offline Profile  
 
 Post subject: Re: WIP SHMUP : Learn basics
PostPosted: Tue Mar 31, 2020 3:37 pm 


User avatar

Joined: 13 Jan 2020
Posts: 16
Yes, you're right !
A menu, a gameover screen (so i need also a game ? :) ) and a score/highscore.
I think i need a pause and exit menu.


heli wrote:
Just tell me 1 good SHMUP thats made with unity ?

I don't know but i learn unity with YT tutorials at first.


Top
 Offline Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 24 posts ] 

All times are UTC


Who is online

Users browsing this forum: No registered users and 2 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
Jump to:  
Space Pilot 3K template by Jakob Persson
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group