SBARINFO Team + MaxTeams Sub block feature request

killall -9

Moderator: Developers

Post Reply
User avatar
DTDsphere
Forum Regular
Posts: 162
Joined: Mon Jun 04, 2012 10:58 am
Location: England
Contact:

SBARINFO Team + MaxTeams Sub block feature request

#1

Post by DTDsphere » Mon Oct 17, 2016 6:42 am

https://zandronum.com/tracker/view.php?id=2507

It's been a year. I would like to bring this back up to light just so it's more likely to actually be added.

Feature request:
Team <team> - Executes the subblock if the team number (defined in TEAMINFO) equals <team>

MaxTeams <maxteams> - Executes the subblock if the max number of teams equals <maxteams>
(So the HUD can reorganise itself for when you have more than 2 teams.)

User avatar
Empyre
Zandrone
Posts: 1204
Joined: Sun Jul 08, 2012 6:41 am
Location: Garland, TX, USA

Re: SBARINFO Team + MaxTeams Sub block feature request

#2

Post by Empyre » Mon Oct 17, 2016 11:25 pm

Bug reports and feature requests need to go in the Bug Tracker (linked at the top of every page on this site), or they will probably not be considered.
"For the world is hollow, and I have touched the sky."

Catastrophe
Addicted to Zandronum
Posts: 2558
Joined: Sat Jun 02, 2012 2:44 am

Re: SBARINFO Team + MaxTeams Sub block feature request

#3

Post by Catastrophe » Tue Oct 18, 2016 1:23 am

To be honest you'd be better off using DECORATE+ACS and SBARINFO than wait another year for this.

User avatar
DTDsphere
Forum Regular
Posts: 162
Joined: Mon Jun 04, 2012 10:58 am
Location: England
Contact:

Re: SBARINFO Team + MaxTeams Sub block feature request

#4

Post by DTDsphere » Sat Nov 05, 2016 1:18 am

Empyre wrote:Bug reports and feature requests need to go in the Bug Tracker (linked at the top of every page on this site), or they will probably not be considered.
Hey Mr Superunhelpful, check the link at the top of my post.
Catastrophe wrote:To be honest you'd be better off using DECORATE+ACS and SBARINFO than wait another year for this.
It's a shit method to use DECORATE+ACS, if I try to do any changes like making the hud blue if you're on the blue team, it flashes red every time you respawn.

User avatar
Empyre
Zandrone
Posts: 1204
Joined: Sun Jul 08, 2012 6:41 am
Location: Garland, TX, USA

Re: SBARINFO Team + MaxTeams Sub block feature request

#5

Post by Empyre » Sat Nov 05, 2016 6:50 am

I was trying to be helpful, but failed this time.
"For the world is hollow, and I have touched the sky."

Catastrophe
Addicted to Zandronum
Posts: 2558
Joined: Sat Jun 02, 2012 2:44 am

Re: SBARINFO Team + MaxTeams Sub block feature request

#6

Post by Catastrophe » Sat Nov 05, 2016 3:44 pm

DTDsphere wrote:
Catastrophe wrote:To be honest you'd be better off using DECORATE+ACS and SBARINFO than wait another year for this.
It's a shit method to use DECORATE+ACS, if I try to do any changes like making the hud blue if you're on the blue team, it flashes red every time you respawn.
Then you're doing it completely wrong. Make two inventory items via decorate, isblue and isred, give the items appropriately via ACS, then on SBARINFO use isblue and isred to render differently per team.

User avatar
DTDsphere
Forum Regular
Posts: 162
Joined: Mon Jun 04, 2012 10:58 am
Location: England
Contact:

Re: SBARINFO Team + MaxTeams Sub block feature request

#7

Post by DTDsphere » Sat Nov 05, 2016 9:43 pm

Catastrophe wrote:Then you're doing it completely wrong. Make two inventory items via decorate, isblue and isred, give the items appropriately via ACS, then on SBARINFO use isblue and isred to render differently per team.
You say I'm doing it completely wrong and then proceed to describe exactly what I'm doing.

Catastrophe
Addicted to Zandronum
Posts: 2558
Joined: Sat Jun 02, 2012 2:44 am

Re: SBARINFO Team + MaxTeams Sub block feature request

#8

Post by Catastrophe » Sat Nov 05, 2016 9:56 pm

DTDsphere wrote:
Catastrophe wrote:Then you're doing it completely wrong. Make two inventory items via decorate, isblue and isred, give the items appropriately via ACS, then on SBARINFO use isblue and isred to render differently per team.
You say I'm doing it completely wrong and then proceed to describe exactly what I'm doing.
You're clearly doing it wrong if I'm able to do it with my mod. Did you forget to give the items back once the player respawns using a RESPAWN script? And did you give the inventory items the undroppable flag? If you answered no to any of these, then you're doing it wrong.

User avatar
DTDsphere
Forum Regular
Posts: 162
Joined: Mon Jun 04, 2012 10:58 am
Location: England
Contact:

Re: SBARINFO Team + MaxTeams Sub block feature request

#9

Post by DTDsphere » Sun Nov 06, 2016 12:22 am

Catastrophe wrote:
DTDsphere wrote:
Catastrophe wrote:Then you're doing it completely wrong. Make two inventory items via decorate, isblue and isred, give the items appropriately via ACS, then on SBARINFO use isblue and isred to render differently per team.
You say I'm doing it completely wrong and then proceed to describe exactly what I'm doing.
You're clearly doing it wrong if I'm able to do it with my mod. Did you forget to give the items back once the player respawns using a RESPAWN script? And did you give the inventory items the undroppable flag? If you answered no to any of these, then you're doing it wrong.

Code: Select all

#library "team_hud"
#include "zcommon.acs"

Script 988 RESPAWN clientside 
{
if ("Teamplay" == False)
	{Terminate;}
	else
		{
		if (PlayerTeam() == 1)
			{Terminate;}	
		if (PlayerTeam() == 0)
			{GiveInventory("HUD_PlayerTeam", 1);}
		}
}

Script 987 ENTER clientside 
{
if ("Teamplay" == False)
	{Terminate;}
	else
		{
		if (PlayerTeam() == 1)
			{Terminate;}	
		if (PlayerTeam() == 0)
			{GiveInventory("HUD_PlayerTeam", 1);}
		}
}

Catastrophe
Addicted to Zandronum
Posts: 2558
Joined: Sat Jun 02, 2012 2:44 am

Re: SBARINFO Team + MaxTeams Sub block feature request

#10

Post by Catastrophe » Sun Nov 06, 2016 11:01 am

Try it w/o using clientside, also "teamplay" == false? Aren't you supposed to use getCvar with that?

Post Reply