Bodyguard mod?

A refuge for those migrating from the fallen DXEditing.com and a place for general discussion relating to Deus Ex editing (coding, mapping, etc).
User avatar
beretta
Thug
Posts: 10
Joined: Mon Aug 08, 2011 9:22 pm
Contact:

Bodyguard mod?

Post by beretta »

While i was playing Deus ex again for hundredth time, I had an idea for a mod. When you press a key (or similar) a npc spawns in front of JC, The npc would then follow you and fight enemies.

Not sure how possible this would be to implement, As my deus ex modding knowledge is limited

Any help is appreciated
chris the cynic
Human Encyclopaedia
Posts: 2207
Joined: Thu Jan 26, 2006 9:50 pm

Re: Bodyguard mod?

Post by chris the cynic »

Spawning an NPC and having them follow you around a map is pretty simple. I used to have it set up so a single keystroke would summon 10 loyal fire breathing greasels who would follow me around and smite my enemies.

(As I recall there was some trouble with them not being proactive enough, they were primarily followers with the smiting usually happening after one of my enemies attacked.)

It would, I think, be more difficult to have your bodyguard follow you across map boundaries. For example, if you wanted to go from getting the dragon's tooth sword to delivering to Max Chen and have you body guard follow you the whole way that means you start in one map, walk through another, and end up in a third. That would require something somewhat more involved than my greasel summoning key.

It is also worth remembering that NPCs can't go everywhere you can go. A notable example being that they can't climb ladders.
User avatar
beretta
Thug
Posts: 10
Joined: Mon Aug 08, 2011 9:22 pm
Contact:

Re: Bodyguard mod?

Post by beretta »

I was looking for a kinda simple follower, even if they cant follow through map boundaries or ladders but your greasels sound similar to what i was wanting, only i was thinking maybe just one human npc (for example, Paul Denton, or a police officer like in paris).
chris the cynic
Human Encyclopaedia
Posts: 2207
Joined: Thu Jan 26, 2006 9:50 pm

Re: Bodyguard mod?

Post by chris the cynic »

This is from memory, so it could be wrong, but I think that what you want is something like this:

set pauldenton alliance player|set pauldenton orders following|summon pauldenton

(Replace "pauldenton" with the name of whoever your preferred npc is)

If that is right then what you do is you open up the file User.ini (in the folder System in your Deus Ex folder) and find the place where there's a list of things of the form [key]=[function] (for example, A=StrafeLeft) and pick a key, say B for bodyguard, and add the above code to it. So it would look like:

B=set pauldenton alliance player| set pauldenton orders following| summon pauldenton

It took me an absurdly long time to figure out that "|" was what you used to separate commands.

I've only tested this enough to see that it does in fact result in Paul being summoned (and he does follow you.) So how well it works for you remains to be seen. Also, you absolutely will need to have cheats enabled for this to work.
User avatar
beretta
Thug
Posts: 10
Joined: Mon Aug 08, 2011 9:22 pm
Contact:

Re: Bodyguard mod?

Post by beretta »

chris the cynic wrote:This is from memory, so it could be wrong, but I think that what you want is something like this:

set pauldenton alliance player|set pauldenton orders following|summon pauldenton

(Replace "pauldenton" with the name of whoever your preferred npc is)

If that is right then what you do is you open up the file User.ini (in the folder System in your Deus Ex folder) and find the place where there's a list of things of the form [key]=[function] (for example, A=StrafeLeft) and pick a key, say B for bodyguard, and add the above code to it. So it would look like:

B=set pauldenton alliance player| set pauldenton orders following| summon pauldenton

It took me an absurdly long time to figure out that "|" was what you used to separate commands.

I've only tested this enough to see that it does in fact result in Paul being summoned (and he does follow you.) So how well it works for you remains to be seen. Also, you absolutely will need to have cheats enabled for this to work.
Thanks, You've been a great help :smile:
Last edited by beretta on Tue Aug 09, 2011 12:59 pm, edited 2 times in total.
~DJ~
UNATCO
Posts: 277
Joined: Thu Sep 13, 2007 4:15 pm

Re: Bodyguard mod?

Post by ~DJ~ »

That's a clever bind.. but I was wondering if this really works.. I think you should first SUMMON PaulDenton (or others) then apply stuff through set commands, then delete it and spawn it back again.. something like this:

Code: Select all

B=summon pauldenton|set pauldenton alliance player|set pauldenton orders following|killall pauldenton|summon pauldenton
I'd try Male2 though; just incase.. if you've got Paul around the same map and he gets killed.. so try something which isn't important in SP storyline. :oops:
User avatar
beretta
Thug
Posts: 10
Joined: Mon Aug 08, 2011 9:22 pm
Contact:

Re: Bodyguard mod?

Post by beretta »

~DJ~ wrote:That's a clever bind.. but I was wondering if this really works.. I think you should first SUMMON PaulDenton (or others) then apply stuff through set commands, then delete it and spawn it back again.. something like this:

