Nali Weapons 3 - Release

Need some nice Mods? Here, you are right!
JackGriffin
Godlike
Posts: 3774
Joined: Fri Jan 14, 2011 1:53 pm
Personal rank: -Retired-

Re: Nali Weapons 3 - Release

Post by JackGriffin »

I bet I know what's causing this. We hit this while working on the UTP stuff. Go into your IP2C setup ini and blank out the sites except for any one that you know is working and currently on that does the lookups. I can't tell you which one to use because I haven't kept up with it. I do know there was some issues with databases being down (SLV one I think?).

If this clears the crash then it's the timeout caused by the down databases that is creating the sigsev. A workaround is to add a timer to the IP2C database check that will return a blank value if it exceeds a certain time.

UEngine works with remote database checks but with one caveat: it HAS to have some sort of return, even if it's <none>. Not getting a return (not <none> but no return) causes the engine to loop into a crash waiting for a return that doesn't come. We had to add a timer to the remote DB check then insert a null return if it timed out, otherwise the server would crash oddly.

It's strange that it's caused by running NW3 but it may be that NW3 is pushing the server/client architecture to near it's limits. Hitty, does the IP2C stuff I built into the MH gold mod still crash the same way? I'll bet you it doesn't.
So long, and thanks for all the fish
User avatar
Feralidragon
Godlike
Posts: 5498
Joined: Wed Feb 27, 2008 6:24 pm
Personal rank: Work In Progress
Location: Liandri

Re: Nali Weapons 3 - Release

Post by Feralidragon »

I want to note though that the only thing NW3 pushes more relative other mods is RAM, as in loading at least 160Mb to memory to run the mod.
From there it's fully optimized to run as smooth as possible with the lowest possible bandwidth despite the amount of features and stuff it has.
Also every single actor is de-referenced once they are destroyed so they can be effectively garbage collected later, so no memory leaks happen during gameplay.

In the client on the other hand, it depends solely on the detail settings (since most of the mod load is in the client and not the server). That's why I find any server hardware related problems very very weird, and as far as the client, I am going to add benchmarking code to evaluate the performance and load up the proper detail profile (since the lowest profile "Please Have Mercy" seems to not be low enough for some players, so I must make this profile the lowest it can possibly be, which isn't currently).
User avatar
Hitman
Adept
Posts: 293
Joined: Mon Aug 16, 2010 11:01 am
Location: Sweden

Re: Nali Weapons 3 - Release

Post by Hitman »

Just to check I tested with MonsterHunt2Gold and it crash the same way if I use MonsterHunt2Gold.LinkActor.....And works if I disable it, So I dont think its my mod as I said.
The reason Sp0ngeb0b got it to work could be that it seams he use Linux that handle memory-usage in a diff way.
Last edited by Hitman on Wed Nov 14, 2012 3:25 am, edited 1 time in total.
User avatar
EvilGrins
Godlike
Posts: 9903
Joined: Thu Jun 30, 2011 8:12 pm
Personal rank: God of Fudge
Location: Palo Alto, CA

Re: Nali Weapons 3 - Release

Post by EvilGrins »

NW3 has led to me taking an obscene number of screenshots lately, which I've been spreading out among numerous forums.

Just when I thought I was about done with screenshots, you pulled me back in!
http://unreal-games.livejournal.com/
Image
medor wrote:Replace Skaarj with EvilGrins :mrgreen:
Smilies · viewtopic.php?f=8&t=13758
User avatar
Dr.Flay
Godlike
Posts: 3348
Joined: Thu Aug 04, 2011 9:26 pm
Personal rank: Chaos Evangelist
Location: Kernow, UK

Re: Nali Weapons 3 - Release

Post by Dr.Flay »

I don't know who to slap harder, you or Ferali
User avatar
EvilGrins
Godlike
Posts: 9903
Joined: Thu Jun 30, 2011 8:12 pm
Personal rank: God of Fudge
Location: Palo Alto, CA

Re: Nali Weapons 3 - Release

Post by EvilGrins »

