This is causing me a headache now, Basicly im using this http://www.solcon.nl/s.tennapel/inventorytgf.gam as a base for my inventory system,
I have now begun to make it into a usable inventory system but my problem is as follows...
i have created a cursor object that appears when i click on the slot, i want to be able to delete what ever is in that slot. I have tried lots of things but my coding sucks pretty badly and i cant seem to find a way round it, Plus im trying to make the items stackable. if anyone can give me some pointers or even add that to this example that would be amazing. Thx for your time.
Antworx, I D/L'd this last night at home but it said I was missing an extension. (I forget just which one but I think it began with "F"). If I have MMF1.5 that shouldn't make a difference, right?
--
"Del Duio has received 0 trophies. Click here to see them all."
"To be a true ninja you must first pick the most stealthy of our assorted combat suits. Might I suggest the bright neon orange?"
DXF Games, coming next: Hasslevania 2- This Space for Rent!
What you're asking isn't particulary difficult so I'll have a look at the code tomorrow since you asked so nicely.
I had a quick look at that first gam; didn't check the code but it looks like it just emulates a multi-slot inventory and actually only stores each item in a single variable.
Question: Do you want multiple items of the same type to ONLY take up a single slot (with a number), or do you want it to be possible for them to take up multiple slots AND be stacked?
yeah i would really appreciate a stack system with a number. (preferably with a limit ie 20potions then a new stack will begin) and a stable drop system. This has been causing me a headache for ages and i am really appreciative for the help, thanks again
Okay, I was about to write it for you and then I realised the first file was a gam so you're probably using TGF. I don't have TGF installed. Is a MMF1.5 or MMF2 file okay or should I dig through my backups?
ya what Phizzy said. Item stacking. use arrays and string parser to handle everything. The array would even stay in memory unless you decide to export it to a file.
That's what I'm doing now (although it's just a one-dimensional array). Only a couple events away from being finished, which I'll do after lunch if I have time.
thank you soooooo much radix, ive been needing this for so long. Credit will be given as this is a very important aspect of my game. you are my mmf coding hero!
Yeah, thanks for the reminder. It's like five minutes away from being finished, but MMF2 has decided to crash for no reason. I just need to fix the bad event (I've tested it and the event itself is fine, but MMF is being a bitch). If I don't have time tonight, expect it up tomorrow.
You can specify the inventory size, layout, and max stack size. Items are inserted into the first empty slot. Items can be dragged into empty slots or stacks of the same object. Dragging objects into the red garbage box drops/deletes them.
Only thing missing is multiple-object dragging. Didn't add this because I didn't know if you wanted it and I can think of about three different ways to implement it anyway. If you need it and can't do it yourself, let me know.
Also there's not a while lot of commenting, but it's all in self-descriptive groups. Just ask if you need something explained.
Meh, I just haven't been active on the boards lately and decided to make a comeback (and this time, IT'S PERSONAL). I also just grabbed meself a copy of this for later use.