GoldenEye: Source Forums

  • December 22, 2024, 06:30:17 pm
  • Welcome, Guest
Advanced search  

News:

Pages: 1 [2] 3 4   Go Down

Author Topic: [Gameplay] Freeze Tag Mode  (Read 31594 times)

0 Members and 3 Guests are viewing this topic.

Troy

  • GE:S Coder
  • 00 Agent
  • ***
  • Posts: 821
  • Reputation Power: 260
  • Troy is awe-inspiring!Troy is awe-inspiring!Troy is awe-inspiring!Troy is awe-inspiring!Troy is awe-inspiring!Troy is awe-inspiring!Troy is awe-inspiring!Troy is awe-inspiring!Troy is awe-inspiring!Troy is awe-inspiring!Troy is awe-inspiring!Troy is awe-inspiring!
  • Offline Offline
Re: [Gameplay] Freeze Tag Mode
« Reply #15 on: November 04, 2012, 08:44:44 pm »

I'm anxious to see it as I don't think it will work.  If an admin turns on jump, then it sounds like the mode will be ruined.
Logged
Complete - Arsenal, One Bullet is Enough, Tournament DM v2, TurboDM
Defunct - Agent Under Fire
VC - Being such a dick, KM must be stroked before springing into action.

kraid

  • Game Artist
  • 007
  • *****
  • Posts: 1,984
  • Reputation Power: 191
  • kraid is awe-inspiring!kraid is awe-inspiring!kraid is awe-inspiring!kraid is awe-inspiring!kraid is awe-inspiring!kraid is awe-inspiring!kraid is awe-inspiring!kraid is awe-inspiring!kraid is awe-inspiring!kraid is awe-inspiring!kraid is awe-inspiring!kraid is awe-inspiring!
  • Offline Offline
    • my Homepage
Re: [Gameplay] Freeze Tag Mode
« Reply #16 on: November 05, 2012, 05:41:09 am »

you don't even need jumping enabled to fall into the decent on the end of runway or beyond the bridges in caves or complex so you surely need to spawn ppl on something like a token- or playerspawn.
Logged

Troy

  • GE:S Coder
  • 00 Agent
  • ***
  • Posts: 821
  • Reputation Power: 260
  • Troy is awe-inspiring!Troy is awe-inspiring!Troy is awe-inspiring!Troy is awe-inspiring!Troy is awe-inspiring!Troy is awe-inspiring!Troy is awe-inspiring!Troy is awe-inspiring!Troy is awe-inspiring!Troy is awe-inspiring!Troy is awe-inspiring!Troy is awe-inspiring!
  • Offline Offline
Re: [Gameplay] Freeze Tag Mode
« Reply #17 on: November 05, 2012, 05:53:20 am »

Yea, that's true as well.  If someone is falling into a pit, and they're killed, the game mode would fail.  It would be worthless to unfreeze them.
Logged
Complete - Arsenal, One Bullet is Enough, Tournament DM v2, TurboDM
Defunct - Agent Under Fire
VC - Being such a dick, KM must be stroked before springing into action.

Joe

  • Secret Agent
  • **
  • Posts: 139
  • Reputation Power: 54
  • Joe has an aura about them.Joe has an aura about them.Joe has an aura about them.Joe has an aura about them.Joe has an aura about them.Joe has an aura about them.Joe has an aura about them.Joe has an aura about them.Joe has an aura about them.Joe has an aura about them.
  • Offline Offline
Re: [Gameplay] Freeze Tag Mode
« Reply #18 on: November 07, 2012, 01:01:04 pm »

Yea, that's true as well.  If someone is falling into a pit, and they're killed, the game mode would fail.  It would be worthless to unfreeze them.
I've decided that I'm going to make resurrection entities spawn at player spawn points because of this map problem and because resurrection entities could block doors if they spawn at player corpses.

I also now think that resurrection token entities should use a grave stone model, if tokens can only use T-posed character models.

