Jump to content
IGNORED

Panzer Strike


Vorticon

Recommended Posts

So as I was waiting in the hospital lobby area for 5 hours for my wife's surgery to be completed (she did fine thankfully), I decided out of the blue to design an XB wargame, something I could (maybe) have ready by Faire time in November. Besides, what else was there to do anyway???


Out came the notepad, and 10 pages of furious scribbling later, I had a detailed outline for a tank battle simulation game, including an AI.


It will pit 5 tanks on each side, each of which will have characteristics such as fire power, side-dependent armor plating, and range. Damage will vary depending on the facing tank side (front is strongest, back is weakest, and sides are mid-range). Full line of sight and fog of war is implemented, along with the ability to send out reconnaissance aircraft. The battlefield will consist of plains, hills, forests and rivers, and will be fully editable.


There will be a scenario editor where one will be able to create a battle map and set the tank characteristics then package it as a complete scenario.


The objective of the player will be to occupy and hold a target square within the enemy (computer AI) area and hold it for 3 turns. The AI on the other hand will of course sweat silicon trying to stop you.


I believe I have most of the salient details worked out on paper, and I'll start the actual coding this week.


This game will be in the same spirit as Clear For Action. Whether I will also need to chain multiple code segments together remains to be seen.


More to come.



UPDATE:


Attached is the completed program package including the .dsk file, source and manual. This latest version as of October 2015 fixes an important bug in the rotation of the player tanks where it was possible to rotate to the right in excess of the allotted movement points.


Panzer Strike.zip

  • Like 11
Link to comment
Share on other sites

Best to you and the wife from here as well.

 

I also like the game concept--the AI trying to retake that square will not only sweat bullets to get it back, it'll lob a huge amount of iron into that space in a concerted attempt to vaporize anything that is foolish enough to actually be there. It sohould make for some interesting defensive/armor use strategies for the player trying to hold that space against a full-blown assault.

Link to comment
Share on other sites

Best to you and the wife from here as well.

 

I also like the game concept--the AI trying to retake that square will not only sweat bullets to get it back, it'll lob a huge amount of iron into that space in a concerted attempt to vaporize anything that is foolish enough to actually be there. It sohould make for some interesting defensive/armor use strategies for the player trying to hold that space against a full-blown assault.

 

Thanks :)

You have definitely outlined here the main AI response when the target square has been occupied: throw everything at the occupying tank! Obviously, if the player makes an early bee line for that square, he will have to face the full intact brunt of the enemy force, likely with deadly effects. A better strategy is to try to ambush and pick off the enemy tanks one at a time, utilizing terrain features whenever possible. For example, a tank tucked away in a forest will be completely undetectable, even from the air. However, that tank will also be blind unless it is right on the edge of the forest. There is also a very large movement cost for entering and moving into forests for tanks. Of course, the AI will not be sitting idle and will have a few effective tactics up its sleeve.

Link to comment
Share on other sites

Sounds good, sounds very good!

 

Tanks-now your talking my language, are you going to give it a historical element?, a WW2 setting would help to define the response of each side if the turns were linked to the years passing.

 

eg-Germans advance into USSR and get shocked by T34's, Germans respond with up-gunned Panzer IV's, Tigers and Panthers, Russians ht back with KV's, T34-85's and IS II's etc etc.

 

How big an element would air power take in the game?-after all, if you gain air superiority, all tanks will in effect become useless.

Link to comment
Share on other sites

Sounds good, sounds very good!

 

Tanks-now your talking my language, are you going to give it a historical element?, a WW2 setting would help to define the response of each side if the turns were linked to the years passing.

 

eg-Germans advance into USSR and get shocked by T34's, Germans respond with up-gunned Panzer IV's, Tigers and Panthers, Russians ht back with KV's, T34-85's and IS II's etc etc.

 

How big an element would air power take in the game?-after all, if you gain air superiority, all tanks will in effect become useless.

 

Well, the historical element could potentially be somewhat recreated using the scenario builder where custom battle maps could be design based on historical ones. The tank characteristics do not go down to the level of specific gun elements, weights etc..., but rather use general attributes to try to emulate them at a high level. For example, the attack potential of a tank goes from 1-3, and can be used to represent a superior or inferior main gun power. You can assign different armor strength (0-4) for the front, sides and back of a tank, again trying to emulate the the same level of protection that a historical tank had. Movement potential varies from 2-8, however this one is automatically calculated based on the attack potential and the total armor value, because a bigger gun and heavier armor mean more weight and thus generally less mobility. As you probably well know, tank design has always been about finding the right balance between fire power, armor, and mobility.

As for the air element, it is only restricted to a single reconnaissance sortie per game per side. The effect of a sortie is to uncover all of the opposing tank positions for one turn, except the ones hidden in forests. But there is a catch. There is always a chance that the plane will be shutdown before its mission is complete, more so if the side ordering the sortie is losing and less so if he is winning, thus trying to represent a certain level of disorganization or morale boost of the affected side.

So all in all, one should be able to create a descent historical recreation of a WWII tank battle, and I will try to include at least a couple of those with the game as a start. Maybe I'll have Rommel and Monty battle it out :)

  • Like 2
Link to comment
Share on other sites

Just remember that this is a platoon based simulation, so it will be kind of hard to recreate large battles.

What I have decided to do though is include a number of preset WWII tanks in the scenario builder whose characteristics will try to be as close as possible to the real thing from a firepower and armor perspective. This will help increase the accuracy of the simulation when setting up historical scenarios and reduce guesswork.

