From bc2dabc461cbd51b936de75a322ef2923fd5981e Mon Sep 17 00:00:00 2001 From: NovaRain Date: Wed, 11 Jul 2018 10:03:03 +0800 Subject: [PATCH] Removed redundant function from NPC combat control and tidied up a bit. --- artifacts/config_files/sfall-mods.ini | 2 +- artifacts/mods/gl_partycontrol.int | Bin 2140 -> 2142 bytes artifacts/mods/gl_partycontrol.ssl | 10 ++++++---- 3 files changed, 7 insertions(+), 5 deletions(-) diff --git a/artifacts/config_files/sfall-mods.ini b/artifacts/config_files/sfall-mods.ini index 15bd5934..c478a1bf 100644 --- a/artifacts/config_files/sfall-mods.ini +++ b/artifacts/config_files/sfall-mods.ini @@ -39,7 +39,7 @@ MotionScanner=0 Mode=0 ;PIDList=62,89,97,107,160,161 -;Displays the name of controlled critter in an extra interface box. Must be between 5 and 9 +;Displays the name of the controlled critter in a notification box above the interface bar. Must be between 5 and 9 ;Set to 0 to disable DisplayName=0 diff --git a/artifacts/mods/gl_partycontrol.int b/artifacts/mods/gl_partycontrol.int index ade765f113183c2f57cc3f84fd8bac40e128b209..c3289d172203626988ae7a8d004865a67e569979 100644 GIT binary patch delta 256 zcmca3a8F>uPR6c{yXqKui&7JF;!{dfQseWJvL>4{X-v*#N@48Ue2K}NiP2*+7wa68 z1B?s|Y)l}Mfw9480wV(h!;z-42IB_T27NH^3QVr4yg>@YW@DQChgDb50mNotY7l~| zdouYPt1f>^0}DhKm^?Dsf=zjHDVr3xTVqOtG)M>An#r@+j2S;oKF6lds5JQ>n?7UE zWIc9$#)ipp?5dK-Kx#myf@#(UbBHeXZIkD)>q@$TMHw1|ptMDUK8VG^F!>R?F{8y~ HF%CBX3NA#) delta 248 zcmca7a7SRmPR5RnyXqJxdoZc;@fD>e=ESFzrliK_CuL2}W=do1*nEk}oQY9qG8gL{ zjR}kl3=BsOfJnv$qo(o(DG;0W8;E3JY7lDB2dlU;S%OWMQDyQiR$YFN1{Sc`5it2` zatNEUa8ASihAUt_3=p#6;p74~MQ)eIlm=;#2-~X3bJ&a-KTN*Brq8G_iCv#DV6p+b zK4abF1a?(Phy$1!gg{CeSR2eCn%K8Yp2w~$=>isIfXXs7STyK^MA-jLe!_0dXf|1b G!wmouk3-)8 diff --git a/artifacts/mods/gl_partycontrol.ssl b/artifacts/mods/gl_partycontrol.ssl index 12d5875d..a5d93531 100644 --- a/artifacts/mods/gl_partycontrol.ssl +++ b/artifacts/mods/gl_partycontrol.ssl @@ -36,18 +36,20 @@ procedure combatturn_handler begin if (status == 1 and (len_array(pidList) == 0 or scan_array(pidList, pid bwand 0xFFFFFF) != -1) and (controlMode == 1 or party_member_obj(pid))) then begin - set_dude_obj(critter); + if not(critter == real_dude_obj) then begin + set_dude_obj(critter); + if hasGeckoSkinning then critter_add_trait(critter, TRAIT_PERK, PERK_gecko_skinning_perk, 1); + end if displayName then begin set_iface_tag_text(displayName, obj_name(critter), displayNameColor); show_iface_tag(displayName); end - if hasGeckoSkinning then critter_add_trait(critter, TRAIT_PERK, PERK_gecko_skinning_perk, 1); end else begin set_dude_obj(real_dude_obj); hide_iface_tag(displayName); end - move_to(dude_obj, dude_tile, dude_elevation); // for removing roof tiles - tile_set_center(dude_tile); + // center the screen on the controlled critter and remove roof tiles + move_to(dude_obj, dude_tile, dude_elevation); end procedure start begin