Massassi Forums Logo

This is the static archive of the Massassi Forums. The forums are closed indefinitely. Thanks for all the memories!

You can also download Super Old Archived Message Boards from when Massassi first started.

"View" counts are as of the day the forums were archived, and will no longer increase.

ForumsCog Forum → Weapon questions.
Weapon questions.
2003-07-04, 4:12 AM #1
I'm working on a new weapon, but the way it is now won't work in MP (due to model switching) and I was wondering, if I would use
Code:
if (IsServer())
{
code for SP gun
}
if (IsMulti())
{
code for MP gun
}

Would that work? I've never done anything with conditions before so I don't know if I have even that set up right.

------------------
Look for my current project, The Force in Your Soul.
Last week I cudn't evn spel grajuat, but now I is one.

*Takes out his blaster and fires shots at the wall, the blastmarks leave the words "S-TROOPER WUZ 'ERE!!!"
2003-07-04, 10:03 AM #2
You need a simple condition to test for a multiplayer or singleplayer game?

Code:
if(!IsMulti())
{
   // sp code
}
else
{
   // mp code
}


IsServer() won't work because it returns false in SP. BTW, here's a tutorial you should read.

------------------
Author of the JK DataMaster, Parsec, Scribe, and the EditPlus Cog Files.
Author of the JK DataMaster, Parsec, Scribe, and the EditPlus Cog Files.
2003-07-06, 9:38 AM #3
Ok, I'll try that, and thanks for the tutorial, I understand it a little better now, I'll have to read through it again later.

------------------
Look for my current project, The Force in Your Soul.
Last week I cudn't evn spel grajuat, but now I is one.

*Takes out his blaster and fires shots at the wall, the blastmarks leave the words "S-TROOPER WUZ 'ERE!!!"

↑ Up to the top!