.:: Bots United ::.  
filebase forums discord server github wiki web
cubebot epodbot fritzbot gravebot grogbot hpbbot ivpbot jkbotti joebot
meanmod podbotmm racc rcbot realbot sandbot shrikebot soulfathermaps yapb

Go Back   .:: Bots United ::. > Developer's Farm > General Bot Coding
General Bot Coding See what a pain it is to get those little mechs shooting around

Reply
 
Thread Tools
Forcing everyone to respawn after death
Old
  (#1)
AssasinoRuso
Member
 
Status: Offline
Posts: 8
Join Date: May 2005
Default Forcing everyone to respawn after death - 19-05-2005

Blop I've been trying for a long time now to make everyone respawn like in the deathmatch mod. The farthest I've gotten is: Spectator mode, player respawns hands respawn near head.... when you click there's a flash on the hands.... basically I guess I might be stuck in spectator mode.....

Anyone done this before?
  
Reply With Quote
Re: Forcing everyone to respawn after death
Old
  (#2)
Pierre-Marie Baty
Roi de France
 
Pierre-Marie Baty's Avatar
 
Status: Offline
Posts: 5,049
Join Date: Nov 2003
Location: 46°43'60N 0°43'0W 0.187A
Default Re: Forcing everyone to respawn after death - 19-05-2005

Please be more explicative. Is it a full mod you're making out of the SDK or is it one of those AMX/metamod plugins ? Which engine is it for (HL/Source) ? What are you doing exactly ?



RACC home - Bots-United: beer, babies & bots (especially the latter)
"Learn to think by yourself, else others will do it for you."
  
Reply With Quote
Re: Forcing everyone to respawn after death
Old
  (#3)
AssasinoRuso
Member
 
Status: Offline
Posts: 8
Join Date: May 2005
Default Re: Forcing everyone to respawn after death - 20-05-2005

err counter-strike 1.6.... dll wrapper HPB_Bot template to be specific. All I want to do is to allow players to respawn after they get killed instantly instead of at the round end. All I'm looking for is the respawn code or theory.
  
Reply With Quote
Re: Forcing everyone to respawn after death
Old
  (#4)
The Storm
Council Member / E[POD]bot developer
 
The Storm's Avatar
 
Status: Offline
Posts: 1,618
Join Date: Jul 2004
Location: Bulgaria
Default Re: Forcing everyone to respawn after death - 20-05-2005

You don't need to code anythink. There is respawn script for AMX. Just look in the AMX web site. But maybe you want to make your own plugin?
  
Reply With Quote
Re: Forcing everyone to respawn after death
Old
  (#5)
AssasinoRuso
Member
 
Status: Offline
Posts: 8
Join Date: May 2005
Default Re: Forcing everyone to respawn after death - 21-05-2005

This code has nothing to do with amx. And I am not going to use amx just to respawn. The amx plugin uses a native function in the amx core and I can't find it cause I dont use cvs.
  
Reply With Quote
Re: Forcing everyone to respawn after death
Old
  (#6)
Lazy
Member
 
Lazy's Avatar
 
Status: Offline
Posts: 236
Join Date: Jan 2004
Location: Toronto, Ontario, Canada
Default Re: Forcing everyone to respawn after death - 21-05-2005

Try calling pfnSpawn on the player's edict_t pointer.
  
Reply With Quote
Re: Forcing everyone to respawn after death
Old
  (#7)
Pierre-Marie Baty
Roi de France
 
Pierre-Marie Baty's Avatar
 
Status: Offline
Posts: 5,049
Join Date: Nov 2003
Location: 46°43'60N 0°43'0W 0.187A
Default Re: Forcing everyone to respawn after death - 22-05-2005

It won't work this way. But even if you don't use CVS, you can download the AMX source code and look it up, no ?



RACC home - Bots-United: beer, babies & bots (especially the latter)
"Learn to think by yourself, else others will do it for you."
  
Reply With Quote
Re: Forcing everyone to respawn after death
Old
  (#8)
T(+)rget
AMX Dev Team
 
T(+)rget's Avatar
 
Status: Offline
Posts: 28
Join Date: Dec 2004
Location: UK
Default Re: Forcing everyone to respawn after death - 23-05-2005

Lets begin: (Taken from AMX Fun Module - Unreleased)

// Lets make them respawnable 1st
if(pEdict->v.deadflag != DEAD_RESPAWNABLE) {
pEdict->v.deadflag = DEAD_RESPAWNABLE;
}

// Make sure the camera is set back correctly
pEdict->v.iuser1 = 0;

// Now respawn the player/bot
pfnSpawn(pEdict);

Quick note:
Player/Bot will spawn with default equipment.

Last edited by T(+)rget; 23-05-2005 at 23:52..
  
Reply With Quote
Re: Forcing everyone to respawn after death
Old
  (#9)
Lazy
Member
 
Lazy's Avatar
 
Status: Offline
Posts: 236
Join Date: Jan 2004
Location: Toronto, Ontario, Canada
Default Re: Forcing everyone to respawn after death - 24-05-2005

[offtopic]
Isn't it cheaper to just set the deadflag to DEAD_RESPAWNABLE rather than always checking the value first?
[/offtopic]
  
Reply With Quote
Re: Forcing everyone to respawn after death
Old
  (#10)
Pierre-Marie Baty
Roi de France
 
Pierre-Marie Baty's Avatar
 
Status: Offline
Posts: 5,049
Join Date: Nov 2003
Location: 46°43'60N 0°43'0W 0.187A
Default Re: Forcing everyone to respawn after death - 24-05-2005

obviously yes...

Didn't know that iuser1 was holding the camera settings for the players. Good to know.



RACC home - Bots-United: beer, babies & bots (especially the latter)
"Learn to think by yourself, else others will do it for you."
  
Reply With Quote
Reply


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump



Powered by vBulletin® Version 3.8.2
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
vBulletin Skin developed by: vBStyles.com