I still haven't finished this mode's script because I haven't spent much time working on it since I said I was confident I would have it finished by today.

I'm stuck at the moment because I want to use the Timer Tracker class but there is an error I've not been able to fix.

I've been trying to make it work in a simple DM test script:

Code: [Select]
from GamePlay import GEScenario
from Utils.GETimer import EndRoundCallback, TimerTracker, Timer
import GEEntity, GEPlayer, GEUtil, GEWeapon, GEMPGameRules, GEGlobal

USING_API = GEGlobal.API_VERSION_1_0_0

class Test( GEScenario ):
def GetPrintName( self ):
return "Test"

def GetScenarioHelp( self, help_obj ):
help_obj.SetDescription( "#GES_GP_DEATHMATCH_HELP" )

def GetGameDescription( self ):
if GEMPGameRules.IsTeamplay():
return "Team Deathmatch"
else:
return "Deathmatch"

def __init__( self ):
self.timerTracker = TimerTracker( self )

def GetTeamPlay( self ):
return GEGlobal.TEAMPLAY_TOGGLE

def OnLoadGamePlay( self ):
GEMPGameRules.SetAllowTeamSpawns( False )
self.CreateCVar( "dm_fraglimit", "0", "Enable frag limit for DeathMatch." )

timer = self.timerTracker.CreateTimer( "timer" )
timer.SetAgeRate( 1.0, 1.0 )
timer.SetUpdateCallback( self.TimerUpdate, 1.0 )

def TimerUpdate( self, timer, update_type ):
GEUtil.Msg("Timer Updated")

def OnThink( self ):
fragLimit = int( GEUtil.GetCVarValue( "dm_fraglimit" ) )
if fragLimit != 0:
if GEMPGameRules.IsTeamplay():

teamJ = GEMPGameRules.GetTeam( GEGlobal.TEAM_JANUS );
teamM = GEMPGameRules.GetTeam( GEGlobal.TEAM_MI6 );

jScore = teamJ.GetRoundScore() + teamJ.GetMatchScore()
mScore = teamM.GetRoundScore() + teamM.GetMatchScore()

if jScore >= fragLimit or mScore >= fragLimit:
GEMPGameRules.EndMatch()
else:
for i in range( 32 ):

if not GEPlayer.IsValidPlayerIndex( i ):
continue

player = GEPlayer.GetMPPlayer( i )

if  ( player.GetMatchScore() + player.GetScore() ) >= fragLimit:
GEMPGameRules.EndMatch()

Quote
Traceback (most recent call last):
  File "c:\program files\steam\steamapps\sourcemods\gesource\scripts\python\GamePlayManager.py", line 23, in SetGamePlay
    scenario = getattr( sys.modules[module], ident )()

  File "c:\program files\steam\steamapps\sourcemods\gesource\scripts\python\GamePlay\Test.py", line 21, in __init__
    self.timerTracker = TimerTracker( self )

  File "c:\program files\steam\steamapps\sourcemods\gesource\scripts\python\GamePlay\Utils\GETimer.py", line 20, in __init__
    parent.RegisterEventHook( EventHooks.GP_THINK, self.AgeTimers )

  File "c:\program files\steam\steamapps\sourcemods\gesource\scripts\python\GamePlay\__init__.py", line 22, in RegisterEventHook
    if not self.__hooks.has_key( hook ):
AttributeError: 'Test' object has no attribute '_GEScenario__hooks'
Scenario loading failed for scenario Test
« Last Edit: November 07, 2012, 06:41:55 pm by Joe »
Logged
Free games:FPS + RTS: Renegade X & Battlezone 1.5,RTS: 7 Kingdoms & Open Red Alert, TBS:Hedgewars, playcatan.com & www.wesnoth.org

