Renegade Public Forums
C&C: Renegade --> Dying since 2003™, resurrected in 2024!
Home » Renegade Discussions » Mod Forum » Detecting when gameplay stops pending
Detecting when gameplay stops pending [message #241599] Sat, 27 January 2007 16:31 Go to next message
danpaul88 is currently offline  danpaul88
Messages: 5795
Registered: June 2004
Location: England
Karma: 0
General (5 Stars)
How can I detect when gameplay is no longer pending in the FDS? I have some custom scripts which work fine in LAN mode etc, but in the FDS they crash because they use Get_Shield_Type() on an obj while gameplay is still pending, which seems to cause it to crash.

http://steamsignature.com/card/1/76561197975867233.png
Re: Detecting when gameplay stops pending [message #241602 is a reply to message #241599] Sat, 27 January 2007 16:36 Go to previous messageGo to next message
jnz is currently offline  jnz
Messages: 3396
Registered: July 2006
Location: 30th century
Karma: 0
General (3 Stars)
have a look for a function called "Is_GameplayPermitted" its something like that.
Re: Detecting when gameplay stops pending [message #241606 is a reply to message #241599] Sat, 27 January 2007 16:51 Go to previous messageGo to next message
zunnie is currently offline  zunnie
Messages: 2959
Registered: September 2003
Location: Netherlands
Karma: 0
General (2 Stars)

If ssaow server:

if (Is_Gameplay_Permitted())
{
std::string gameplay;
StrFormat2(gameplay,"Gameplay is permitted");
FDSMessage(gameplay,"_GENERAL");
}


that would work i think and also log it in ssaowlog.


https://multiplayerforums.com/uploads/monthly_2018_03/TCW2_Signature.png.6236a0dbc6e1e53472a18fe8cd15e47b.png
Re: Detecting when gameplay stops pending [message #241607 is a reply to message #241599] Sat, 27 January 2007 17:05 Go to previous messageGo to next message
danpaul88 is currently offline  danpaul88
Messages: 5795
Registered: June 2004
Location: England
Karma: 0
General (5 Stars)
Yeah, thanks, was looking for something with pending in the name Razz

It still does not work if the FDS is set to 1 player (since it assumes that means its NOT pending, but still causes the crash), but on player counts above 1 it works fine Smile


http://steamsignature.com/card/1/76561197975867233.png
Re: Detecting when gameplay stops pending [message #241608 is a reply to message #241599] Sat, 27 January 2007 17:06 Go to previous messageGo to next message
jnz is currently offline  jnz
Messages: 3396
Registered: July 2006
Location: 30th century
Karma: 0
General (3 Stars)
if the server is one player. it isn't pending, or mine doesn't :/
Re: Detecting when gameplay stops pending [message #241613 is a reply to message #241599] Sat, 27 January 2007 17:40 Go to previous messageGo to next message
danpaul88 is currently offline  danpaul88
Messages: 5795
Registered: June 2004
Location: England
Karma: 0
General (5 Stars)
Hmm... another problem... for some reason Get_Shield_Type seems to crash the FDS no matter when you use it... does this command not work in the FDS for some reason?

http://steamsignature.com/card/1/76561197975867233.png

[Updated on: Sat, 27 January 2007 17:48]

Report message to a moderator

Re: Detecting when gameplay stops pending [message #241623 is a reply to message #241599] Sat, 27 January 2007 18:07 Go to previous messageGo to next message
jnz is currently offline  jnz
Messages: 3396
Registered: July 2006
Location: 30th century
Karma: 0
General (3 Stars)
i have used that before... what argument are you passing it?
Re: Detecting when gameplay stops pending [message #241736 is a reply to message #241599] Sun, 28 January 2007 05:28 Go to previous message
danpaul88 is currently offline  danpaul88
Messages: 5795
Registered: June 2004
Location: England
Karma: 0
General (5 Stars)
strcpy_s ( defaultShieldType, sizeof( defaultShieldType ), Get_Shield_Type ( obj ) );


It works if you play LAN or host through Renegade, but it crashes the FDS unless I comment out that line...


http://steamsignature.com/card/1/76561197975867233.png
Previous Topic: sniper hud
Next Topic: Sounds
Goto Forum:
  


Current Time: Mon Nov 04 07:49:50 MST 2024

Total time taken to generate the page: 0.00830 seconds