[SOLVED] Weapon blocks all actors

Discuss all aspects related to modding Zandronum here.
Post Reply
User avatar
Fabysk
Forum Regular
Posts: 469
Joined: Sat Sep 22, 2012 8:17 pm
Location: In a house...duhh

[SOLVED] Weapon blocks all actors

#1

Post by Fabysk » Sun Apr 20, 2014 11:32 pm

Is it possible to make a weapon that blocks Actors? I went ahead and created the weapon.

[spoiler]

Code: Select all

ACTOR AssaultSheild : Weapon 10031
{
  Game Doom
  Weapon.SelectionOrder 3700
  Weapon.Kickback 200
  +NOAUTOFIRE
  States
  {
  Ready:
    SHLD A 1 A_WeaponReady
    Loop
  Deselect:
    SHLD A 1 A_Lower
    Loop
  Select:
    SHLD A 1 A_Raise
    Loop
  Fire:
    SHLD B 2
    SHLD C 2
    SHLD D 2
    SHLD E 2
    SHLD F 2
    SHLD G 3 A_CustomPunch(60, 0, 0, "Sheild_Hit")
    SHLD H 2
    SHLD I 2
    SHLD J 2
    SHLD K 2
    SHLD L 3
    Goto Ready
  }
}
[/spoiler]

This is obviously a Riot Shield
Last edited by Fabysk on Tue Apr 22, 2014 11:46 pm, edited 1 time in total.
Image Image Image

Lollipop
Zandrone
Posts: 1124
Joined: Tue Jul 24, 2012 10:34 am
Location: Denmark

RE: Weapon blocks all actors

#2

Post by Lollipop » Mon Apr 21, 2014 9:30 am

All I can say is to try and dig into brutal hexen and look really
Combinebobnt wrote:i can see the forum league is taking off much better than the ctf ones
GalactusToday at 1:07 PM
are you getting uncomfortable jap
feeling something happen down there

User avatar
Dusk
Developer
Posts: 581
Joined: Thu May 24, 2012 9:59 pm
Location: Turku

RE: Weapon blocks all actors

#3

Post by Dusk » Mon Apr 21, 2014 12:52 pm

A weapon doesn't really exist in the map other than as a pickup. The ready/select/deselect/fire states are actually called by the player.

You could try a couple of approaches:
  • spawn blocking actors in an arc in front of the player in formation of the shield, spawn them with ACS every tic and make them last for only that tic
  • use the 2.0 alpha build and use A_Blast, though this will blast everything around the player.
  • spawn A_Blast-calling actors in an arc in front of the player? Might cause trouble.

User avatar
Fabysk
Forum Regular
Posts: 469
Joined: Sat Sep 22, 2012 8:17 pm
Location: In a house...duhh

RE: Weapon blocks all actors

#4

Post by Fabysk » Tue Apr 22, 2014 5:00 am

Lollipop wrote: All I can say is to try and dig into brutal hexen and look really
I have found the weapon BattleAxe that uses the "ShieldDefense" Actor. I have tried to put it in, modifying it where it just blocks actors, but it results in doing absolutly nothing. What about making the incoming actors being pushed away. Using A_RadiusThrust works fine, but it also pushes the player. Sadly, RTF_AFFECTSOURCE doesn't work anymore. How do I make this possible with just the weapon pushing actors away a few feet?
Image Image Image

User avatar
CloudFlash
Zandrone
Posts: 1074
Joined: Mon Jun 04, 2012 5:35 pm
Location: Wonderland (except not really)

RE: Weapon blocks all actors

#5

Post by CloudFlash » Tue Apr 22, 2014 7:42 am

Fabysk wrote: Using A_RadiusThrust works fine, but it also pushes the player.
If memory serves, GvH had similar problems, which was solved by increasing the mass of player classes. See if it works in your case.
https://i.imgflip.com/i5tpe.jpg
*Hey, who wants to hear my solution to the modern world's problems? ^Me! %Me! @Me! #Me! *WELL TOO BAD @Did he just stab himself with this butcher knife? %Looks like it ^Hey, the pizza guy arrived! %Pizza! Yey

User avatar
Fabysk
Forum Regular
Posts: 469
Joined: Sat Sep 22, 2012 8:17 pm
Location: In a house...duhh

RE: Weapon blocks all actors

#6

Post by Fabysk » Tue Apr 22, 2014 11:45 pm

CloudFlash wrote: If memory serves, GvH had similar problems, which was solved by increasing the mass of player classes. See if it works in your case.
Thank you CloudFlash. Changing the mass of the player solved my problem.
Image Image Image

Post Reply