Announcement

Collapse
No announcement yet.

Tower Defense Starter Kit

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

    I used this project to create a scenario myself, but the tower of scenario can't be created in the BP_GridGenerator you gave me. What options have I set less?

    Comment


      Originally posted by jonnyjiang View Post
      I used this project to create a scenario myself, but the tower of scenario can't be created in the BP_GridGenerator you gave me. What options have I set less?
      Hi, I've uploaded a tutorial for setting up new Towers using the toolkit:


      You should be able to get your towers working by following those steps. If you do run into issues, just let me know.
      Unreal Possibilities
      Tower Defense Starter Kit | Line of Sight Visualization | Circular Ring Material Tutorial

      Comment


        @Stormrage256

        Hello sorry for my bad english.
        Can you tell me how to fix these mistakes ?

        https://imgur.com/FWHu8Oa

        Comment


          Originally posted by polkovnika View Post
          @Stormrage256

          Hello sorry for my bad english.
          Can you tell me how to fix these mistakes ?

          https://imgur.com/FWHu8Oa
          Alright, so what's happening is that the AI units are not able to access their spline paths and hence unable to run their movement logic. May I know whether you're using the nav mesh pathing or the custom spline path option for AI movement?
          Unreal Possibilities
          Tower Defense Starter Kit | Line of Sight Visualization | Circular Ring Material Tutorial

          Comment


            No problem with UE4 version 4.22.
            But using UE4 4.23 shows these errors.
            This happens on one of the cards included in the package.

            Comment


              Originally posted by polkovnika View Post
              No problem with UE4 version 4.22.
              But using UE4 4.23 shows these errors.
              This happens on one of the cards included in the package.
              I have not tested it in v4.23 since it's still in the preview version. But thanks for letting me know beforehand. I'll see if I can reproduce the issue at my end. Also by cards, could you be more specific which asset you're referring to?
              Unreal Possibilities
              Tower Defense Starter Kit | Line of Sight Visualization | Circular Ring Material Tutorial

              Comment


                Hi polkovnika , I was able to reproduce the issue in v4.23 preview 7. It's caused by the spline components being set to null for some reason.

                I'm not sure if its an engine bug, but what seems to be happening in 4.23 is that every time the spline construction script runs in the editor, it keeps retaining references to the components created in the past as you can see below:

                Click image for larger version  Name:	referror.jpg Views:	1 Size:	532.0 KB ID:	1657105

                The print strings within the green border are how it's supposed to be. Three spline components: the middle one created by the user and parallel splines on each side generated automatically through the script. However, in v4.23, you can see 'TRASH' references (within the red border) to additional spline components and more keep getting added every time you compile.

                You can fix this by adding the following node at the beginning of BP_SpawnPoint_SplinePathing's construction script:

                Click image for larger version  Name:	bugfix.jpg Views:	1 Size:	331.3 KB ID:	1657106

                I believe that should take care of the issue. Let me know if it works out.
                Unreal Possibilities
                Tower Defense Starter Kit | Line of Sight Visualization | Circular Ring Material Tutorial

                Comment


                  The v2.9 update has been submitted to the Marketplace.

                  New Features:
                  • Added support for branching tower upgrade paths: Now you can have tower upgrades branch out along specialized paths in just a single step. Simply add new tower models to the UpgradesTo: array for your tower in the DT_TowerData data table and you should be good to go. [Note: Tower Models required to have entries in the data table.]

                    Click image for larger version  Name:	upgradesto.jpg Views:	1 Size:	423.8 KB ID:	1666946

                    The Tower Interaction UI systems will automatically calculate positions for upgrade buttons using the data table information. No script changes required for displaying multiple upgrade options.

                  Other Changes:
                  • Tower Upgrades now destroy & spawn new towers instead of modifying the attributes of base towers. Tower XP still carries over to the upgraded towers.
                  • Unique hardcoded UI Stats for Mining Tower removed. All towers now directly use the stats specified in the data table.
                  • Toolkit updated to Unreal Engine v4.23.
                  Bug Fixes:
                  Additional Notes:
                  • Search for Version2_9 in the blueprint editor to identify all the major changes in this update.
                  Last edited by Stormrage256; 09-20-2019, 08:04 AM.
                  Unreal Possibilities
                  Tower Defense Starter Kit | Line of Sight Visualization | Circular Ring Material Tutorial

                  Comment


                    The v2.10 update has been submitted to the Marketplace.

                    New Features:
                    • Added a new Data Table driven workflow for defining waves when using the Batched Wave Spawning System. Compared to the previous struct array setup, data tables offer far greater ease of use when it comes to defining waves, especially when dealing with large hordes comprising multiple clusters of enemies within each wave.

                      Click image for larger version

