Enslaved for UT

Share interesting stuff you have found or created yourself.
User avatar
OjitroC
Godlike
Posts: 3750
Joined: Sat Sep 12, 2015 8:46 pm

Re: Enslaved for UT

Post by OjitroC »

Gustavo6046 wrote: Nope, I just extracted, loaded up OldSkool Amp'd, ran the map, and it saved sucesfully.
Yes it can be saved when playing it as a SP using OldSkool - the issue here now is to do with playing it as a MH map!
Gustavo6046 wrote: I'm gonna do now some UnrealScript algorithm to spawn more player starts near existing ones where reachable.
That's what Sektor's LessTele2 does though it also looks for other points (navigation points, etc) at which to spawn players/bots. The problem with Enslaved is the 'start' area is small (a cell) and so few player starts can be added because of the space available. To get more player starts in one would need to edit it and put starts in outside the cell in the corridor or elsewhere.

So have a look at Sektor's stuff as that will be instructive for you, plus extremely effective in use in the game.
User avatar
Barbie
Godlike
Posts: 2955
Joined: Fri Sep 25, 2015 9:01 pm
Location: moved without proper hashing

Re: Enslaved for UT

Post by Barbie »

Gustavo6046 wrote:I'm gonna do now some UnrealScript algorithm to spawn more player starts near existing ones where reachable.
The following may help you with that: It collects the enabled existing playerstarts and then tries to spawn a custom PlayerStart at some places around them. If successful, these new Playerstarts are added to the end of the list of existing PlayerStarts.
The current overridden function of "GameInfo.FindPlayerStart" may have to be adapted to use the additional created PlayerStarts. Also PlayerStarts can be spawned in Movers and therefore be unusable - I don't know how to avoid that.
Create additional PlayerStarts

Code: Select all

function bool PlayerStartCreate(PlayerStart PS, out float RotationAngle, out PlayerStart NewPlayerStart, ELogType Logtype) {
/*******************************************************************************
Tries to spawn a new PlayerStartSB in the area around *PS*.
*******************************************************************************/
local vector NewLoc, Offset;
local float radius, RotationInc, LastUsedAngle;
local PlayerStart Dummy;

	if (Logtype >= LOG_Debug)
		log(self $ ".PlayerStartCreate DEBUG: called with PlayerStart=" $ PS $ ", RotationAngle=" $ RotationAngle);
	Offset.z = 0;
	RotationInc = pi / 6;
	radius = PS.collisionRadius + class'PlayerStartSB'.Default.collisionRadius;
	while (RotationAngle < 2 * Pi)
	{
		Offset.x = radius * sin(RotationAngle);
		Offset.y = radius * cos(RotationAngle);
		LastUsedAngle = RotationAngle;
		RotationAngle += RotationInc;
		NewLoc = PS.Location + Offset;
		if ( ! RadiusActorsHave(class'PlayerStart', class'PlayerStartSB'.Default.CollisionRadius, NewLoc))
		{
			Dummy = spawn(class'PlayerStartSB', PS.Owner, PS.Tag, NewLoc, PS.Rotation);
			if (Dummy != None)
			{
				if (
					RadiusActorsHave(class'PlayerStart', Dummy.CollisionRadius, Dummy.Location, , Dummy)
				||
					RadiusActorsHave(class'Mover', Dummy.CollisionRadius, Dummy.Location)
				)
				{
					if (Logtype >= LOG_Debug)
						log(self $ ".PlayerStartCreate DEBUG: spawned PlayerStart too close to another, deleting " @ Dummy);
					dummy.Destroy();
				}
				else
				{
					NewPlayerStart = Dummy;
					// NewPlayerStart.Tag is set by *Spawn()*
					NewPlayerStart.bCoopStart = PS.bCoopStart;
					NewPlayerStart.bSinglePlayerStart = PS.bSinglePlayerStart;
					NewPlayerStart.TeamNumber = PS.TeamNumber;
					if (Logtype >= LOG_Info)
						LogEx("PlayerStartCreate", NewPlayerStart @ "spawned at" @ NewPlayerStart.location $ ", RotationAngle=" $ LastUsedAngle);
					return true;
				}
			}
			else
				if (Logtype >= LOG_Debug)
					log(self $ ".PlayerStartCreate DEBUG: spawning NewPlayerStart failed at location" @ NewLoc);
		}
		else
			if (Logtype >= LOG_Debug)
				log(self $ ".PlayerStartCreate DEBUG: location busy:" @ NewLoc @ "with RotationAngle=" $ LastUsedAngle);
	}
	if (Logtype >= LOG_Debug)
		if (RotationAngle >= 2 * Pi)
			log(self $ ".PlayerStartCreate DEBUG: RotationAngle=" $ RotationAngle @ "exhausted, terminating function");
	return false;
}

