Start game with no guns at all?

Archive of the old editing forum
Forum rules
Before asking on how to use a ZDoom feature, read the ZDoom wiki first. This forum is archived - please use this set of forums to ask new questions.
Locked
User avatar
9skulls
Posts: 62
Joined: Sat Sep 20, 2008 4:53 am
Location: Still at the main menu -screen
Contact:

Start game with no guns at all?

Post by 9skulls »

How can I implement that idea to the game? Making the game start so that player doesnt have any guns at all, only fists. The gun would be found only later on in the game.

I know that this needs some scripting, just dunno which commands to use...

Help appreciated!
User avatar
Enjay
 
 
Posts: 27201
Joined: Tue Jul 15, 2003 4:58 pm
Location: Scotland
Contact:

Re: Start game with no guns at all?

Post by Enjay »

An easy and reliable way that would work for any map would be to use DECORATE to make a custom player class that only gets the fists as a start item.
User avatar
jallamann
Posts: 2271
Joined: Mon May 24, 2004 8:25 am
Location: Ålesund, Norway
Contact:

Re: Start game with no guns at all?

Post by jallamann »

[wiki]ClearInventory[/wiki]
User avatar
FuzzballFox
Posts: 1905
Joined: Thu Jan 24, 2008 10:19 am
Location: Hampshire UK

Re: Start game with no guns at all?

Post by FuzzballFox »

Code: Select all

#include "zcommon.acs"

script 999 OPEN 
{
 ClearInventory();
 GiveInventory("Fist", 1);
}
This should work, just stick in in your ACS thingy and away you go! :D
User avatar
9skulls
Posts: 62
Joined: Sat Sep 20, 2008 4:53 am
Location: Still at the main menu -screen
Contact:

Re: Start game with no guns at all?

Post by 9skulls »

Yeah, those inventory -tags did the trick. Thanks for the tip!
User avatar
HotWax
Posts: 10002
Joined: Fri Jul 18, 2003 6:18 pm
Location: Idaho Falls, ID

Re: Start game with no guns at all?

Post by HotWax »

And yet Enjay's method is the most correct, and he gets completely ignored. :P
User avatar
Cutmanmike
Posts: 11354
Joined: Mon Oct 06, 2003 3:41 pm
Operating System Version (Optional): Windows 10
Location: United Kingdom
Contact:

Re: Start game with no guns at all?

Post by Cutmanmike »

I dunno I would have used ClearInventory if I was just making a map.
User avatar
Enjay
 
 
Posts: 27201
Joined: Tue Jul 15, 2003 4:58 pm
Location: Scotland
Contact:

Re: Start game with no guns at all?

Post by Enjay »

I probably would too. However, there was something in the phrasing of the original question that made me think he might want something a bit more robust that would, I dunno, allow warping to different maps or whatever and still guarantee the "base condition" of the player as a no-pistol one.
Locked

Return to “Editing (Archive)”