Page 1 of 2

Bodyguard mod?

Posted: Mon Aug 08, 2011 9:26 pm
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

Re: Bodyguard mod?

Posted: Mon Aug 08, 2011 9:49 pm
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.

Re: Bodyguard mod?

Posted: Mon Aug 08, 2011 9:58 pm
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).

Re: Bodyguard mod?

Posted: Tue Aug 09, 2011 1:21 am
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.

Re: Bodyguard mod?

Posted: Tue Aug 09, 2011 1:26 am
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:

Re: Bodyguard mod?

Posted: Tue Aug 09, 2011 2:31 am
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:

Re: Bodyguard mod?

Posted: Tue Aug 09, 2011 1:00 pm
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?

Re: Bodyguard mod?

Posted: Tue Aug 09, 2011 2:23 pm
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.

Re: Bodyguard mod?

Posted: Tue Aug 09, 2011 2:29 pm
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.

Re: Bodyguard mod?

Posted: Tue Aug 09, 2011 4:18 pm
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.

Re: Bodyguard mod?

Posted: Tue Aug 09, 2011 5:20 pm
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.

Re: Bodyguard mod?

Posted: Thu Aug 11, 2011 10:15 pm
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

Re: Bodyguard mod?

Posted: Thu Aug 11, 2011 11:55 pm
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

Re: Bodyguard mod?

Posted: Fri Aug 12, 2011 12:00 am
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.

Re: Bodyguard mod?

Posted: Sat May 11, 2019 9:31 pm
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?