Say, 2 quick things:
1) Is there some kind of destructible items thing with NW3? Sometimes I get a bigger boom if my target's carrying a lot of weapons.
2) When the cybots kill anything, the message I get is that person wqas killed by me but not by my cybot. Specifically, cybot does the kill and I'm currently using the flamethrower, I get a message saying I killed that guy with the flamethrower.
Dr.Flay wrote:I don't know who to slap harder, you or Ferali
Image
http://unreal-games.livejournal.com/
Image
medor wrote:Replace Skaarj with EvilGrins :mrgreen:
Smilies · viewtopic.php?f=8&t=13758
User avatar
Feralidragon
Godlike
Posts: 5498
Joined: Wed Feb 27, 2008 6:24 pm
Personal rank: Work In Progress
Location: Liandri

Re: Nali Weapons 3 - Release

Post by Feralidragon »

1. No. What you are experiencing are likely to be coincidences, the booms are always the same either your target carries 1 item or 100, it doesn't really matter.
2. It's a bug/limitation of UT itself, since UT gives the death messages solely based on the weapon you're currently using, and not actually who or what originally killed a player.
Epic realized this so they added the Redeemer as an exception to that rule since generally you only get 1 ammo to the Redeemer so it would be noticeable (retarded design..., they knew about it, never fixed it...).
I have been digging in the code however I think I can circumvent their messages system with my own. It's rather tricky, and depends either or not some mods like Nexgen replace some things themselves (which I think they don't).
The only 100% guaranteed to work way would be create new gametypes (since this sort of thing is hardcoded in them).

Epic did a lot of dumb things in UT, this is one of the most noticeable. Can't blame them though, they had a tight schedule to release UT back then.

EDIT: Just rechecked a few forums from where you posted to see if anyone posted some more bugs and such so I can get to work on the new (and final) release in this next weekend, and I giggled on this one:
http://unrealoldfriends.activeboard.com ... 3-release/
They think the mod is for UT2k4 :lol2:
You probably should enlighten them up and tell them it's for UT1 before they actually try to install it in UT2k4.
User avatar
The_Cowboy
Skilled
Posts: 165
Joined: Mon Jan 24, 2011 3:22 am
Personal rank: Codezilla

Re: Nali Weapons 3 - Release

Post by The_Cowboy »

Feralidragon wrote: 2. It's a bug/limitation of UT itself, since UT gives the death messages solely based on the weapon you're currently using, and not actually who or what originally killed a player.
I think UT gives death messages not on basis of current weapon but on the basis of damagetype of the weapon. Here is the code from Gameinfo.

Code: Select all

// Level death message functions.