function int PlayerStartsCreate(byte DesiredPlayerStartCount, ELogType Logtype) {
/*******************************************************************************
Spawns up to *DesiredPlayerStartCount*-1 addditional PlayerStarts around
existing and enabled PlayerStarts.
The number of created PlayerStarts is returned.
*******************************************************************************/
local PlayerStart PlayerStarts[32], PS;
local int PlayerStartsCount, i;
local float RotationAngle;
local int result;

	if (DesiredPlayerStartCount > ArrayCount(PlayerStarts))
	{
		warn("DesiredPlayerStartCount=" $ DesiredPlayerStartCount @ "exceeds hardcoded limit of" @ ArrayCount(PlayerStarts));
		DesiredPlayerStartCount = ArrayCount(PlayerStarts);
	}
	foreach AllActors(class'PlayerStart', PS) // collect all active PlayerStarts
		if (PS.bEnabled)
		{
			PlayerStarts[PlayerStartsCount] = PS;
			PlayerStartsCount++;
			if (PlayerStartsCount >= DesiredPlayerStartCount)
				return result; // enough PlayerStarts available, nothing to do...
		}
	if (PlayerStartsCount == 0)
	{
		warn("no enabled PlayerStarts found, exiting...");
		return 0;
	}
	if (Logtype >= LOG_Verbose)
		LogEx("PlayerStartsCreate", "number of enabled playerstarts:" @ PlayerStartsCount);
	i = 0;
	while (PlayerStartsCount < DesiredPlayerStartCount && i < PlayerStartsCount)
	{
		RotationAngle = 0;
		while (i < PlayerStartsCount && PlayerStartCreate(PlayerStarts[i], RotationAngle, PS, Logtype))
		{
			PlayerStarts[PlayerStartsCount] = PS;
			PlayerStartsCount++;
			result++;
			if (PlayerStartsCount >= DesiredPlayerStartCount)
				return result;
		}
		if (Logtype >= LOG_Debug)
			LogEx("PlayerStartsCreate", "next loop with i=" $ i $ ", PlayerStartsCount=" $ PlayerStartsCount);
		i++;
	}
	return result;
}
PlayerStartSB

Code: Select all

class PlayerStartSB extends PlayerStart;

defaultproperties {
	bAutoBuilt=false
	bStatic=false
	bCollideWorld=true
	bCollideWhenPlacing=true
	// uncomment the following for visual debugging:
	// bHidden=false
	// Mesh=LodMesh'UnrealShare.Pottery0M'
	// DrawType=DT_Mesh
} 
"If Origin not in center it be not in center." --Buggie
User avatar
sektor2111
Godlike
Posts: 6442
Joined: Sun May 09, 2010 6:15 pm
Location: On the roof.

Re: Enslaved for UT

Post by sektor2111 »

That's a simple one, you can develop it if do needs more. PlayerStarts have a sort or auxiliary spawn cross around until min of 16 is reached or less. Else you can make a double cross and trying 32 pieces (for all Pri array).
For 1 PlayerStart LessTele2 will try to bring 4 new ones, else you can bring 8 or more around. I think minimum of 8 Starts should be OK for a decent game with wise resources usage.

For future if such simple things are worked/requested I'm interested in participation if are not time consuming.
User avatar
Gustavo6046
Godlike
Posts: 1462
Joined: Mon Jun 01, 2015 7:08 pm
Personal rank: Resident Wallaby
Location: Porto Alegre, Brazil

Re: Enslaved for UT

Post by Gustavo6046 »

I did a MH conversion and pathing of this map.
It was so fun!

a) I noticed some bots won't get through the first gate, *even though* I specified the LiftTrigger for the doors (matching the switch's tag; only dedicated Enslaved players and nerds, lovers, and really knows this huge place knows!) and the LiftTag matches the door's tag! I wouldn't mind to have a bit of help on this part. Otherwise people would think I'm a blind or bad pather. I do test my stuff! :wth:

