I’ve been dealing with this issue for a couple of days now and was wondering if anyone else has ever run into this. (So sorry if there’s already a thread about this.)
The game I’m working on has eighteen inventory objects to pick up and use for different puzzles. Creating and using the first fifteen objects works perfectly. However, my program refuses to create the last three.
Part of this could be because I’m a non-coder who relies on duct tape and bubblegum, but the thing that’s odd is that I have a create/target inventory command (that occurs in the same room as the last three items) right above the broken code that works perfectly fine.
The player’s inventory limit is fifty (might as well, am I right?), so it shouldn’t be a weight problem or an over-crowded inventory problem. I’ve tried placing the three objects in the room at the start, I’ve tried creating and then pocketing the objects, and I’ve tried creating the three objects at the same time as the create/target inventory code that works. Nothing.
I don’t remember there being an object limit in the user guide or the cookbook, but if anyone has faced a similar problem with creating objects or has any ideas on why that might be the case, I’d love to hear about it. Thanks~
If you have the relevant code, you could post it here (using the ‘code’ option at the top of the message box on the same row as the bold and italics buttons).
You can also get live help at the Adventuron discord (I think this is the link: Discord)
And you’re right, it shouldn’t be a built in thing; there are adventuron games with way more than 18 objects, so something’s not right!
Again, I’m a non-coder so it’s real messy and long, but I’m working on a list to hopefully consolidate things.
: match "look supplies; examine supplies; observe supplies; search supplies; see supplies; rummage supplies; ransack supplies" {
: if (tied_up ==false) {
: if (is_exists "fire_extinguisher" && is_exists "rope" && is_exists "cooking_spray") {
: if (is_carried "fire_extinguisher" && is_carried "rope" && is_carried "cooking_spray") {
: print "There's nothing else from the camping supplies that you need." ;
}
: else_if (is_carried "fire_extinguisher" && !is_carried "rope" && !is_carried "cooking_spray") {
: print "Looking through the outdoors equipment, some <ROPE<#b45>> and cooking <SPRAY<#b45>> catch your attention." ;
}
: else_if (is_carried "fire_extinguisher" && is_carried "rope" && !is_carried "cooking_spray") {
: print "Looking through the outdoors equipment, a can of cooking <SPRAY<#b45>> catch your attention." ;
}
: else_if (!is_carried "fire_extinguisher" && is_carried "rope" && !is_carried "cooking_spray") {
: print "Looking through the outdoors equipment, a fire <EXTINGUISHER<#b45>> and some cooking <SPRAY<#b45>> catch your attention." ;
}
: else_if (!is_carried "fire_extinguisher" && is_carried "rope" && is_carried "cooking_spray") {
: print "Looking through the outdoors equipment, a fire <EXTINGUISHER<#b45>> catches your attention." ;
}
: else_if (!is_carried "fire_extinguisher" && !is_carried "rope" && is_carried "cooking_spray") {
: print "Looking through the outdoors equipment, a fire <EXTINGUISHER<#b45>> and some <ROPE<#b45>> catch your attention." ;
}
: else_if (is_carried "fire_extinguisher" && !is_carried "rope" && is_carried "cooking_spray") {
: print "Looking through the outdoors equipment, some <ROPE<#b45>> catches your attention." ;
}
: else_if (!is_carried "fire_extinguisher" && !is_carried "rope" && !is_carried "cooking_spray") {
: print "As you sort through all the outdoors equipment, looking for items that may be useful, three things catch your attention: a fire <EXTINGUISHER<#b45>>, <ROPE<#b45>>, and cooking <SPRAY<#b45>> (which, is arguably less useful than the other two)." ;
}
}
: else_if (!is_exists "fire_extinguisher" && !is_exists "rope" && !is_exists "cooking_spray") {
: print "As you sort through all the outdoors equipment, looking for items that may be useful, three things catch your attention: a fire <EXTINGUISHER<#b45>>, <ROPE<#b45>>, and cooking <SPRAY<#b45>> (which, is arguably less useful than the other two)." ;
: create "fire_extinguisher" ;
: create "rope" ;
: create "cooking_spray" ;
}
}
: else_if (tied_up == true) {
: print "You have to free yourself of the ties before you can look at them." ;
}
}
objects {
// Make sure you don't have conspicuous="false" or listed="false," or else you won't be able to see the items in the item list OR in your inventory.
fire_extinguisher : object "a fire extinguisher" msg="It puts out fires." get_message="You pick up the heavy fire extinguisher and toss it into your infinitely expansive imaginary backpack." ;
rope : object "some rope" msg="It's made of twisted fibers." ;
cooking_spray : object "cooking spray" msg="Spray this on your pan, and your pancakes will slide right off." ;
}
scenery {
supplies : object "a pile of supplies" msg="Nothing else in the pile of supplies seems useful."
}
on_command {
: if (is_present "supplies") {
: match "examine supplies;rummage supplies;ransack supplies" {
: if (tied_up == false) {
: if (has_not_created "fire_extinguisher") {
: create "fire_extinguisher" ;
: create "rope" ;
: create "cooking_spray" ;
: print "As you sort through all the outdoors equipment, looking for items that may be useful, three things catch your attention: a fire <EXTINGUISHER<#b45>>, <ROPE<#b45>>, and cooking <SPRAY<#b45>> (which, is arguably less useful than the other two)." ;
: done ;
}
: else_if (is_beside "fire_extinguisher" || is_beside "rope" || is_beside "cooking_spray") {
// This is a useful way of adding text that only shows up in certain situations. In this case, if the object is beside the character. You can also use this with booleans!
: print "Looking through the outdoors equipment, you see {fire_extinguisher? `a fire <EXTINGUISHER<#b45>>, `}{rope? `some <ROPE<#b45>>, `}{cooking_spray? `some <COOKING SPRAY<#b45>>, `} some old junk, and some other useless supplies." ;
}
}
: else {
: print "You have to free yourself of the ties before you can look at them." ;
}
}
: match "examine junk" {
: print "Some of that stuff is so old, you're not even sure what it's for. You don't need it." ;
}
}
}
This is such a good idea! Thanks so much for suggesting it! I’ll be sure to use it in my next game since this one’s pretty much done haha
Here’s the error I get when I put it in Thanks so much for trying all these out, though! I’ll put this out in the discord and see if we can all figure it out
Oh darn it… I guess the {fire_extinguisher ?} thing only works in the beta version. I think the regular version does allow you to do that with booleans though.
Anyway, I see that you’ve joined the Discord, so I’m sure you’ll get some more help there!
Assuming you set all the synonyms for EXAMINE in the vocabulary{} section, then in the interests of simpicity, you could try this.
: match "examine supplies; rummage supplies; ransack supplies" {
: if (tied_up) {
: print "You have to free yourself of the ties before you can look at them.";
: done;
}
: if (has_not_created "fire_extinguisher") {
: create "fire_extinguisher";
: create "rope";
: create "cooking_spray";
: print "As you sort through all the outdoors equipment looking for items that may be useful, three things catch your eye: a fire <EXTINGUISHER<#b45>>, a <ROPE<#b45>> and some cooking <SPRAY<#b45>> (which is arguably less useful than the other two).";
: done;
}
: print "There's nothing else that you need from the camping supplies.";
: done;
}