Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Duplicating an existing item #32

Closed
jonndoe47pp opened this issue Apr 8, 2021 · 3 comments
Closed

Duplicating an existing item #32

jonndoe47pp opened this issue Apr 8, 2021 · 3 comments
Labels
enhancement New feature or request

Comments

@jonndoe47pp
Copy link

For non stackable items you can't increase the quantity. And as I asked before you author(s) of this edit can't create new items in the inventory as that info isn't publicly available... But out of curiosity, would it be possible to copy an item and over write an existing inventory item ? Of course you would warn the user that this would erase for good the previous item.... Would this be a kludge/workaround on not being able to do this (it all has to do with the death fog barrel in case you wanted to know).

@NovFR NovFR added the enhancement New feature or request label Apr 8, 2021
@NovFR
Copy link
Owner

NovFR commented Apr 8, 2021

Replacing an existing item would be easier indeed as I won't have to deal with InventoryViews and other stuff, but the problem remains. Deeply modifing items may have side effects I don't know, because I have no idea on how the game create items and what data it needs to function properly.

And to be honest, adding a new item would be theorically less "dangerous" than completely replacing existing one.

With my actual knowledge, I'm affraid I can't make such modifications.

@NovFR
Copy link
Owner

NovFR commented Apr 8, 2021

If you really want to experiment:

  1. Take an item you can easily duplicate ingame (such as potions)
  2. Split the stack to create stacks of 1 item
  3. Save

Load your savegame into GlEd.

  1. Find the item you want to duplicate
  2. Open item's tree
    1. Copy the value of Flags
    2. Copy the value of CurrentTemplate
    3. Copy the value of CurrentTemplateType
    4. Copy the value of Stats
  3. For each item you want to replace:
    1. Open item's tree
    2. Replace all the above values
  4. Save and try ingame

I can't guarantee it will work as I haven't tested yet, but it can be a solution of your problem.

@jonndoe47pp
Copy link
Author

I'll try those suggestions, but for now I'll close the ticket. Thanks for the feedback.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants