Jump to content

Wood chopping and Ore collecting script help...


GrumpyTanky

Recommended Posts

Hello,

 

 

Was wondering if anyone could help me with a little problem... To start I have no idea how to script... Plus my eyes have gone square trying to route through the numerous, very informative tutorials... I just need simple answers or help if anyone can with three scripts...

 

I want to have it so you can harvest 500 bits of fire wood, but only 2 at a time like the default... Thus your character will just sit and chop a lot longer... Until he/she has 500 firewood... Also wanted the same to happen with the Ore collection...

 

So I edited the numbers in the scripts:

 

MineOreScript.psc

ResourceFurnitureScript.psc

WoodChoppingScript.psc

 

But I cannot figure out how to save as .pex or get the engine to execute these amended scripts. I also placed them in Data/Scripts and tried Data/Scripts/Source with no success... Can anyone please explain step by step how I might go about getting these to work? Please keep in mind that my primary job in life is working in silly countries getting shot at and that I am scripting literate. Intrinsically I am thick as pig poops... Cheers!

 

PS I have attached the files in the only format I could export the .psc

Link to comment
Share on other sites

You have to compile the .psc and thus create .pex files

 

1) Place the .psc file in the Data/Scripts/Source folder

2) Open the CK and load just Skyrim.esm

3) Gameplay > Papyrus Script Manager

4) Use the filter to find your script, rightclick on it and select Compile

 

You can also set up the compiler to be used from some editors like notepad++ (wiki link)

Link to comment
Share on other sites

Cheers M3rvin...

 

 

It compiled and re-wrote as a .pcx but the game still wont recognize these new scripts... I've placed the amended files in skyrim/data/scripts but still nothing... I don't need to have an .esp file to tell the game to run the scripts do I? Cheers for any help...

Link to comment
Share on other sites

So the Papyrus Script Manager successfully compiled the script(s) you edited? If so a .pex file(s) with the same name(s) as your script(s) should be in your Skyrim\Data\Scripts folder. If you compiled the files correctly, the .pex files should be automatically placed in the right folder, no need to move them by hand.

Anyway, how do you know that your script doesn't work?

Link to comment
Share on other sites

Erm,

 

 

 

I tried to chop wood in game and it was still yielding (2) per chop and only chopping 3x... Do I have to tell the game to recompile scripts manually? I have used the "more firewood per chop" mod and all that did was place it's .pex files into the Skyrim/Data/Scripts folder... I took that mod out and put mine in and nothing happened... as in the default was run instead...

 

I've attached my latest .pex files... Just incase... Cheers, your help is very much appreciated...

Link to comment
Share on other sites

Yeah,

 

 

The .psc files are in the first.rar on the very first post... Cheers...

 

Try modifying these values in the mining script:

 

int property StrikesBeforeCollection = 1 Auto
int property AttackStrikesBeforeCollection = 1 Auto

 

Also can someone explain this part to me? Having a hard time understanding the scripting logic

 

int property StrikesCurrent = -1 Auto hidden

 

Why the - in StrikesCurrent = -1? also seen the reverse further in the script "- = 1"

Link to comment
Share on other sites

Also can someone explain this part to me? Having a hard time understanding the scripting logic

 

int property StrikesCurrent = -1 Auto hidden

 

Why the - in StrikesCurrent = -1? also seen the reverse further in the script "- = 1"

 

I haven't taken a look at the modified scripts, but in the original MineOreScript, this is used to keep track of how many times the player has struck the ore vein. The value is negative by default, indicating that the player has not started any strikes yet.

 

 

StrikesCurrent -= 1

is just short-hand for

 

StrikesCurrent = StrikesCurrent - 1

 

The reason why it takes 3 strikes before giving out ore even though "StrikesBeforeCollection = 1" by default is because the script doesn't actually detect the (animated) strikes. Instead, the MineOreFurnitureScript on the linked ref is the one telling the MineOreScript when an (animated) strike occurs. But the detection in the MineOreFurnitureScript is flawed, so it only detects it every 3rd strike.

Edited by fg109
Link to comment
Share on other sites

I haven't taken a look at the modified scripts, but in the original MineOreScript, this is used to keep track of how many times the player has struck the ore vein. The value is negative by default, indicating that the player has not started any strikes yet.

 

 

StrikesCurrent -= 1

is just short-hand for

 

StrikesCurrent = StrikesCurrent - 1

 

The reason why it takes 3 strikes before giving out ore even though "StrikesBeforeCollection = 1" by default is because the script doesn't actually detect the (animated) strikes. Instead, the MineOreFurnitureScript on the linked ref is the one telling the MineOreScript when an (animated) strike occurs. But the detection in the MineOreFurnitureScript is flawed, so it only detects it every 3rd strike.

 

Ah that's what I couldn't understand! But would StrikeCurrent = -1 work the same way? Also this part was from the original MineOreScript not the modded one here.

And I'm not sure if the detection is really flawed since it would make sense that the animation would look kind of funny if you just tap the rock and boom you get ore

 

As for the OP: I guess setting the StrikesBeforeCollection to 167 will get you your wanted total of 500 (501 actually).

Link to comment
Share on other sites

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...