Indie game storeFree gamesFun gamesHorror games
Game developmentAssetsComics
SalesBundles
Jobs
Tags

Strive for Power

Fantasy Slave Management/RPG Erotic Game · By Strive4Power

Adding New Areas?

A topic by hecatoncheyr created Sep 10, 2018 Views: 3,247 Replies: 11
Viewing posts 1 to 6

I decided to piddle around and explore adding new areas, because who doesn't like exploring more places? Well I was immediately unsuccessful and I'm not quite sure where/what my problem is exactly.  So here's the steps I took (according to the modding guide and in the posts I've read here):

Step 1: Create /mods folder in User/AppData/Roaming/Strive/mods

Step 2: Create folder in /mods, eg: User/AppData/Roaming/Strive/mods/Expanded/scripts

Step 3: Identify GD files for existing areas (ignoring ones that seemed quest/teleport related)-- explorationregions.gd and gallery.gd

Step 4: Copy existing area (Marsh in this case) and tweak it. 'Marsh Ruin' created, exit to new 'Marsh Ruin' added to 'Marsh', exit FROM 'Marsh Ruin' set to 'Marsh'. Slightly tweak enemy list.-----Saved and added explorationregions.gd to /mods/Expanded/scripts

Step 5: Same as the above (just setting a background picture in gallery.gd)---- Saved and added gallery.gd to /mods/Expanded/scripts

Step 6: Open Strive.exe, click mod(s) on main menu. Click mod, click apply, crash game.

Where did I lose the wheels on my short bus? See attached picture. (https://imgoat.com/v/144578/crashycrash) I barely caught the console errors via screenshot before everything exited out (hence the fading). The bottom of the pic is the explorationregions.gd, the top right is gallery.gd, and the top left is the console errors thrown.

Can someone more educated/knowledgeable than me, point out where I went wrong/spilled the teapot?

Thanks

You don't really need a marshruin background if you are not using it in area data. Also it's quite hard to say what went wrong without your code. 

(1 edit)

https://pastebin.com/VUqB57eq

https://pastebin.com/ZtXcEgxM

explorationregions.gd and gallery.gd pastebins respectively. I know the background isn't really needed but I figured I play around with it anyway.  I assume the problem I've having is that any new additions actually need to be 'called out' I guess? And not just 'inserted' in to existing code.

Edit: @ Line 117 on explorationregions.gd

@ Line 506 gallery.gd

Just tried using it without gallery with no issue. I suggest trying to remove it and try again. Also what is your OS?

Clicking apply exits the game, it's normal for it to exit when you apply a mod. It didn't "crash".  I do believe it'd be nicer if the game gave a message box at the end like "Mods applied successfully, please restart the game, exiting..." and an ok button.

The yellow bits in your screenshot happen every time you exit the game, applying a mod or not. The other errors are it looking for a info.txt file, add that to your mod folder and they go away.

You appear to be trying to wholesale replace the files, are you using version 0.5.19b? Older versions wouldn't handle correctly replacing a multi-line variable.  However, honestly, I don't like this approach. Doesn't work well if say you wanted your mod to play nice with someone else's mod. Instead I'd do it like this:

https://pastebin.com/SCDggsDh

This works, at least with 0.5.19b, but probably with most older versions too since it only adds a simple var and modifies a function.  It works in a manner that would play nice with other mods.  You could have 20 mods like this, each adding their own regions, and as long as they named them something different, they'd all work.

I apologize for the delay, I appreciate the feedback. For these purposes I'm using Windows 10 64-bit. I didn't think to check the version, I just now switched to 0.5.19c.

I may have something going on, on my end. I took a brand new 'installation' of 0.5.19c and took the script provided in https://pastebin.com/SCDggsDh

and dropped it into /mods/extended/scripts/explorationregions.gd

It actually prevents me from using any of the main menu buttons after the mod is selected, and it applies itself (and I restart the game.).   If I look in the /Strive folder with the .exe on my desktop, all the files now read 0kb or 1kb. A fresh 'install' of 0.5.19c without applying mods fixes the issue. I'm not sure what would cause this issue, possibly something on my end/my machine specifically, I'll try it on a laptop and see what shakes out.

i had this issue too

i fixed this:
- deleted the files in AppData\Roaming\Strive\..

- copied my mods again to Strive\..

- deleted the game and took "new install"

- started the game and used the reset function in mods menu

- started the game and activated the mods

Didn't work for me. 

-Deleted appdata/roaming/strive

-created appdata/roaming/strive and put mod into folder /blah/scripts/explorationregions.gd

-deleted existing game folder on desktop

-re-extracted/installed new game folder on desktop

-used reset function in-game

-started game up again, applied mods, same issue occurred (menu unclickable/non-functioning) Noteably here: the version displayed changed from 0.5.19c to 0.5.19d

-----------------------------------------------------------

then I repeated all of the above but skipped the reset function part, same unclickable/non-functioning menu happened.

-----------------------------------------------------------

then did the following

-Deleted appdata/roaming/strive

-deleted existing game folder on desktop

-re-extracted/installed new game folder to desktop

-opened the game, closed the game (without going to mod menu)

-added mod appdata/roaming/strive

-opened the game, hit apply, restarted the game, nothing happens. (also tried reset/apply/reset/apply in various orders) Mod isn't applied at all and no 'Modded' shows up to the 0.5.19c version number on the menu.

-deleted appdata/strive/mod folder, reopened game. Now reads 0.5.19c 'Modded' (obviously since the file is missing/nothing changed in-game)

-readded mod to /appdata/strive/mod, opened game, still reads modded, but nothing changed in-game. 

-reapplying mod nothing happens, reset mod nothing happens, different orders of reset/apply don't work as well when starting from step 1 of this.

-----------------------------------------------------------

tried all of the above, both in and out of administrator, didn't matter at all-- same results. Repeated all of the above (again) on windows 10  64x laptop, same result, didn't work. I guess I could try the linux version, I don't know of there'd be a difference. Its a mystery.

Did you try what I suggested up above? I think you're going to just run into all sorts of problems trying to completely replace the file or large chunks of it and the approach i demonstrated will work much more reliably.

I'm using the exact text in the pastebin you provided, nothing else. It feels like something else is going on, is there a temp file folder somewhere outside appdata/roaming?

maybe a mod from you is broken

Yeah, are you starting from a fresh extract of the game? If a previous mod failed to apply then it leaves the game in a broken state, you need to extract it back out.

Ideally the mod engine would detect that it failed in some way, and revert, or the revert code could somehow be protected.  You can delete the files folder copy the backup folder and name that copy files, and that does a revert, or i find it easier to wipe the folder and extract again.