Joe

  • Secret Agent
  • **
  • Posts: 139
  • Reputation Power: 54
  • Joe has an aura about them.Joe has an aura about them.Joe has an aura about them.Joe has an aura about them.Joe has an aura about them.Joe has an aura about them.Joe has an aura about them.Joe has an aura about them.Joe has an aura about them.Joe has an aura about them.
  • Offline Offline
Re: [Gameplay] Freeze Tag Mode
« Reply #19 on: November 08, 2012, 05:01:04 pm »

I've still not found a solution to the problem I mentioned in my previous post but I have been implementing parts of the script which don't need timers.

I would like to implement resurrection entities using capture area entities but I've not found a way to associate a capture area entity a player enters, with its reference in the token manager. In order for the token manager to delete a specific capture area it needs to be given the capture area's name and I've not been able to get the name from a capture area object by using the functions in CBaseEntity.  The token manager doesn't have a function for returning its capture area entity objects, so I've not been able to map a capture area object to its name in a Python dictionary.

I think the only alternative way for implementing resurrection entities would be to use token entities. However this would allow players to interact with resurrection entities by picking them up instead of standing near them. So player's would not resurrect players in the same way that they would resurrect players in MOHAA's freeze tag mode, which could make this mode less enjoyable than that popular mode.

So if anyone knows how I could get the name for a capture area please let me know.
« Last Edit: November 08, 2012, 05:05:33 pm by Joe »
Logged
Free games:FPS + RTS: Renegade X & Battlezone 1.5,RTS: 7 Kingdoms & Open Red Alert, TBS:Hedgewars, playcatan.com & www.wesnoth.org

WNxEuphonic

  • 00 Agent
  • ***
  • Posts: 217
  • Reputation Power: 106
  • WNxEuphonic is awe-inspiring!WNxEuphonic is awe-inspiring!WNxEuphonic is awe-inspiring!WNxEuphonic is awe-inspiring!WNxEuphonic is awe-inspiring!WNxEuphonic is awe-inspiring!WNxEuphonic is awe-inspiring!WNxEuphonic is awe-inspiring!WNxEuphonic is awe-inspiring!WNxEuphonic is awe-inspiring!WNxEuphonic is awe-inspiring!WNxEuphonic is awe-inspiring!
  • Offline Offline
    • Euphonic.dev
Re: [Gameplay] Freeze Tag Mode
« Reply #20 on: November 08, 2012, 07:25:09 pm »

Hey, check out my Uplink gameplay for how capture areas work (and the older version archived somewhere around here for how to use tokens for a similar effect, the trick is to deny pickup). My advice would be to have two lists (deadJANUS and deadMI6) that keep track of dead players then create capture zones in a number equal to the length of those lists. When a player enters a capture zone, remove it and then remove the top player from the list. Players inside the list are denied spawning, keeping them eliminated until someone hits a capture zone.

Joe

  • Secret Agent
  • **
  • Posts: 139
  • Reputation Power: 54
  • Joe has an aura about them.Joe has an aura about them.Joe has an aura about them.Joe has an aura about them.Joe has an aura about them.Joe has an aura about them.Joe has an aura about them.Joe has an aura about them.Joe has an aura about them.Joe has an aura about them.
  • Offline Offline
Re: [Gameplay] Freeze Tag Mode
« Reply #21 on: November 08, 2012, 09:31:07 pm »

Hey, check out my Uplink gameplay for how capture areas work (and the older version archived somewhere around here for how to use tokens for a similar effect, the trick is to deny pickup). My advice would be to have two lists (deadJANUS and deadMI6) that keep track of dead players then create capture zones in a number equal to the length of those lists. When a player enters a capture zone, remove it and then remove the top player from the list. Players inside the list are denied spawning, keeping them eliminated until someone hits a capture zone.

Thanks for your advice, I will have a look at how capture areas work in your Uplink mode script.
Logged
Free games:FPS + RTS: Renegade X & Battlezone 1.5,RTS: 7 Kingdoms & Open Red Alert, TBS:Hedgewars, playcatan.com & www.wesnoth.org