Code: Select all

B=summon pauldenton|set pauldenton alliance player|set pauldenton orders following|killall pauldenton|summon pauldenton
I'd try Male2 though; just incase.. if you've got Paul around the same map and he gets killed.. so try something which isn't important in SP storyline. :oops:
Thanks DJ :)

Is there a command to give the summoned npc a weapon?
nerdenstein
Illuminati
Posts: 1591
Joined: Thu Apr 24, 2008 7:40 pm
Location: Leicester, England, UK.

Re: Bodyguard mod?

Post by nerdenstein »

Paul should come with a weapon already. Some NPC's won't.
To actually give them a weapon however, I have no idea.
The real trouble with reality is that there's no background music.
chris the cynic
Human Encyclopaedia
Posts: 2207
Joined: Thu Jan 26, 2006 9:50 pm

Re: Bodyguard mod?

Post by chris the cynic »

~DJ~ wrote:That's a clever bind.. but I was wondering if this really works.. I think you should first SUMMON PaulDenton (or others) then apply stuff through set commands, then delete it and spawn it back again.. something like this:

Code: Select all

B=summon pauldenton|set pauldenton alliance player|set pauldenton orders following|killall pauldenton|summon pauldenton
It is my recollection that that doesn't really work. My old greasel command would summon a greasel, set alliance and orders, change weapon greaselspit to have a projectile class of fire, then spawnmass ten greasels.

The idea was that the summoned greasel summoned first would allow the changes to be made even if the map had no greasels. Except I don't remember it working that way. I don't think the first summoned greasel made things any different (other than there being 11 greasels) which meant that in maps without greasels I just had to hit the minion key twice.

If I recall correctly, it was a long time ago.
DDL
Traditional Evil Scientist
Traditional Evil Scientist
Posts: 3791
Joined: Mon Oct 17, 2005 10:03 am

Re: Bodyguard mod?

Post by DDL »

Yeah, it seems like set commands like that affect defprops of actors yet to spawn, rather than current properties of actors already spawned.
~DJ~
UNATCO
Posts: 277
Joined: Thu Sep 13, 2007 4:15 pm

Re: Bodyguard mod?

Post by ~DJ~ »

chris the cynic wrote:
~DJ~ wrote:That's a clever bind.. but I was wondering if this really works.. I think you should first SUMMON PaulDenton (or others) then apply stuff through set commands, then delete it and spawn it back again.. something like this:

Code: Select all

B=summon pauldenton|set pauldenton alliance player|set pauldenton orders following|killall pauldenton|summon pauldenton
It is my recollection that that doesn't really work. My old greasel command would summon a greasel, set alliance and orders, change weapon greaselspit to have a projectile class of fire, then spawnmass ten greasels.
Ah.. that's more clever.. don't even have to do the killall command at all. :oops:

So..

Code: Select all

B=summon pauldenton|set pauldenton alliance player|set pauldenton orders following|summon pauldenton
This would summon two Paul(s) though, but one would be useless and would just wander around.
User avatar
beretta
Thug
Posts: 10
Joined: Mon Aug 08, 2011 9:22 pm
Contact:

Re: Bodyguard mod?

Post by beretta »

I've created a new pawn of the cop in the editor, Can i summon him ingame?. I created the .u files but it loads the map i placed him in. Is there a way for me to use him just as a summonable pawn and not as a whole new map?


Got it figured out :), Had to uncompile deusex.u and import my .uc then recompile, Type summon MyFriendlyCop in console, Then my pawn spawns. Took some figuring out but i'm fairly happy with my first modding attempt :D
~DJ~
UNATCO
Posts: 277
Joined: Thu Sep 13, 2007 4:15 pm

Re: Bodyguard mod?

Post by ~DJ~ »

Oh my god.. don't recompile DeusEx.u haha.

You could just summon it normally.. Like say if you made your package called 'BODYGUARD', you'd just have to do this..

Code: Select all

summon BodyGuard.MyFriendlyCop
User avatar
beretta
Thug
Posts: 10
Joined: Mon Aug 08, 2011 9:22 pm
Contact:

Re: Bodyguard mod?

Post by beretta »

~DJ~ wrote:Oh my god.. don't recompile DeusEx.u haha.

You could just summon it normally.. Like say if you made your package called 'BODYGUARD', you'd just have to do this..

Code: Select all

summon BodyGuard.MyFriendlyCop
Thanks DJ, that helped me a lot, Now i can use my own .u. I didn't realize how easy it is to use the SDK untill after i completed some tutorials.
ggrotz
X-51
Posts: 780
Joined: Tue Nov 10, 2009 12:55 am

Re: Bodyguard mod?

Post by ggrotz »

I've been playing with trying to get a macro going like described in this thread, but I can't summon anything via keystroke in USER.INI. Any thoughts?
Post Reply