Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Tutorial GetMapCustom
#1
Hello

I havent done any tutorial for a long time, here comes one, is about the use of the command getMapCustom(), it will give you some values from the map you are playing, this values are stored in basemaps.arena file, to use it:

Code:
thing = getMapCustom( "info you want" );

Examples:

Code:
level.environment = getMapCustom( "environment" );
level.mapstring = getMapCustom( "longname" );
level.map = getMapCustom( "map" );
level.gametype = getMapCustom( "gametype" );
level.description = getMapCustom( "description" );
level.mapimage = getMapCustom( "mapimage" );
level.mapoverlay = getMapCustom( "mapoverlay" );
level.alliesname = getMapCustom( "allieschar" );
level.axisname = getMapCustom( "axischar" );

Thats it, you can use it for some stuff, especially the environment, map or mapstring one. OMA

MW3 PART:

In MW3 IW has added a new feature to basemaps.arena, so this getmapcustom() could be good to detect maps:

Code:
mappack

Example of use:

Code:
if( getMapCustom( "mappack" ) == 0 )
level.dlcmap = false;

The previous example means that the map which is currently being played is a original map, no dlc

mappack value = 0 -> Original maps
mappack value = 1 -> mp_italy(Piazza)
mappack value = 2 -> mp_park(Park)
mappack value = 3 -> mp_overwatch(Overwatch)
mappack value = 4 -> mp_morningwood(Morningwood)

Thanks to the xbox modding community for their updated basemaps.arena, I thought it could be nice to update this a bit, Wink
Reply

#2
cool,
Code:
level.oma = getMapCustom( "oma" );
C++/Obj-Cdeveloper. Neko engine wip
Steam: Click
Reply



Forum Jump:


Users browsing this thread:
2 Guest(s)

Forum Powered By MyBB, Theme by © 2002-2024 Melroy van den Berg.