function Killed( pawn Killer, pawn Other, name damageType )
{
	local String Message, KillerWeapon, OtherWeapon;
	local bool bSpecialDamage;

	if (Other.bIsPlayer)
	{
		if ( (Killer != None) && (!Killer.bIsPlayer) )
		{
			Message = Killer.KillMessage(damageType, Other);
			BroadcastMessage( Message, false, 'DeathMessage');
			if ( LocalLog != None )
				LocalLog.LogSuicide(Other, DamageType, None);
			if ( WorldLog != None )
				WorldLog.LogSuicide(Other, DamageType, None);
			return;
		}
		if ( (DamageType == 'SpecialDamage') && (SpecialDamageString != "") )
		{
			BroadcastMessage( ParseKillMessage(
					Killer.PlayerReplicationInfo.PlayerName,
					Other.PlayerReplicationInfo.PlayerName,
					Killer.Weapon.ItemName,
					SpecialDamageString
					),
				false, 'DeathMessage');
			bSpecialDamage = True;
		}
		Other.PlayerReplicationInfo.Deaths += 1;
		if ( (Killer == Other) || (Killer == None) )
		{
			// Suicide
			if (damageType == '')
			{
				if ( LocalLog != None )
					LocalLog.LogSuicide(Other, 'Unknown', Killer);
				if ( WorldLog != None )
					WorldLog.LogSuicide(Other, 'Unknown', Killer);
			} else {
				if ( LocalLog != None )
					LocalLog.LogSuicide(Other, damageType, Killer);
				if ( WorldLog != None )
					WorldLog.LogSuicide(Other, damageType, Killer);
			}
			if (!bSpecialDamage)
			{
				if ( damageType == 'Fell' )
					BroadcastLocalizedMessage(DeathMessageClass, 2, Other.PlayerReplicationInfo, None);
				else if ( damageType == 'Eradicated' )
					BroadcastLocalizedMessage(DeathMessageClass, 3, Other.PlayerReplicationInfo, None);
				else if ( damageType == 'Drowned' )
					BroadcastLocalizedMessage(DeathMessageClass, 4, Other.PlayerReplicationInfo, None);
				else if ( damageType == 'Burned' )
					BroadcastLocalizedMessage(DeathMessageClass, 5, Other.PlayerReplicationInfo, None);
				else if ( damageType == 'Corroded' )
					BroadcastLocalizedMessage(DeathMessageClass, 6, Other.PlayerReplicationInfo, None);
				else if ( damageType == 'Mortared' )
					BroadcastLocalizedMessage(DeathMessageClass, 7, Other.PlayerReplicationInfo, None);
				else
					BroadcastLocalizedMessage(DeathMessageClass, 1, Other.PlayerReplicationInfo, None);
			}
		} 
		else 
		{
			if ( Killer.bIsPlayer )
			{
				KillerWeapon = "None";
				if (Killer.Weapon != None)
					KillerWeapon = Killer.Weapon.ItemName;
				OtherWeapon = "None";
				if (Other.Weapon != None)
					OtherWeapon = Other.Weapon.ItemName;
				if ( Killer.PlayerReplicationInfo.Team == Other.PlayerReplicationInfo.Team )
				{
					if ( LocalLog != None )
						LocalLog.LogTeamKill(
							Killer.PlayerReplicationInfo.PlayerID,
							Other.PlayerReplicationInfo.PlayerID,
							KillerWeapon,
							OtherWeapon,
							damageType
						);
					if ( WorldLog != None )
						WorldLog.LogTeamKill(
							Killer.PlayerReplicationInfo.PlayerID,
							Other.PlayerReplicationInfo.PlayerID,
							KillerWeapon,
							OtherWeapon,
							damageType
						);
				} else {
					if ( LocalLog != None )
						LocalLog.LogKill(
							Killer.PlayerReplicationInfo.PlayerID,
							Other.PlayerReplicationInfo.PlayerID,
							KillerWeapon,
							OtherWeapon,
							damageType
						);
					if ( WorldLog != None )
						WorldLog.LogKill(
							Killer.PlayerReplicationInfo.PlayerID,
							Other.PlayerReplicationInfo.PlayerID,
							KillerWeapon,
							OtherWeapon,
							damageType
						);
				}
				if (!bSpecialDamage && (Other != None))
				{
					BroadcastRegularDeathMessage(Killer, Other, damageType);
				}
			}
		}
	}
	ScoreKill(Killer, Other);
}
Feralidragon wrote:Trial and error is sometimes better than any tutorial, because we learn how it works for ourselfs, which kills any doubts about anything :tu:
Patreon: https://www.patreon.com/FreeandOpen
User avatar
Feralidragon
Godlike
Posts: 5498
Joined: Wed Feb 27, 2008 6:24 pm
Personal rank: Work In Progress
Location: Liandri

Re: Nali Weapons 3 - Release

Post by Feralidragon »

UT *does* give the death messages based on your weapon. You shouldn't look at GameInfo alone, since GameInfo is not used for UT, as is just a generic class that is constantly overridden by other gameinfo subclasses, such as TournamentGameInfo and DeathMatchPlus.
I was referring to this:

Code: Select all

