Duke4.net Forums: Scorpion Tank (unused first brown tank for Atomic Edition) - Duke4.net Forums

Jump to content

Hide message Show message
Welcome to the Duke4.net Forums!

Register an account now to get access to all board features. After you've registered and logged in, you'll be able to create topics, post replies, send and receive private messages, disable the viewing of ads and more!

Page 1 of 1
  • You cannot start a new topic
  • You cannot reply to this topic

Scorpion Tank (unused first brown tank for Atomic Edition)  "Minors problems"

User is offline   Firefly_Trooper 

  • 12

#1

Hello everyone!

Thanks to the fan community, I was able to save the first Brown Pig Tank from the Atomic Edition. However, I have two small unresolved issues.

1. The sound "ROAM" when it moves, does not work at all.
2. He never attacks the player automatically.

I remember that this code is not of myself but found here: http://www.nitro404....d=scorpion_tank

Here is the code:

define SCORPIONTANK 7170

define SCORPIONTANKSTRENGTH 1000 // More than twice as strong

// NEW Scorpion Tank

action ASCORPIONTANKSPIN 0 1 7 1 4
action ASCORPIONTANKSHOOTING 7 2 7 1 15
action ASCORPIONTANKWAIT 0 1 7 1 1
action ASCORPIONTANKDESTRUCT 0 1 7 1 1
action ASCORPIONTANKDEAD 0 1 7 1 1

move SCORPIONTANKFORWARD 260  // More than twice as fast
move SCORPIONTANKSTOP

state tank_explode
 debris SCRAP3 10
 debris SCRAP1 7
 debris SCRAP4 8
 debris SCRAP2 9
 debris SCRAP5 8
 guts JIBS6 8
ends

state shoot_rpg 
sound TANK_ROCKET // a blank sound slot
shoot RPG
ends

state drop_rpg
ifrnd 64 spawn RPGAMMO
ends

useractor enemy SCORPIONTANK SCORPIONTANKSTRENGTH fall
ifpdistl 1024 { ifp palive { palfrom 63 63 addphealth -100 } } // Running over

  ifaction 0
  {
    action ASCORPIONTANKWAIT
    cstat 257
    clipdist 100
  }
  else
    ifaction ASCORPIONTANKSPIN
  {
    soundonce SCORPIONTANK_ROAM

    ifactioncount 20
    {
      ifrnd 16
        ifcansee
          ifcanshoottarget
      {
        move TANKSTOP geth
        action ATANKSHOOTING
        stopsound SCORPIONTANK_ROAM
      }
    }

    ifrnd 16
      move SCORPIONTANKFORWARD seekplayer
  }
  else
    ifaction ASCORPIONTANKSHOOTING
  {
    ifactioncount 22
    {
      ifpdistg 4192
      {
        
        ifrnd 128 state shoot_rpg else { sound TANK_MORTER shoot MORTER } // Makes it have a 50/50 chance
                                              // whether it shoots a grenade
                                              // or a rocket.
      }
      resetcount
      move 0 action ASCORPIONTANKWAIT
    }
    else
      ifactioncount 2
    {
      ifcansee
      {
        ifpdistl 16384
        {
          ifrnd 128
          {
            sound TANK_JOKE // I used JOKE because it was like a blank slot.
            shoot SHOTGUN  // stronger bullet
          }
        }
        else
          ifrnd 128
        {
          sound PRED_ATTACK
          shoot FIRELASER
        }
      }
      else
      {
        move SCORPIONTANKFORWARD seekplayer
        action ATANKSPIN
      }
    }

    ifrnd 16
    {
      stopsound SCORPIONTANK_ROAM
      move TANKSTOP faceplayerslow
    }
  }
  else
    ifaction ASCORPIONTANKWAIT
  {
    ifactioncount 32
    {
      move SCORPIONTANKFORWARD seekplayer
      action ATANKSPIN
    }
  }
  else
    ifaction ASCORPIONTANKDESTRUCT
  {
    ifactioncount 64
      action ASCORPIONTANKDEAD
    else
      ifactioncount 56
       sound LASERTRIP_ARMING
     else
       ifactioncount 48
         sound LASERTRIP_ARMING
     else
       ifactioncount 32
         sound LASERTRIP_ARMING
     else
       ifactioncount 16
         sound LASERTRIP_ARMING
     break
  }
  else
    ifaction ASCORPIONTANKDEAD
  {
    addkills 1
    hitradius 6144 TOUGH TOUGH TOUGH TOUGH
    sound LASERTRIP_EXPLODE
    state tank_explode
    spawn EXPLOSION2
    state drop_rpg
    ifrnd 128 spawn BURNING
    spawn PIGCOP
    killit
  }

  ifhitweapon
  {
    ifdead
      action ASCORPIONTANKDEAD
    else
    {
      debris SCRAP1 4
      ifaction ASCORPIONTANKSHOOTING break

      ifrnd 192
      {
        move SCORPIONTANKSTOP geth
        action ASCORPIONTANKSHOOTING
        stopsound SCORPIONTANK_ROAM
      }
    }
  }

  ifpdistl 1280
    ifhitspace
      ifp pfacing
        ifangdiffl 512
          action ASCORPIONTANKDESTRUCT