b) If the end portal is activated jumping in restarts level. Otherwise the MHEnd makes it end match (while the other trigger would simply hop directly back into the start).

Please note it's still in alpha. Instead of "fixes" I'm gonna release "updates" until the Final version (which can't get redundant fixes).
"Everyone is an idea man. Everybody thinks they have a revolutionary new game concept that no one else has ever thought of. Having cool ideas will rarely get you anywhere in the games industry. You have to be able to implement your ideas or provide some useful skill. Never join a project whose idea man or leader has no obvious development skills. Never join a project that only has a web designer. You have your own ideas. Focus on them carefully and in small chunks and you will be able to develop cool projects."

Weapon of Destruction
Aldebaran
Masterful
Posts: 672
Joined: Thu Jan 28, 2016 7:30 pm

Re: Enslaved for UT

Post by Aldebaran »

Gustavo6046, I played your MH version and found some bugs in it.

[...]
Last edited by Aldebaran on Fri Dec 09, 2016 1:32 am, edited 1 time in total.
Aldebaran
Masterful
Posts: 672
Joined: Thu Jan 28, 2016 7:30 pm

Re: Enslaved for UT

Post by Aldebaran »

Continuation of the previous post...

[...]

I can't play it to end because of the door that does not open.
Last edited by Aldebaran on Fri Dec 09, 2016 1:32 am, edited 1 time in total.
User avatar
OjitroC
Godlike
Posts: 3750
Joined: Sat Sep 12, 2015 8:46 pm

Re: Enslaved for UT

Post by OjitroC »

Aldebaran wrote:1. picture: invisible walls near the button on left/right side in room after spawnpoint
There's also an invisible wall just beyond that point on the main corridor at the entrance door - covers part of the right-hand side of the door when it is open.

Haven't played it much beyond the first set of buildings yet but the pathing looks good - had two bots following me up to the buildings, where they were killed and were able to quickly get back to where I was.
User avatar
EvilGrins
Godlike
Posts: 10231
Joined: Thu Jun 30, 2011 8:12 pm
Personal rank: God of Fudge
Location: Palo Alto, CA

Re: Enslaved for UT

Post by EvilGrins »

Aldebaran wrote:I have to split my post because only 5 pictures can be attached each...
Less of an issue (and avoids double post complains) if you host your pics on another site. Then you can put as many pics in a post as you like...
Aldebaran wrote:I can't play it to end because of the door that does not open.
Does anyone know what's supposed to open the door? If so, that seems the obvious fix... if not, delete the door.
User avatar
Barbie
Godlike
Posts: 2955
Joined: Fri Sep 25, 2015 9:01 pm
Location: moved without proper hashing

Re: Enslaved for UT

Post by Barbie »

EvilGrins wrote:Does anyone know what's supposed to open the door?
I had a look in map "Enslaved.unr" (md5sum 51af710f1d2c386a8df1f51886f656c8) and if I am correct, that door is build of Mover40 and Mover42. They open and stay open on Event 'defil1', but there is no Actor in the map that raises an Event with this name. There is a small chance that there is custom code in the map that triggers this Event, but I guess that trigger setup is broken by design. (Has Maciej (the mapper) ever played his map? ^^)

Also the Sound'Activates.Beeps.mactiv31' and a message "Security system offline. Acces granted." would be triggered with this event.
"If Origin not in center it be not in center." --Buggie
User avatar
EvilGrins
Godlike
Posts: 10231
Joined: Thu Jun 30, 2011 8:12 pm
Personal rank: God of Fudge
Location: Palo Alto, CA

Re: Enslaved for UT

Post by EvilGrins »

Far be it for me to poke a sleeping bear...
Image
...but before you converted this map to MonsterHunt, did you get permission from the guy that made the original SinglePlayer version?
User avatar
Gustavo6046
Godlike
Posts: 1462
Joined: Mon Jun 01, 2015 7:08 pm
Personal rank: Resident Wallaby
Location: Porto Alegre, Brazil

Re: Enslaved for UT

Post by Gustavo6046 »

Sorry for bumping, but I think Enslaved took a similar path to Half-Life, at one point it has an elevator that is similar to the one in Akira:
vOaMpHTm_xk
"Everyone is an idea man. Everybody thinks they have a revolutionary new game concept that no one else has ever thought of. Having cool ideas will rarely get you anywhere in the games industry. You have to be able to implement your ideas or provide some useful skill. Never join a project whose idea man or leader has no obvious development skills. Never join a project that only has a web designer. You have your own ideas. Focus on them carefully and in small chunks and you will be able to develop cool projects."

Weapon of Destruction
User avatar
sektor2111
Godlike
Posts: 6442
Joined: Sun May 09, 2010 6:15 pm
Location: On the roof.

Re: Enslaved for UT

Post by sektor2111 »

Eh, I did a check around so called MH version.
We have... borks, this map will never step into any of my server.
1. I did not see any MonsterEnd - it will never end - don't crap me with Inter-Levels teleporters inactive ON-Line which doesn't heads anywhere in MH - it's just a default broken stuff;
2. TriggerToggle and bTriggerOnceOnly - Good luck here;
3. What ?? 9197 Actors ?? - a Server uses 1024 (0-1023) channels for working with Client Player - what is this load ? Iterators are taking ages here having some chances to crash;
4. Those doors - probably map is not finished, really it doesn't have any visible option for opening them - why was shared in this stage is still a secret for me;
5. I was challenged to find the right InfAdds.u file for matching required used devs (- just for some stupid skins ?);
6. Someday I will learn what's the deal with lights placed in void - maybe I'm still a stupid noob who cannot understand this way of mapping;
7. Also I will attempt to learn news, I'm interested what the heck is the meaning of PathNode256 (speaking about "pathed" string from title) which has no link with anything - just quickly figured after 3 minutes of checks - I'm not curious what's the deal after 30 minutes of checks;
8. Translator as TranslatorEvent doesn't work in MH - it needs some mutator else is pointless;
9. I see 2 factories with SkaarjTroopers both of them closer and having MaxItems > Capacity :loool: both of them with low load - they could be spawned by a single factory - load, load, load - USELESS;
10. Etc ??? Worth the MH porting work ? 145 Monsters vs 137 Movers - this is MoverHunt not MonsterHunt, c'mon guys. Friendly advice: You can leave this UNFINISHED SP map to stay as it is and nothing will explode guaranteed... If you want to play some crapped MH stuff go get some redirect, download files from there, decompress them and... engage to the garbage party ! Else there is crapped stuff already hosted and messed up in the same way, just hit links around in MH maps sections.

I'm gonna be honest here... even if this guy "Maciej " will say that it wants help for a MH portation not only giving editing permissions, me one I'm not interested in any deal - I can make my own MH maps fully operational. The age when I was doing plonks has passed away... this is a load which is not healthy in MH especially if server uses a lot of tweaking and stuff... Seriously... and for sure I'm not doing stuff only for OFF-Line - as my default way of doing.
User avatar
Gustavo6046
Godlike
Posts: 1462
Joined: Mon Jun 01, 2015 7:08 pm
Personal rank: Resident Wallaby
Location: Porto Alegre, Brazil

Re: Enslaved for UT

Post by Gustavo6046 »

It's about time we upgrade to some forum software that has a WYSIWYG post editor.
sektor2111 wrote:Eh, I did a check around so called MH version.
We have... borks, this map will never step into any of my server.
Okay, maybe it's about time to revisit my version too... (inb4 *-fix65535.unr integer overflows to *-fix0.unr)
1. I did not see any MonsterEnd - it will never end - don't crap me with Inter-Levels teleporters inactive ON-Line which doesn't heads anywhere in MH - it's just a default broken stuff;
That is a problem I could fix.
2. TriggerToggle and bTriggerOnceOnly - Good luck here;
Not problem in my end.
3. What ?? 9197 Actors ?? - a Server uses 1024 (0-1023) channels for working with Client Player - what is this load ? Iterators are taking ages here having some chances to crash;
I might clean up some of these later, but for now the size of the level needs that.
4. Those doors - probably map is not finished, really it doesn't have any visible option for opening them - why was shared in this stage is still a secret for me;
oh I forgot about these... :oops:
5. I was challenged to find the right InfAdds.u file for matching required used devs (- just for some stupid skins ?);
Dafuq is that?
6. Someday I will learn what's the deal with lights placed in void - maybe I'm still a stupid noob who cannot understand this way of mapping;
Also Maciej's problem.
7. Also I will attempt to learn news, I'm interested what the heck is the meaning of PathNode256 (speaking about "pathed" string from title) which has no link with anything - just quickly figured after 3 minutes of checks - I'm not curious what's the deal after 30 minutes of checks;
I should fix that.
8. Translator as TranslatorEvent doesn't work in MH - it needs some mutator else is pointless;
9. I see 2 factories with SkaarjTroopers both of them closer and having MaxItems > Capacity :loool: both of them with low load - they could be spawned by a single factory - load, load, load - USELESS;
10. Etc ??? Worth the MH porting work ? 145 Monsters vs 137 Movers - this is MoverHunt not MonsterHunt, c'mon guys.
Blame Maciej!

The map has quality because it's not purely cubic rooms and more rooms, with corridors - it's similar to a Unreal level, just with common errors. You can not expect a map to be perfect and free of errors. For an example, lights in void might be because UnrealEd 2 has this one bug where sometimes Actors can't be deleted, but putting them into the void makes them almost impossible to even interact with, even in the Editor context - giving the illusion they get deleted.

Right now I'm doing some way to fix it up, involving debug Actors (in a separate 'MyLevel package' .unr file) that force all players to spawn in a random one of them (when bActivated is true).

(tell me if I forgot something - I'll then edit this post)
"Everyone is an idea man. Everybody thinks they have a revolutionary new game concept that no one else has ever thought of. Having cool ideas will rarely get you anywhere in the games industry. You have to be able to implement your ideas or provide some useful skill. Never join a project whose idea man or leader has no obvious development skills. Never join a project that only has a web designer. You have your own ideas. Focus on them carefully and in small chunks and you will be able to develop cool projects."

Weapon of Destruction
User avatar
sektor2111
Godlike
Posts: 6442
Joined: Sun May 09, 2010 6:15 pm
Location: On the roof.

Re: Enslaved for UT

Post by sektor2111 »

Gustavo6046 wrote:The map has quality because it's not purely cubic rooms and more rooms, with corridors - it's similar to a Unreal level, just with common errors. You can not expect a map to be perfect and free of errors.
If is beautiful but broken it's useless, else I'm expecting perfect maps because ARE DOABLE. The problem of wrong maps is their size. If they are big are harder to check and we have... huge borks, that's all about let's load more -> quantity != quality.
Gustavo6046 wrote: 5. I was challenged to find the right InfAdds.u file for matching required used devs (- just for some stupid skins ?);
Dafuq is that?
It was one of required files un-shared in map's archive like that "UIPlants" or such which I had to hunt from redirects and used for some fragments as a destruction texture related to some decorations.
Gustavo6046 wrote:For an example, lights in void might be because UnrealEd 2 has this one bug where sometimes Actors can't be deleted, but putting them into the void makes them almost impossible to even interact with, even in the Editor context - giving the illusion they get deleted.
Give me such a map and I'll wipe the floor there how you did not see yet... I'm deleting any sort of actor if map is not corrupted doing an instant crash. I'm able to select and edit actors which cannot be "clicked" and with a single button pressed they go vanished. After making around 10 complete maps so far + a few demo types, I've figured several solutions and what can be done in UED - the only thing disturbing me is checking 2000 actors in such useless load... and Editor is not that wild when it's properly handled.
User avatar
Gustavo6046
Godlike
Posts: 1462
Joined: Mon Jun 01, 2015 7:08 pm
Personal rank: Resident Wallaby
Location: Porto Alegre, Brazil

Re: Enslaved for UT

Post by Gustavo6046 »

I still blame Maciej for most of that - I merely added pathnodes and fixed some of the components... except that damn door. If you expect more from a terrible mapper like me, I hope you never wake up from your dreams.
"Everyone is an idea man. Everybody thinks they have a revolutionary new game concept that no one else has ever thought of. Having cool ideas will rarely get you anywhere in the games industry. You have to be able to implement your ideas or provide some useful skill. Never join a project whose idea man or leader has no obvious development skills. Never join a project that only has a web designer. You have your own ideas. Focus on them carefully and in small chunks and you will be able to develop cool projects."

Weapon of Destruction