function BroadcastRegularDeathMessage(pawn Killer, pawn Other, name damageType)
{
    if (damageType == 'RedeemerDeath')
    {
        if ( RedeemerClass == None )
            RedeemerClass = class<Weapon>(DynamicLoadObject("Botpack.Warheadlauncher", class'Class'));
        BroadcastLocalizedMessage(DeathMessageClass, 0, Killer.PlayerReplicationInfo, Other.PlayerReplicationInfo, RedeemerClass);
    }
    else if (damageType == 'Eradicated')
        BroadcastLocalizedMessage(class'EradicatedDeathMessage', 0, Killer.PlayerReplicationInfo, Other.PlayerReplicationInfo, None);
    else if ((damageType == 'RocketDeath') || (damageType == 'GrenadeDeath'))
        BroadcastLocalizedMessage(DeathMessageClass, 0, Killer.PlayerReplicationInfo, Other.PlayerReplicationInfo, class'UT_Eightball');
    else if (damageType == 'Gibbed')
        BroadcastLocalizedMessage(DeathMessageClass, 8, Killer.PlayerReplicationInfo, Other.PlayerReplicationInfo, None);
    else {
        if (Killer.Weapon != None)
            BroadcastLocalizedMessage(DeathMessageClass, 0, Killer.PlayerReplicationInfo, Other.PlayerReplicationInfo, Killer.Weapon.Class);
        else
            BroadcastLocalizedMessage(DeathMessageClass, 0, Killer.PlayerReplicationInfo, Other.PlayerReplicationInfo, None);
    }
}
Which is actually what the function GameInfo calls from there if the damage is not a "SpecialDamage" and if it's not a suicide.
And as you can see, Epic pretty much hardcoded what they consider "SpecialDamage", so there's no way around it besides changing the DeathMessageClass itself and do some background magic before the kill message is actually broadcasted (such as saving the actual damage and let DeathMessageClass read it and give another message instead, since no arguments relative the damage type are passed in BroadcastLocalizedMessage).
User avatar
Sp0ngeb0b
Adept
Posts: 376
Joined: Wed Feb 13, 2008 9:16 pm
Location: Cologne

Re: Nali Weapons 3 - Release

Post by Sp0ngeb0b »

Oh yeah, that's the UT souce code I know :ironic:
Website, Forum & UTStats

Image
******************************************************************************
Nexgen Server Controller || My plugins & mods on GitHub
******************************************************************************
User avatar
The_Cowboy
Skilled
Posts: 165
Joined: Mon Jan 24, 2011 3:22 am
Personal rank: Codezilla

Re: Nali Weapons 3 - Release

Post by The_Cowboy »

Exactly! I stand corrected. But the deathmessage corresponding to current weapon is shown only if damagetype is *not recognised* (i.e not related to default weapons). Assuming that you must have given some creative names :D to damagetype of NW3, the last "else" statement is in action. Hmm, so that was what you were complaining about.
I think you must see EnhancedItems written by Wormbo. He has dealt with these kind (and other kinds) of bugs smartly (I have yet to see better code. 8) )
I will be little suprised to know that you have not inherited classes of Enhanced items in NW3.
Last edited by The_Cowboy on Thu Nov 15, 2012 12:55 pm, edited 1 time in total.
Feralidragon wrote:Trial and error is sometimes better than any tutorial, because we learn how it works for ourselfs, which kills any doubts about anything :tu:
Patreon: https://www.patreon.com/FreeandOpen
User avatar
Feralidragon
Godlike
Posts: 5498
Joined: Wed Feb 27, 2008 6:24 pm
Personal rank: Work In Progress
Location: Liandri

Re: Nali Weapons 3 - Release

Post by Feralidragon »

Yes, the last "else" statement is indeed in use since I created new damagetype names, which is the correct thing to do and the only reliable way to identify from where the damage came from.
The thing is, you only have a couple of solutions for this:
- There's the solution I posted above (the background "magic" would include having a PreventDeath check in a mutator);
- Creating new gameinfo subclasses instead and override the function directly;
- Defining everything as SpecialDamage and constantly change SpecialDamageString to fit the needs, but then there's no way to reliably know the kind of damage without also doing more background "magic";
- Nullify the DeathMessageClass completely, and do the broadcasting yourself.