enda


This post has been edited by Firefly_Trooper: 10 November 2018 - 07:03 AM

0

User is offline   Firefly_Trooper 

  • 12

#2


0

User is offline   NightFright 

  • The Truth is in here
  • 836

#3

Several addons were utilizing the unused Pig Cop tank before. Right now, the only one I remember for sure is "XarTech Invasion" from 1997.


This post has been edited by NightFright: 10 November 2018 - 07:33 AM

0

User is offline   Nancsi 

  • 359

#4

It's probably the same as the Tank in the final version, except it can automatically kill you instead of letting you to press any buttons behind. And it has a rocket in addition to the mortar.

JJ Duke Nukem 3D also used these, in fact, they are added next to the other tank. But the coding was VERY poor in that mod.

I honestly think there was more potential in the organic turret.
0

User is offline   Firefly_Trooper 

  • 12

#5

View PostNancsi, on 10 November 2018 - 07:59 AM, said:

It's probably the same as the Tank in the final version, except it can automatically kill you instead of letting you to press any buttons behind. And it has a rocket in addition to the mortar.

JJ Duke Nukem 3D also used these, in fact, they are added next to the other tank. But the coding was VERY poor in that mod.

I honestly think there was more potential in the organic turret.


You must refer to the strange plant that sends acid. This strange creature has also been improved by me.
The idea of ​​this brown tank is good. I'll have to find a way to make it operational. The original Tank, works very well.
0

User is offline   Firefly_Trooper 

  • 12

#6

Corrected codes, Functional brown tank. Just a little detail: when I shoot him at the RPG, he has strange jerks. The sprite advances towards the player in a brutal way.



This post has been edited by Firefly_Trooper: 13 November 2018 - 06:18 AM

1

User is online   Trooper Dan 

  • Duke Plus Developer
  • 3,267

#7

View PostFirefly_Trooper, on 13 November 2018 - 06:05 AM, said:

Corrected codes, Functional brown tank. Just a little detail: when I shoot him at the RPG, he has strange jerks. The sprite advances towards the player in a brutal way.


Yes, that's normal hardcoded behavior. I think it's from a bug going back to the original game whereby if an actor is hit by an RPG, it moves in the direction of htang instead of the opposite direction. You can correct this using your own code or you can use the spriteflag for removing the movement entirely.

EDIT: Actually, I think it simply moves the sprite forwards in the direction it is facing (not at htang).


This post has been edited by Trooper Dan: 13 November 2018 - 11:37 AM

0

User is offline   Firefly_Trooper 

  • 12

#8

Thanks TD. I would not have thought of using this code for that. The CyberKeef boss of the psx version, has the same problem. I just need to add Spriteflag in the code? Is there a specific value?
0

User is offline   Firefly_Trooper 

  • 12

#9

The "spriteflags -1" function works well, except that it activates other monsters on the map. It's strange !
0

User is online   Trooper Dan 

  • Duke Plus Developer
  • 3,267

#10

View PostFirefly_Trooper, on 13 November 2018 - 03:52 PM, said:

The "spriteflags -1" function works well, except that it activates other monsters on the map. It's strange !


Who said anything about using the value -1 for spriteflags? The value for SFLAG_NODAMAGEPUSH is 1048576.
0

User is offline   Firefly_Trooper 

  • 12

#11

View PostTrooper Dan, on 13 November 2018 - 04:34 PM, said:

Who said anything about using the value -1 for spriteflags? The value for SFLAG_NODAMAGEPUSH is 1048576.


Nobody ! I just wanted to do a test. Thanks
0

User is offline   Firefly_Trooper 

  • 12

#12

The code "spriteflags" is fixed. Thanks !
0

User is offline   Firefly_Trooper 

  • 12

#13

Last detail on the brown chariot. He continues to attack, but when the Duke is dead.
0

User is offline   Jimmy 4k 

  • Duke4 Thot Patrol
  • 4,171

#14

The_Fly's CON Supplement has the best coded version, to my knowledge, of the Scorpion Tank if you'd like to look at it.

Posted Image

This post has been edited by Jimmy 4k: 14 November 2018 - 09:42 AM

0

User is offline   Firefly_Trooper 

  • 12

#15

Thank you ! I'm just going to keep the carcass of the tank. No idea about my last problem?

This post has been edited by Firefly_Trooper: 14 November 2018 - 10:29 AM

0

User is offline   Jimmy 4k 

  • Duke4 Thot Patrol
  • 4,171

#16

Study the AI of other well written enemies.

Posted Image
0

User is offline   Firefly_Trooper 

  • 12

#17

I looked at the file you offered me on the Scorpion Tank, I also looked in other codes, I did not find a solution.
0

Share this topic:


Page 1 of 1
  • You cannot start a new topic
  • You cannot reply to this topic


All copyrights and trademarks are property of their respective owners. Instead of reading this text, you could be playing Ion Maiden! ;) © 2018 Voidpoint, LLC

Enter your sign in name and password


Sign in options