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

creating tame vermin (pets) in gui/create-item results in mangled data #4507

Open
myk002 opened this issue Apr 24, 2024 · 3 comments
Open

creating tame vermin (pets) in gui/create-item results in mangled data #4507

myk002 opened this issue Apr 24, 2024 · 3 comments
Labels

Comments

@myk002
Copy link
Member

myk002 commented Apr 24, 2024

as per https://discord.com/channels/793331351645323264/1017471248567124049/1232483204347330631

@myk002 myk002 added the bug label Apr 24, 2024
@quietust
Copy link
Member

quietust commented May 1, 2024

To clarify, the vermin items are somehow ending up with a race of -1 and a caste consisting of the specified race.

The bug is entirely inside gui/create-item.lua and/or modtools/create-item.lua, since the createitem plugin creates vermin correctly (tested with createitem VERMIN ANT:QUEEN and createitem PET ANT:SOLDIER and both came out correctly).

@myk002
Copy link
Member Author

myk002 commented May 1, 2024

is it worth replacing logic in gui/create-item and/or modtools/create-item with a call to createitem?

@quietust
Copy link
Member

quietust commented May 1, 2024

They're both calling the same code inside the Items module - the only difference is in how they translate user-provided inputs into numeric IDs, and I'm not sure whether it makes sense for them to share that (because createitem takes them in "custom reaction" format, while gui/create-item takes them from menu selections).

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

No branches or pull requests

2 participants