Furthermore, I have replaced the fixed gun range with a variable one which will depend on the main gun characteristics of the tank being emulated, thus adding a little more realism.

  • Like 2
Link to comment
Share on other sites

Ambitious! I like it. :)

Removing my earlier comments... I see that you are familiar with chaining XB programs and the difficulties of variable passing already. :)

 

Some other thoughts... having a fog of war is going to be very slow processing. By the description you wrote it sounds like each tile has the following properties:

 

  • Terrain Type (Forest, hill, plain, road, river, etc.) Can be stored as an ASCII display character for speed
  • Covered/uncovered in FoW (boolean)
  • Is owned by Enemy (boolean)

Ownership is only checked for victory conditions, so that should be easy to store in a numeric array. Although that's a HUGE waste of memory... Come to think of it, wouldn't it be better to have a "point" of control, like a city or fortification that your tank has to "occupy"? That would be far cheaper and easier to track... and you could set up scenarios with 1-5 points of control, meaning if you lose too many tanks you can't achieve victory.

 

The fog of war could be painful, though. I assume tanks "uncover" area as they move, or aircraft do around enemy tanks? One good way to do a fog of war that way is to just store "blank" characters next to your actual ones. If you cut your set size in half (4 instead of 8 ) then you can just initialize your map screen all in blanks. As a tank moves around, you use GCHAR to get the characters around it, add/subtract one, and VCHAR it back to expose the tile.

Edited by adamantyr
Link to comment
Share on other sites

Yes, I am very familiar with program chaining from my earlier work with Clear For Action. All it really involved was storing the relevant variables on a temp disk file and having the chained program retrieve them. Since the screen is preserved during chaining, the process is transparent to the user.

The way I am implementing fog of war is 2 fold: each own tank is checked against every enemy tank that is alive for distance (d=SQR ((x1-x2)^2+(y1-y2)^2), and if it exceeds 10 then the enemy tank is invisible for that particular unit. Otherwise, a virtual Bresenham line is drawn from the enemy tank to the originating tank, checking along the way for any obstruction. If none is found, then a check is made for facing because a tank can only detect objects within 45 degrees from the centerline. Only then if all the conditions are met that a tank is made visible and it's position is broadcast to all friendly tanks.

This process will be repeated for the computer side as well.

All this is done prior to the movement phase. When it's the computer's turn to move, it's tanks are temporarily hidden until movement is complete, then another round of visibility checks will be made for each side since movement will very likely change the visibility of some tanks.

I know all this sounds complicated, but it will be iterative and I will try to make it as efficient as possible.

As for square ownership, I only need to track the target square, and that is easy to do. All other squares are irrelevant.

Link to comment
Share on other sites

panzer_general2_screenshot1.jpg

Whilst we are all in a wargame mood-just a little indulgence on my part, Panzer General II-possibly the best strategy game ever.

 

683539515.jpg

 

And now-Panzer General III, probably the worst sequel ever to a perfect game engine.(oh how my heart sank as I played this for the first time) :_(

 

 

Sorry for the partial thread hi-jack.

  • Like 2
Link to comment
Share on other sites

I delved into Clear For Action last night. It's a very impressive game! I feel like it would take me weeks to get the hang of all the variables and figure out how not to get my butt kicked. I'm not well versed in the war games and Avalon Hill titles that inspired it, though, so I'm coming at it as a real noob. It's a very intriguing game, though, and the level of complexity you managed to work into it is pretty impressive.

 

This is the sort of project that makes me feel bad that more people aren't playing the games that get created (as was being discussed in that other thread). If nothing else, you also inspired me to get off my butt and work on the AI for my (much simpler) game I posted about a few weeks ago. Got some more hotel downtime this weekend and I'm looking forward to coding, and to playing Clear For Action some more.

Link to comment
Share on other sites

I delved into Clear For Action last night. It's a very impressive game! I feel like it would take me weeks to get the hang of all the variables and figure out how not to get my butt kicked. I'm not well versed in the war games and Avalon Hill titles that inspired it, though, so I'm coming at it as a real noob. It's a very intriguing game, though, and the level of complexity you managed to work into it is pretty impressive.

 

This is the sort of project that makes me feel bad that more people aren't playing the games that get created (as was being discussed in that other thread). If nothing else, you also inspired me to get off my butt and work on the AI for my (much simpler) game I posted about a fIew weeks ago. Got some more hotel downtime this weekend and I'm looking forward to coding, and to playing Clear For Action some more.

 

Thanks :) It's certainly not everyone's cup of tea, but like most programmers here I tend to write the programs I want to play.

I hope you can get your AI algorithm up and running. At first building an AI can seem like a daunting task, but the key here is to break it down to very simple principles and you'd be surprised how much apparent complexity can arise from just a handful of axioms.

Link to comment
Share on other sites

I feel like I approached it the right way this time, at least, in that I built the main game loop with no bells and whistles, in two-player mode, then just played it a bunch myself. That approach showed me a few different strategies an AI could take, and also made me redesign a few elements of the game to remove some easy 'cheats' to winning. The game itself will be more compelling, and the AI will be 'smarter' and possibly have a few distinct options that the human player can choose from.

Link to comment
Share on other sites

The scenario builder is half way done, with the map building section completed. Next is the tank designer. You will have the ability to pick a ready to go tank design from a list of the 10 top WWII tanks (according to this site http://armedforcesmuseum.com/top-ten-tanks-of-wwii/) or you could create your own custom characteristics.

The scenario builder is a standalone program separate from the main game, and I should have it completed within the next few days.

  • Like 2
Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...