TriDefiance

  • 00 Agent
  • ***
  • Posts: 343
  • Reputation Power: 78
  • TriDefiance is awe-inspiring!TriDefiance is awe-inspiring!TriDefiance is awe-inspiring!TriDefiance is awe-inspiring!TriDefiance is awe-inspiring!TriDefiance is awe-inspiring!TriDefiance is awe-inspiring!TriDefiance is awe-inspiring!TriDefiance is awe-inspiring!TriDefiance is awe-inspiring!TriDefiance is awe-inspiring!TriDefiance is awe-inspiring!
  • Offline Offline
Re: [Gameplay] Freeze Tag Mode
« Reply #22 on: November 09, 2012, 12:16:30 am »

Hope you can get this gamemode to work! :D
Logged

Joe

  • Secret Agent
  • **
  • Posts: 139
  • Reputation Power: 54
  • Joe has an aura about them.Joe has an aura about them.Joe has an aura about them.Joe has an aura about them.Joe has an aura about them.Joe has an aura about them.Joe has an aura about them.Joe has an aura about them.Joe has an aura about them.Joe has an aura about them.
  • Offline Offline
Re: [Gameplay] Freeze Tag Mode
« Reply #23 on: November 09, 2012, 12:39:48 pm »

I will try to finish the first playable version of this Mode's script by Monday. This version won't allow players to resurrect their team mates from a long distance, so they will have to stand next to their team mates' resurrection entities.
« Last Edit: November 09, 2012, 01:42:56 pm by Joe »
Logged
Free games:FPS + RTS: Renegade X & Battlezone 1.5,RTS: 7 Kingdoms & Open Red Alert, TBS:Hedgewars, playcatan.com & www.wesnoth.org

Joe

  • Secret Agent
  • **
  • Posts: 139
  • Reputation Power: 54
  • Joe has an aura about them.Joe has an aura about them.Joe has an aura about them.Joe has an aura about them.Joe has an aura about them.Joe has an aura about them.Joe has an aura about them.Joe has an aura about them.Joe has an aura about them.Joe has an aura about them.
  • Offline Offline
Re: [Gameplay] Freeze Tag Mode
« Reply #24 on: November 09, 2012, 02:39:16 pm »

I've now added a % development progress guesstimate to the first post in this forum topic, I will occasionally update it.
Logged
Free games:FPS + RTS: Renegade X & Battlezone 1.5,RTS: 7 Kingdoms & Open Red Alert, TBS:Hedgewars, playcatan.com & www.wesnoth.org

Troy

  • GE:S Coder
  • 00 Agent
  • ***
  • Posts: 821
  • Reputation Power: 260
  • Troy is awe-inspiring!Troy is awe-inspiring!Troy is awe-inspiring!Troy is awe-inspiring!Troy is awe-inspiring!Troy is awe-inspiring!Troy is awe-inspiring!Troy is awe-inspiring!Troy is awe-inspiring!Troy is awe-inspiring!Troy is awe-inspiring!Troy is awe-inspiring!
  • Offline Offline
Re: [Gameplay] Freeze Tag Mode
« Reply #25 on: November 09, 2012, 08:24:08 pm »

I hope you're good at Sourcepawn.  Better yet, you could just use someone else's code for the freeze.
Logged
Complete - Arsenal, One Bullet is Enough, Tournament DM v2, TurboDM
Defunct - Agent Under Fire
VC - Being such a dick, KM must be stroked before springing into action.

Joe

  • Secret Agent
  • **
  • Posts: 139
  • Reputation Power: 54
  • Joe has an aura about them.Joe has an aura about them.Joe has an aura about them.Joe has an aura about them.Joe has an aura about them.Joe has an aura about them.Joe has an aura about them.Joe has an aura about them.Joe has an aura about them.Joe has an aura about them.
  • Offline Offline
Re: [Gameplay] Freeze Tag Mode
« Reply #26 on: November 10, 2012, 01:07:54 pm »