Epic simply hardcoded things, they didn't even give the slightest way to define new damage types at all, like new managers with the damage type argument.

And no, I didn't inherit anything from anywhere, I built the entire mod code myself ground up, so I didn't even look at other mods or how they did things (I never felt the need to tbh).
But if there's a better way to do it, I'm all hears. :)
User avatar
The_Cowboy
Skilled
Posts: 165
Joined: Mon Jan 24, 2011 3:22 am
Personal rank: Codezilla

Re: Nali Weapons 3 - Release

Post by The_Cowboy »

Feralidragon wrote: - There's the solution I posted above (the background "magic" would include having a PreventDeath check in a mutator);
- Nullify the DeathMessageClass completely, and do the broadcasting yourself.
I did apply these very solutions in some of my mutators but i never released them for obvious reasons(incompatibility).
Feralidragon wrote: And no, I didn't inherit anything from anywhere, I built the entire mod code myself ground up, so I didn't even look at other mods or how they did things (I never felt the need to tbh).
:rock:
Feralidragon wrote: But if there's a better way to do it, I'm all hears. :)
Apparently there is another way (not sure if you have mentioned it). For that you will have to check this out http://wiki.beyondunreal.com/Legacy:Enh ... ageMutator
Feralidragon wrote:Trial and error is sometimes better than any tutorial, because we learn how it works for ourselfs, which kills any doubts about anything :tu:
Patreon: https://www.patreon.com/FreeandOpen
User avatar
Feralidragon
Godlike
Posts: 5498
Joined: Wed Feb 27, 2008 6:24 pm
Personal rank: Work In Progress
Location: Liandri

Re: Nali Weapons 3 - Release

Post by Feralidragon »

Just checked, actually the only thing I think to be better in his approach is the fact that he uses a message mutator instead to change the deathmessageclass every single time a deathmessage is broadcasted instead of changing the class from the gameinfo directly instead.
The rest is actually the kind of background "magic" I talked about, however it seems that in his case his approach is way more incompatible than what I was thinking to do: it does not avoid other mods to write different messages anyway (either you use a mutator or change directly it ends up being the same), and it only works "better" in a sense because he defined his own profiles, ammo and whatnot for the new items, so in a way it only works for his own items and nothing else.

What I was thinking does not avoid the first problem either (it's pretty much impossible since you cannot predict what another messageclass will do in other mods), but I can make it compatible with every single weapon available as long as you configure its ini to be recognized, and not just my own stuff like in his case.
Plus his way consists in actual actors and a list of 5 items, which limits severally the whole thing in an actual full server match and is bound to not work when the server gets some action going. Again, damagetype is the most reliable way to evaluate what message to display currently in UT in a generic way to work with most weapons around.
In resume, although Wormbo's work is awesome and all, his way in this particular case is way more dirty and incompatible with other stuff as it can be imo.

I will stick with mine, although probably the only thing I will change in my approach is adding a message mutator instead of change the class directly, but even that is a "maybe".

Thanks for the link though :)
User avatar
EvilGrins
Godlike
Posts: 9903
Joined: Thu Jun 30, 2011 8:12 pm
Personal rank: God of Fudge
Location: Palo Alto, CA

Re: Nali Weapons 3 - Release

Post by EvilGrins »

Feralidragon wrote:EDIT: Just rechecked a few forums from where you posted to see if anyone posted some more bugs and such so I can get to work on the new (and final) release in this next weekend, and I giggled on this one:
http://unrealoldfriends.activeboard.com ... 3-release/
They think the mod is for UT2k4 :lol2:
Just did. That's too funny, even with the original link in the post!

So far, not so much a bug, the only negative I've seen is on Hermskii's forum. There's one guy in the screenshots thread that's got a real problem with NW3 and special weapons packages in general.
http://unreal-games.livejournal.com/
Image
medor wrote:Replace Skaarj with EvilGrins :mrgreen:
Smilies · viewtopic.php?f=8&t=13758