Name:	dt.jpg
Views:	144
Size:	194.5 KB
ID:	1673004

                      [Note: Tutorials on how to use the new system will be posted on Youtube once v2.10 hits the Marketplace. You can find them in the Tower Defense Starter Kit playlist: https://www.youtube.com/playlist?lis...Ky4HRAkYVzIuPg]
                    • Added support for spawning Boss enemies at the end of waves. Simply select the data table entry for the wave, set the SpawnBossAtEnd? variable to True, & define the BossSpawnData (similar to normal enemy spawn data) parameters.

                      Click image for larger version

Name:	boss1.jpg
Views:	118
Size:	178.0 KB
ID:	1673005

                    Other Changes:
                    • Revamped the BP_WaveSpawnController workflow to incorporate the new features as well as to make it easier to understand. The visual setup now displays every step of the wave spawning system in a neatly arranged manner so as to enable identifying all working parts of the system in a single glance as soon as you open the blueprint.

                      [Note: If you need the old setup for reference, it's still available when you download the v4.22 edition as no changes have been made to this blueprint while making the transition to Unreal Engine v4.23.]

                      Click image for larger version

Name:	wsc.jpg
Views:	109
Size:	454.8 KB
ID:	1673006
                    Additional Notes:
                    • Search for Version2_10 in the blueprint editor to identify all the major changes in this update.
                    Unreal Possibilities
                    Tower Defense Starter Kit | Line of Sight Visualization | Circular Ring Material Tutorial

                    Comment


                      Hi, I've uploaded a new tutorial for setting up waves using the Batched Wave Spawn (spawning AI units in batches) Controller, taking into account the changes that were introduced in the latest v2.10 update.

                      [Note: If you're using the Weighted Wave Spawning system, the old workflow still applies since the waves are not explicitly defined through data tables in that scenario.


                      It's a simple 3-minute tutorial. So you should be able to create your own customized waves and have them up & running in just a matter of minutes. Have fun!
                      Last edited by Stormrage256; 10-16-2019, 05:15 AM.
                      Unreal Possibilities
                      Tower Defense Starter Kit | Line of Sight Visualization | Circular Ring Material Tutorial

                      Comment


                        Hi Stormrage,

                        First, I wanted to say great job on this project. It's got a ton of features, and I really love how modular this has gotten over its lifetime. Very nice, props!

                        I have a few suggestions that I think would be nice in this project. I'm in the process of implementing these features in my project, and thought they may be of use to others.
                        • Muzzle flash emitters upon firing. Minor, easy to do, but I ended up throwing the logic in the base class (which means I can't update super easily in the future) so all turrets had it if needed.
                        • Damage types and armor types. Bolding this one because it's kind of a staple in TDs.
                          • It'd be awesome to have a table with each armor type and the multipliers for damage types. A tank's armor, for example, could reduce all damage other than piercing. An entry in the table of "default" could make all unspecified damage types use that multiplier.
                          • Projectile collision sounds would be pretty easy with this in place as well. Ricochets and metal "tink" sounds for metal armor. Fleshy sounds for unarmored units. Etc.
                        • Ammo pool with recharge time upon depletion. Example, a rocket turret with 8 rockets. It can fire all 8 and the fire rate can account for the delay between them. However, once those 8 rockets are depleted, a recharge time which is totally independent of the fire rate is incurred before the next pool of 8 can be cycled through.
                        • Turret thumbnails. It would be nice if I could just throw a thumbnail into the TowerData table, and if it exists, show it instead of the abbreviation. Only fall back to abbreviations when a texture isn't provided for a thumbnail.
                        • SpawnPointIndex value of -1 to randomize the spawn point in the Batched Wave Spawn system. Example, I know I want 10 of unit A and 10 of unit B. I don't want it to be perfectly distributed to exactly the same point each time. The value of -1 would just pick a random spawn point for all 10 of unit A and B.
                        They're mostly minor, but I'd really love to see damage types and armor types. If it actually uses physical materials, great, but totally not necessary imo.

                        Admittedly I haven't even tried the latest version on 4.24, but looking forward to seeing the update for 4.24 as well.

                        Thanks, and again great work!

                        Comment


                          Hi One Mode Only , thanks a lot for all your feedback and suggestions. I took some time to think about them and here are the current plans regarding each of the suggestions:
                          • Muzzle Flash Emitters can definitely be added. From a blueprint implementation standpoint, it's quite easy. However, creating emitters might take more time. In any case, I'll try to include it in the v4.24 lifecycle, but since the plans for next couple of updates are already mapped out, it would be available only after them.
                            As you've already done, adding the logic in parent class would be a good way to handle it, since the Boost Tower is the only default tower that wouldn't use it.
                            As an alternative, a component driven approach can also be used to specifically handle weapon FX like muzzle flashes, bullet trails, fire sounds, etc.
                          • Damage/Armor types, I imagine would require the most work among all of the suggested features. And it would actually be an awesome feature to have, but I will have to do more research on different types of implementations before I can confirm when it can be made available.
                          • So something that fires a volley of rockets one after the other & then waits for a duration before firing the next volley?
                          • Turret thumbnails are already on the way. If all goes as planned, it will be focus of the the first update after the upcoming 4.24 compatibility update.
                            And it will, of course be customizable through the Tower Data table. There won't be any need to make changes to the HUD elements.
                          • I like the spawn point randomization idea. It will also be added alongside the Turret thumbnails.
                          The first 4.24 update has already been submitted. It's more of a compatibility update. The only major change is the removal of Projectile Spawn Controller which had a role earlier during the toolkit life cycle, but has since been an unnecessary complexity. The more interesting updates will be on the way soon after that.
                          Last edited by Stormrage256; 12-21-2019, 05:06 AM.
                          Unreal Possibilities
                          Tower Defense Starter Kit | Line of Sight Visualization | Circular Ring Material Tutorial

                          Comment


                            Hi Stormrage256, thanks for the well thought responses.

                            I agree, I think damage and armor types would be the bulk of the work. I can send over what I come up with if it's of any use. I'm sure I'd do things a little differently than you, but my current goal is to create two components. One for armor, one for damage. Then in the damage calculation, drop in one more function that just checks the table for a multiplier right at the end of the calculation (after crit).

                            As for the volley of rockets, that's exactly the idea. That'd unlock a vast array of possibilities, for example a turret that was fairly overpowered stat-wise (extremely rapid fire rate, high damage) but was limited by n (ammo pool for rocket turret, overheating for a machine gun, recharge for a laser, etc). That said, multiple variations would be super cool too. The rocket turret might always fire 8 and then require a reload period. However, maybe the machine gun would overheat if it fired for 2.5 seconds consistently. In all cases, the end of the round would reset these counters. Food for thought, I know this is added complexity which may not have huge gains.

                            As for the muzzle flashes, I just changed the way I was doing it. I've got a looping muzzle flash particle on the tower BP which is hidden by default. It's shown when we're told to fire, and hidden when the target is lost. Seems to work perfectly. I overcomplicated it at first, but this seems to do exactly what I'm looking for. The only exception is that my higher tier MG towers add barrels. MGI has one barrel, MGII has two, and MGIII has three. The fire rate stays the same, and the additional barrels fire (rechargeTime * 0.25) seconds later in the sequence. So, a looping muzzle flash does not do me a tremendous amount of good in this niche scenario. I'll likely keep it how it is, and just set a timer to hide the muzzle flash in these cases. It's already fairly custom, since the projectiles fire from each barrel and that required changing the spawning of the projectile a bit so it aimed on the target properly.

                            Anyway, I'm really looking forward to the coming updates. This project is very well done, and I appreciate all the hard work you've put into it.

                            Happy holidays, hope all is well!
                            Last edited by One Mode Only; 12-24-2019, 02:26 PM.

                            Comment


                              Originally posted by One Mode Only View Post
                              Hi Stormrage256, thanks for the well thought responses.

                              I agree, I think damage and armor types would be the bulk of the work. I can send over what I come up with if it's of any use. I'm sure I'd do things a little differently than you, but my current goal is to create two components. One for armor, one for damage. Then in the damage calculation, drop in one more function that just checks the table for a multiplier right at the end of the calculation (after crit).

                              As for the volley of rockets, that's exactly the idea. That'd unlock a vast array of possibilities, for example a turret that was fairly overpowered stat-wise (extremely rapid fire rate, high damage) but was limited by n (ammo pool for rocket turret, overheating for a machine gun, recharge for a laser, etc). That said, multiple variations would be super cool too. The rocket turret might always fire 8 and then require a reload period. However, maybe the machine gun would overheat if it fired for 2.5 seconds consistently. In all cases, the end of the round would reset these counters. Food for thought, I know this is added complexity which may not have huge gains.

                              As for the muzzle flashes, I just changed the way I was doing it. I've got a looping muzzle flash particle on the tower BP which is hidden by default. It's shown when we're told to fire, and hidden when the target is lost. Seems to work perfectly. I overcomplicated it at first, but this seems to do exactly what I'm looking for. The only exception is that my higher tier MG towers add barrels. MGI has one barrel, MGII has two, and MGIII has three. The fire rate stays the same, and the additional barrels fire (rechargeTime * 0.25) seconds later in the sequence. So, a looping muzzle flash does not do me a tremendous amount of good in this niche scenario. I'll likely keep it how it is, and just set a timer to hide the muzzle flash in these cases. It's already fairly custom, since the projectiles fire from each barrel and that required changing the spawning of the projectile a bit so it aimed on the target properly.

                              Anyway, I'm really looking forward to the coming updates. This project is very well done, and I appreciate all the hard work you've put into it.

                              Happy holidays, hope all is well!
                              Hey, I've been mostly away from work during the holidays. So didn't get a chance to go through the solution in detail. Anyways, back to work now & I've submitted a new update to the Marketplace & it will add support for Spawn Point Randomization. I went ahead with your idea of assigning an "index of -1" as the cue for randomizing spawn points for an AI batch. So now you can have a mix of both fixed & randomized spawn point systems across different batches of AI units. You can find more info about it in the change log which will be posted once the update goes live.

                              The next update will focus on the Turret Thumbnails, and the rocket volley after that. As for the damage/armor types, I'll have to first figure out how to go about with the implementation. I'll hit you up before starting work on it.
                              Unreal Possibilities
                              Tower Defense Starter Kit | Line of Sight Visualization | Circular Ring Material Tutorial

                              Comment


                                The v2.12 update has gone live on the Marketplace.

                                New Features:
                                • Added support for Spawn Point Randomization in Batched Wave Spawn System. Previously the feature was available only when using the Weighted Wave Spawn System, but can now also be used in the former scenario by setting the Spawn Point Index of an AI Batch to '-1'.

                                  Click image for larger version

Name:	spiran.jpg
Views:	47
Size:	164.9 KB
ID:	1705852
                                  By setting the index to -1 (as opposed to the index of a particular spawn point), individual units within the specified AI Batch will be spawned at random spawn points.

                                Other Changes:
                                • Optimizations to the AI Visual Perception logic through the use of Math Expressions for linear/angular range checks.

                                  Click image for larger version

Name:	mathexpopt.jpg
Views:	26
Size:	393.9 KB
ID:	1705853

                                Additional Notes:
                                • Search for Version2_12 in the blueprint editor to identify all the major changes in this update.
                                Unreal Possibilities
                                Tower Defense Starter Kit | Line of Sight Visualization | Circular Ring Material Tutorial

                                Comment

                                Working...
                                X