★ Smart Weapons Fully Loaded 4★ [Updated 14/12/20]

Search, find and discuss about Mutators!
User avatar
Posts: 5193
Joined: Sun May 09, 2010 6:15 pm
Location: On the roof.

Re: ★ Smart Weapons Fully Loaded 4★ [Updated 14/12/20]

Post by sektor2111 » Wed Dec 16, 2020 4:49 pm

Barbie wrote:
Fri Dec 11, 2020 11:58 pm
I remember that @sektor2111 has experimented with such.
I did not reinvent the wheel. Higor pointed nice codes in how to launch certain function only in certain map. Also in said function you can "dynamicloadobject" something specific for a map based on its name - this is how was born NavAdder supporting a lot of such plugins/modules/components/adds.

Code: Select all

		LevelName = String(Outer.Name);
		log ("Map's name is:"@LevelName,'NavAdder');
		LevelName0 = Caps("SS_NVAD"$LevelName)$".PathsMapper";
		log ("Personal seeking strategy: Looking for a class called >"@LevelName0,'NavAdder');
		Module = Class<Actor>( DynamicLoadObject(LevelName0, class'Class',True) ); //Warning at plain UT with this "True" - it might be a hazard
		if ( Module == None )
//Report something
// Spawn it
			log ("Found module, attempt loading... "$Module,'NavAdder');
			if ( Module != None )
				log ("Module has been started...",'NavAdder');
				log ("Bork... Module failed to spawn in this Level...",'NavAdder');
Each map can have separate packages - I had to update this thing because... we can have CTF and DM map with similar names it's why I used a paranoia check because I had real reasons for that... These modules will execute their PreBeginplay in which you can split tasks Server-Client according to map needs: lights, decorations, items, blockers (jerking BT zones), kill spots, moving movers away and/or changing their operation mode, all sort of goodies... shortly said a bit of run-time map editing.
Monster Gaming Server is running several maps "re-edited" in run-time this way. Very visible tweaked map sample: MH-MinasTirith (and not only that).
Advantage XC_Engine mapping as ServerPackages automatically these "for-client" plugins directly if are found... no ini file edited is ever needed but NavAdder's white list (maps that are always excepted for any reasons).