defaultmap not working?

Ask about ACS, DECORATE, ZScript, or any other scripting questions here!

Moderator: GZDoom Developers

Forum rules
Before asking on how to use a ZDoom feature, read the ZDoom wiki first. If you still don't understand how to use a feature, then ask here.

Please bear in mind that the people helping you do not automatically know how much you know. You may be asked to upload your project file to look at. Don't be afraid to ask questions about what things mean, but also please be patient with the people trying to help you. (And helpers, please be patient with the person you're trying to help!)
Post Reply
User avatar
Mini--Joe
Posts: 97
Joined: Sun Jul 27, 2014 10:25 am

defaultmap not working?

Post by Mini--Joe »

Code: Select all

GameInfo
{
	PlayerClasses = "Commando"
    AddEventHandlers = "ForceFieldHandler", "WoodHandler", "DirtHandler", "GrassHandler"
}

Defaultmap { aircontrol = 1 } 
This is all that is in my MAPINFO lump. I don't understand why it won't work and it's driving me frickin NUTS. I have another pk3 where the Defaultmap works perfectly, and I didn't do anything different for this one.
User avatar
Player701
 
 
Posts: 1710
Joined: Wed May 13, 2009 3:15 am
Graphics Processor: nVidia with Vulkan support
Contact:

Re: defaultmap not working?

Post by Player701 »

See https://zdoom.org/wiki/MAPINFO/Map_definition
ZDoom Wiki wrote:Sets the defaults that will be automatically used for all subsequent map definitions.
You don't have any subsequent map definitions in your MAPINFO, so there are no maps to apply your defaultmap definition to. You either have to redefine the maps one by one, or use an event handler to change Level.aircontrol. I haven't tried the latter myself, but the field is not marked readonly in gzdoom.pk3, so it should work, and if it does, I recommend doing just that because it's a more robust solution.
User avatar
Mini--Joe
Posts: 97
Joined: Sun Jul 27, 2014 10:25 am

Re: defaultmap not working?

Post by Mini--Joe »

Code: Select all

GameInfo
{
	PlayerClasses = "Commando"
    AddEventHandlers = "ForceFieldHandler", "WoodHandler", "DirtHandler", "GrassHandler"
}

Defaultmap { aircontrol = 1 }

map map01 "Heck" { Music = "MUSIC/RUNGHELL.mid" }
It's now this, and it is still not working.
User avatar
Player701
 
 
Posts: 1710
Joined: Wed May 13, 2009 3:15 am
Graphics Processor: nVidia with Vulkan support
Contact:

Re: defaultmap not working?

Post by Player701 »

I just copy-pasted your code (minus the gameinfo block, since I don't have your classes), and it works just fine on Doom II MAP01. If it doesn't work for you, then you probably aren't on MAP01, or something else in your mod must be messing with air control.
User avatar
Mini--Joe
Posts: 97
Joined: Sun Jul 27, 2014 10:25 am

Re: defaultmap not working?

Post by Mini--Joe »

Ok, I also just put it into it's own pk3 and it did not work. Wtf is going on??? It works on one of my mods, but not any other?
User avatar
Player701
 
 
Posts: 1710
Joined: Wed May 13, 2009 3:15 am
Graphics Processor: nVidia with Vulkan support
Contact:

Re: defaultmap not working?

Post by Player701 »

Sorry, I can't say what's wrong unless I can see your mod. However, I won't be able to check it out until morning (it's past midnight where I am). Maybe someone else could do that, though.
Post Reply

Return to “Scripting”