Announcement

Collapse
No announcement yet.

Announcing Section #4 for Survival Game - Setting up the survival game-loop

Collapse
X
  • Filter
  • Time
  • Show
Clear All
new posts

    Announcing Section #4 for Survival Game - Setting up the survival game-loop

    We're announcing the fourth section of the survival sample game today! The documentation will be up by the end of next week, in the meanwhile you can grab the latest source at GitHub (https://github.com/tomlooman/EpicSurvivalGameSeries). Which will continuously be worked on for the 12 week period! Use the tagged release for stable builds each section, once available.

    UPDATE: Wiki Docs are now available for this section!

    LINK TO MAIN THREAD

    In this section we will setup the game loop with scoring, failure state and a day night cycle that will affect the spawning of enemies and items.

    Some of the concepts that will be covered include:
    • Controlling a dynamic time of day through the gamemode.
    • Spawning enemy AI and items (food, weapons) during gameplay.
    • Showing (replicated) game information through the HUD (time of day, score, kills etc.)
    • Replicating score and the gamestate on clients (kills, time of day etc.)


    Every two weeks a new section will be announced with a new thread alongside it! Please use this thread for questions and feedback you might have on the section!

    UPDATE: Wiki Docs are now available for this section!

    Screenshots:

    Click image for larger version

Name:	survival_section4_banner01.jpg
Views:	3
Size:	117.0 KB
ID:	1150092

    Click image for larger version

Name:	section2_overview02.jpg
Views:	2
Size:	170.2 KB
ID:	1149515
    Attached Files
    Last edited by Tom Looman; 05-18-2015, 10:46 AM.
    Game Developer @ LODZERO - My Twitter | tomlooman.com UE4 samples & tutorials | C++ Survival Game (Open-source template)

    #2
    Still have to explore Section 3

    I'm really interested about game-loop and how to manage it with UE4, cool section Tom, thank!
    Join the Unreal Engine community on Reddit! | Twitter: @ZioYuri78

    Comment


      #3
      A quick update on what I'm working on right now:

      Smooth networked time of day. The day/night cycle will influence scoring and enemy (maybe even behavior of those enemies)

      Click image for larger version