I hope you're good at Sourcepawn.  Better yet, you could just use someone else's code for the freeze.

I don't want to freeze players in this mode.
« Last Edit: November 10, 2012, 03:27:45 pm by Joe »
Logged
Free games:FPS + RTS: Renegade X & Battlezone 1.5,RTS: 7 Kingdoms & Open Red Alert, TBS:Hedgewars, playcatan.com & www.wesnoth.org

Joe

  • Secret Agent
  • **
  • Posts: 139
  • Reputation Power: 54
  • Joe has an aura about them.Joe has an aura about them.Joe has an aura about them.Joe has an aura about them.Joe has an aura about them.Joe has an aura about them.Joe has an aura about them.Joe has an aura about them.Joe has an aura about them.Joe has an aura about them.
  • Offline Offline
Re: [Gameplay] Freeze Tag Mode
« Reply #27 on: November 11, 2012, 07:44:32 pm »

I will release the script for version 1 tomorrow when it's ready to be released.
Logged
Free games:FPS + RTS: Renegade X & Battlezone 1.5,RTS: 7 Kingdoms & Open Red Alert, TBS:Hedgewars, playcatan.com & www.wesnoth.org

Joe

  • Secret Agent
  • **
  • Posts: 139
  • Reputation Power: 54
  • Joe has an aura about them.Joe has an aura about them.Joe has an aura about them.Joe has an aura about them.Joe has an aura about them.Joe has an aura about them.Joe has an aura about them.Joe has an aura about them.Joe has an aura about them.Joe has an aura about them.
  • Offline Offline
Re: [Gameplay] Freeze Tag Mode
« Reply #28 on: November 12, 2012, 10:36:34 pm »

I'm very close to having a releasable script but I'm not going to release a script today because I want to spend more time testing it tomorrow and I want to make an important change.

Having played this mode with bots today I now think that spawning resurrection entities at player corpses is important because imo spawning them any where else makes this mode less enjoyable than MOHAA Freeze Tag.

I now know that players can move through character models when they are used as capture area models, so if a capture area entity could be moved from its spawn point to a player's corpse there would be no risk of it blocking a door. I guess moving a capture area entity may not be possible but maybe a script could move spawned tokens.

So I'm going to try to make an eliminated player's resurrection entity appear at their corpse.
Logged
Free games:FPS + RTS: Renegade X & Battlezone 1.5,RTS: 7 Kingdoms & Open Red Alert, TBS:Hedgewars, playcatan.com & www.wesnoth.org

killermonkey

  • GES Programmer
  • Retired Lead Developer
  • GE:S Fanatic
  • *
  • Posts: 5,473
  • Reputation Power: 346
  • killermonkey is awe-inspiring!killermonkey is awe-inspiring!killermonkey is awe-inspiring!killermonkey is awe-inspiring!killermonkey is awe-inspiring!killermonkey is awe-inspiring!killermonkey is awe-inspiring!killermonkey is awe-inspiring!killermonkey is awe-inspiring!killermonkey is awe-inspiring!killermonkey is awe-inspiring!killermonkey is awe-inspiring!
  • Offline Offline
    • DroidMonkey Apps
Re: [Gameplay] Freeze Tag Mode
« Reply #29 on: November 13, 2012, 12:28:08 am »

You cannot move entities from Python. The reason for this is so that you don't inadvertently break something in the game (like moving a player into a wall) or moving an entity into a player. I am not sure how the capture points will react to being moved, but they should be ok. They were not designed to be moved after being placed.

You would have to create a sourcepawn script to handle this.

I am pretty interested to see what you do with this. If it works out I may move some of the sourcepawn script stuff into Python so you can do it all in Python.

BTW, did you end up getting the timers to work? You should use Capture The Key as an example of using advanced timers.
« Last Edit: November 13, 2012, 12:30:04 am by killermonkey »
Logged
Pages: 1 [2] 3 4   Go Up