Indie game storeFree gamesFun gamesHorror games
Game developmentAssetsComics
SalesBundles
Jobs
Tags

Strive for Power

Fantasy Slave Management/RPG Erotic Game · By Strive4Power

Bandit Tooltip Mod

A topic by alexsis987 created Nov 12, 2019 Views: 3,943 Replies: 11
Viewing posts 1 to 4
(6 edits)

So haven't played this game in quite a while but was incredibly disappointed when I came back and couldn't see bandit's information anymore. I mean i'm going weapon to weapon with these thugs and I can't even tell what race, gender or age they are?! Makes no sense to me so I just put together a tooltip of the pertinent information  whenever you hover over a bandit. 


Bandit Tooltip

Made a mod version of this for those using no mods or those which only minimally modify combat.gd. If your mod doesn't much change the func _ready(); or func start_battle(nosound =false) functions it should be compatible. If you are, you will need to slightly adjust the line numbers to compensate. 

https://mega.nz/#!hl9GjABa!tpT3Kl23toKjNf3UnEzI6pqaqNDIi49Pm4DIE97-3C8


This version will work for Aric's Expansion v.08

https://mega.nz/#!kk9knSAA!6IQc_fA_5pIqiub_-0AFCTweh-1WtupT0Z9fNLY0nQg


Can replace your existing combat.gd file in files\scripts\ with this if you use v.07 of Aric's Expansion. Otherwise follow instructions

https://mega.nz/#!IgkE2aZT!unaJ0YvU7P4-rRF4Yl74vaAB229zE7veGGaIL_YqTug


Just follow the directions  for copy pasting the information yourself and it should work with vanilla or any other mod that edits the combat.gd. Before anyone complains about doing it themselves, its only 10 lines in 3 different locations and 2 of those are the same line. For this you can use any code editor which will open a .gd file but highly recommend Notepad++. Its amazing and super useful at opening almost anything if you don't have it already.

Note: All line numbers use Aric's Expansion v.07. Of course he would launch v.08 while I was fiddling with this. Will probably update my line numbers for the new version tomorrow but otherwise Ctrl F is your friend.

Instructions

1) Navigate to your files\scripts\ and open combat.gd


2)  Add the following line 

            newbutton.connect('mouse_entered', newcombatant, 'enemytooltip')

right after

           newbutton.connect('mouse_entered', newcombatant, 'combatanttooltip')

on lines  90, and 174 (accounts for the new line you're adding).

NOTE: You can follow my line numbers for this one if you use v.07 of Aric's Expansion or just ctrl + F for combatanttooltip. There will be 4 examples of this before you reach func combatanttooltip(). You'll add the line right after the  2nd and 4th ones being sure not to count the ones with hide at the front. It won't actually hurt anything if you do all 4, but you'll end up getting a tooltip on yourself and your slaves while in combat if you do the others.


3) Next we need to remove the existing func enemytooltip(enemy): its an outdated function which has been replaced (and had this feature in it) but is no longer supported. You'll be deleting lines 730 to 741. For those of you not using the mod just ctrl F the above func to find it. Next you're going to copy and paste 

func enemytooltip():
var text = ''
if self.person != null:
self.node.get_parent().move_child(node, node.get_parent().get_children().size())
text += name + '\n'
text += self.person.race + ' ' + self.person.age + ' ' + self.person.sex + '.\n'
text += "\nGrade: " + self.person.origins
self.node.hint_tooltip = text

right after func hidecombatanttooltip(): on line 550 while being sure to format appropriately, sorry forum formating which doesn't support code inserts is lame. See picture. And now you're done! Enjoy knowing who you're beating up!


You could create a mod that will do all this things for not aric expansion users :)

not sure how is mod system working with aric expansion and never wanted to try

i ll give it a try, thanks for new mod.

(1 edit)

Some mods seem to be fully compatible. Chastity Belt was (he made a patch for it), Random Portraits, and Standard Harem Protagonist (from what people have told me, I haven’t tested that one personally) seems to be fully compatible. I’ll probably list the tested and compatible mods on the main page to clarify, I think it’s all scattered in the threads atm.

Edit:

Love the additions in this mod, mate. It’s something I’ve been slightly annoyed about too. Maybe I don’t want to waste resources to prevent a crappy Slave from escaping battle, right? I love what the mod community is doing for this game these days! If there’s anything I can do to help, just let me know.

additional notes for this:

While I did say d harem protag was compatible, note I did remove the spell file from the mod because I didnt want it, nor checked it. I only wanted the stats increase, until I found what file to edit myself to do this. So. it didnt get a whole lot of testing on my end. I recommend checking the files and/or testing yourself.

Good to know. It has always felt way too overpowered even for me so it’s not been my cup of tea, but I figured I’d mention it since I remembered it being brought up. Thanks for the clarification!

(1 edit)

Any idea why <AddTo -1> just throws a bunch of errors? I'm attempting to add a new function to the class combatant: in combat.gd and I don't particularly care where it is as long as its in there so adding it at the end would be great as it would be compatible with any mod (even with your changes). The modding help does say that this is perfectly valid but I could only get it to work by specifying a particular line which makes it vulnerable to other mods

Edit: Oh, apparently it was already brought up in the modding thread like a year+ ago and has just never been fixed.... That's super lame

The problem is that array[-1] successfully gets the last item, but array.insert("something", -1) gives an index out of bounds error.  For a language derived from Python it's quite unexpected for negative indexes to fail.  Thanks for finding it.  If you have any other troubles while modding be sure to say something, as I am currently fixing it and writing a more detailed modding guide.

Awesome! Sorry I haven't been involved with this game in quite a few years. How would I go about getting your fix?

(1 edit)

well if that helps <Remove from> is index 1 and <Addto> is index 0 so you need to <AddTo 0> to be in line 1 right after function

also mod system cant read 1st line in file, even if ank fixes will solve problems for you, most users might not have them instaled

(1 edit)

The reason why mods are so incompatible if they edit the same file is because the system the game uses basically requires you to tell it what file to look at, and then give it a specific line number to add/remove code for. So if the line numbers are changed because one mod completely overwrites the file then it will change the wrong thing or insert the code in the wrong place and then it may work (if it doesn't necessarily matter where in a function the code is and doesn't accidentally drop it in the middle of some if or for) but it may also break everything.

(2 edits)

nice job with current version i ll try instal your mod with my 2 tweaks for combat and see if it explode :D

EDIT: it works together 

http://prntscr.com/pxq09q

your mod must be just loaded 1st :)

there is nice latency before your tooltip pops and thats made it better to use this mods

Its because it technically is a hint window instead of an actual tooltip. I kinda took the minimalist route and didn't want to expand the scope to include a new panel which would properly format the information so i utilized the hint portion of the existing combat panel. But because its a hint and not a panel it has a small delay when hovering over something.