Name:	section4_timeofday01.jpg
Views:	1
Size:	96.1 KB
ID:	1076074

      (Should really be viewed in motion, video coming soon!
      Game Developer @ LODZERO - My Twitter | tomlooman.com UE4 samples & tutorials | C++ Survival Game (Open-source template)

      Comment


        #4
        Hey Tom,

        Ty so much for these awesome tutorials. I been stuck on replicating character rotation when using SetActorRotation, It rotates fine on the server side, but the client side doesnt always change the rotation.

        EDIT: I had to go back and relook at your gits, videos,etc. I just had to Replicate the spellbar with CondOwneronly.

        Ty again!
        Last edited by Venros; 05-15-2015, 03:44 PM.

        Comment


          #5
          Hey Tom,

          Great Idea doing such a widespread comprehensive tutorial series for this, given that OpenWorld was just promoted at GDC

          Btw. porting to 4.8 shouldn't induce too much trouble, mostly some changes to the override specifier and some undeclared identifiers from what i've been seeing in the log when trying to convert.

          I guess you are waiting for a stable release though?

          Im basicly just saying thanks and keep up the good work!

          Greetings


          Chris

          Comment


            #6
            Originally posted by HostileEnvironment View Post
            Hey Tom,

            Great Idea doing such a widespread comprehensive tutorial series for this, given that OpenWorld was just promoted at GDC

            Btw. porting to 4.8 shouldn't induce too much trouble, mostly some changes to the override specifier and some undeclared identifiers from what i've been seeing in the log when trying to convert.

            I guess you are waiting for a stable release though?

            Im basicly just saying thanks and keep up the good work!

            Greetings


            Chris
            Hi! Thanks! Yeah definitely waiting for 4.8 stable, there are some blocking bugs in the preview that will break multiplayer. The project will be 4.8 compatible for sure though.

            Cheers

            - Tom
            Game Developer @ LODZERO - My Twitter | tomlooman.com UE4 samples & tutorials | C++ Survival Game (Open-source template)

            Comment


              #7
              Originally posted by Tom Looman View Post
              [*]Replicating score and the gamestate on clients (kills, time of day etc.)
              May I ask will you consider having player vs player kills / deaths counted as well as kills on AI?

              Comment


                #8
                Originally posted by CyberDev View Post
                May I ask will you consider having player vs player kills / deaths counted as well as kills on AI?
                That wouldn't be too difficult to implement. For the current gamemode however it's 2 player coop vs. environment/AI. I think since a lot of people would like to use this "template" for open world purposes instead I will consider setting up and splitting up some code to make all that easier (eg. moving all closed area coop into a separate gamemode class, so it can be left out while maintaining the base framework for gamerules with open worlds etc. All that is TBD though, there is still two sections to go which I'll plan out soon.
                Game Developer @ LODZERO - My Twitter | tomlooman.com UE4 samples & tutorials | C++ Survival Game (Open-source template)

                Comment


                  #9
                  Originally posted by Venros View Post
                  Hey Tom,

                  Ty so much for these awesome tutorials. I been stuck on replicating character rotation when using SetActorRotation, It rotates fine on the server side, but the client side doesnt always change the rotation.

                  EDIT: I had to go back and relook at your gits, videos,etc. I just had to Replicate the spellbar with CondOwneronly.

                  Ty again!
                  Oh haha great that you found an answer. I was typing one out the other day, but didn't get to finish it

                  A snippet from that anwser that is still of use even though you solved your initial problem:

                  "...You probably even want to look into (Actor)Components instead of using Actor for your spells, and attach the spells as components to your character. ActorComponents are more efficient and generally clearer who owns it (and it won't exist as an object in your world anymore, which is a bit unneccessary) But that is up to you.

                  Docs on Component Replication: https://docs.unrealengine.com/latest...nts/index.html

                  At that time you'd also want to replicate the spellbar, using a condition COND_OwnerOnly (look at the commented code of GetLifetimeReplicatedProps in SCharacter.cpp for an example) since only the server and owning player care about this array..."


                  I skipped the rest of the answer since you resolved it already

                  Cheers,

                  Tom
                  Game Developer @ LODZERO - My Twitter | tomlooman.com UE4 samples & tutorials | C++ Survival Game (Open-source template)

                  Comment


                    #10
                    The docs for Section 4 are almost done! I've been adding some improvements to the code to simplify and cleanup some of the examples before releasing the docs.

                    Click image for larger version

Name:	survival_section4_banner01.jpg
Views:	3
Size:	117.0 KB
ID:	1076565
                    Game Developer @ LODZERO - My Twitter | tomlooman.com UE4 samples & tutorials | C++ Survival Game (Open-source template)

                    Comment


                      #11
                      UPDATE: Wiki Docs are now available for this section!
                      Game Developer @ LODZERO - My Twitter | tomlooman.com UE4 samples & tutorials | C++ Survival Game (Open-source template)

                      Comment


                        #12
                        Thank you Tom, shared on Reddit as usual.
                        Join the Unreal Engine community on Reddit! | Twitter: @ZioYuri78

                        Comment


                          #13
                          That doors in that side remember me something mmm, no idea what... xD
                          Nice work Tom, but for that type of example/game will be nice a bigger map with respawn of the items or something ?
                          Hevedy - Instance Tools: https://hevedy.itch.io/hevedyinstances
                          Hevedy - Image Tools: https://hevedy.itch.io/imagetools

                          Comment


                            #14
                            Thanks Tom for this tutorial series.

                            One question, I've noticed some calculation for the day/ nightcycle are done in the gamestate class...could/ should I do this calculations inside the TimeOfDayManager or another Actor class if our game is singleplayer only? From what I've read GameState is only useful for multiplayer.

                            Comment


                              #15
                              Hi Tom, I took the right to update myself the Main documentation page on the wiki to add section 4 with useful links.

                              I hope its okay for you!

                              Cheers!
                              [Gamedev programmer at Darewise (Paris) - We are hiring]
                              UE4 Git LFS 2.x Source Control Plugin 2.12-beta for UE4.22 - (v1 integrated by default in Beta status since UE4.7)
                              UE4 Plastic SCM Source Control Plugin (1.4.5 for UE4.22)

                              Comment

                              Working...
                              X