The Good Approach - Subtle hints were the best way
You mentioned subtle clues, but really that is the best approach. So, they inspected the well and the door, and you already said there is nothing different. Maybe there is something on the wall that hints, perhaps scrawled by previous failed adventurers "Generosity is to be praised." "Each only gets one." Etc.
If they really don't want to bash the door in, maybe they should backtrack get an NPC minion and have the minion make the needed wish.
If you want to be even more subtle, they notice something about the layout of the whole room that reminds the bard/wizard/cleric of some ancient Rune and they should go back to talk to an expert who can then subtly (or not so subtly) hint about it talking about the Rune referring to self sacrafice or something like that.
Speaking of Bards/Clerics even PC Bards and Clerics make a decent way to deliver hints. The Bard remembers some lore suddenly (especially if he hasn't made that check yet), for a Cleric the deity might literally give them a bolt of inspiration. I think this is a distinctly inferior approach, but it may be better than the next options I list.
Slightly Less Good - OOC hints
There is nothing wrong with giving the occassional oblique out of character hint. "Sometimes you just need to take the risk of a trap being there."
Deus Ex Makes it Go Away
This is substantially less good, but you can always make the problem almost literally disappear. A massive earthquake destroys the door, and collapses the well.
Retcon
This is a last resort, but its not necessarily a game breaker to just say openly, "This didn't go the way I had planned, why don't we try this scene again." And if they haven't figured it out, drop some further hints this time around.
It's pretty reasonable you're annoyed. One of your fellow players secretly plotted to kill your character for revenge (and it worked), the DM - the one guy you pretty much have to be able to trust - was in on it, and your fellow players offered you no emotional support at a point when you clearly needed it and instead made things worse for you.
People have been annoyed over character deaths, but you also have the issue of a betrayal of trust.
Different groups (and different DMs) handle stuff like this in very different ways - some handle it well, some badly. You had a conflict within the party, and a conflict between two people, and some character death and secret plots on your hands. These are often things groups don't talk about beforehand, but should. As the DM, I wouldn't have allowed this secret plot and would've talked to you two outside the game to get this enmity settled at first signs.
(And honestly, if this was real out-of-game racism you were experiencing, I wouldn't have tolerated that either.)
So now the guy who betrayed you is the DM and you want revenge.
Don't do it.
A good plan is to decline the invitation, not play, leave, and find something else to do or another D&D group to play with. This is not advice for how to ruin Bob's day. This is advice for how to avoid having your own next two months ruined, and possibly several weeks or months after that as well, and instead have some degree of peace for yourself.
You're pissed off. But, proverbially:
Holding onto anger is like drinking poison and waiting for the other person to die.
— (Not sure who first said this)
So you're going to have several gaming sessions and two months in which you're busy being pissed off at Bob, stressed out working out how to get revenge, and suffering over the lot of it - and expecting him to suffer for it. Eventually. At some point. Maybe.
That's not working out in your benefit.
Here's how the next two months are going to pan out according to this plan.
- Bob's the DM. The universe of the game you're considering bends to his whims.
- He doesn't like you to begin with, resents you for something you did to him, and apparently is subtly vengeful. He might give you a hard time for the next two months. This is going to feed right back into you being even unhappier in general, and unhappy to be in that game. This may even increase the degree of revenge you want, something you might not even get to begin with.
- You're going to be preoccupied being annoyed at him and not really actually just enjoying a good game of D&D. (Not that this game is going to be a good game of D&D for you necessarily anyway.)
- Eventually, you might actually find a way to get back at him. But, since he's the absolute controller of the game's universe, he can just say: "Oh. Well, my guy's goddess smiles upon him and heals him. Then she teleports your character into the plane of fire. Alright, whose turn next?"
- Or you don't get anything out of it and you're just annoyed.
- Or a month in, before anything even really happens, he or your fellow players ask you to leave because you're not being very fun to play with. You probably won't be. You're here for revenge, not to enjoy a good game.
- And you're playing with this guy as your DM the whole time, again. That's worth repeating. Why would you want that?
This entire plan is toxic to you and you alone. It's going to be really unpleasant for you, and more likely than not won't get anything out of it - and if you do, it probably won't be very satisfying.
Don't do it.
But I really want revenge!
This is an issue between you and another person, not an issue D&D will help with. Don't try to solve it through D&D, and don't try to solve it by playing with this guy as a DM for a few months.
Deal with it out of the game somehow. Maybe talk to him and get stuff off your chest. Consider walking away and leaving it behind you rather than let this weigh on you. Different things work for different people. I don't know what will work for you, personally. But spend these two months of your life doing something else. Find peace, somehow.
A surprising option is forgiving him - and not for his benefit, but for yours. Forgiveness is just as often so you can stop holding onto the negative emotions you have - the ones which are affecting you much more than anyone else - and let them go and find some inner peace. You might not be prepared to do that, but I advise you try it.
D&D is normally not like this.
(But sometimes it can be.)
There are going to be groups more supportive of first time players. There are going to be groups where you can genuinely be friends with most people, get along with all of them, and reliably trust the DM and your fellow players. This wasn't one of them, clearly. I suggest you find a group that suits you if you want to keep playing D&D.
One thing that normally goes unrecognised is that several D&D players at the same table, playing the same session at the same time, are usually not even playing the same game. They have different expectations of what a good game constitutes, different ideas of what's OK and what's not, different understandings of the rules, and different opinions over how issues like loot and character death should be handled. Usually, they assume that everyone else shares a similar view, without realising that everyone probably thinks very differently - to each other, as well.
An analogy is having several people sitting around a table to play a game of cards, but they are playing different games: one person is playing Poker, another Hearts, and another Go Fish. That wouldn't work very well, but somehow that's how D&D gets played without anyone realising it.
This disconnect is the reason why someone authored the Same Page Tool - which, as its name suggests, exists to get people on the same page. Its author also wrote about The Roots of the Big Problems and A Way Out (from which I drew the card game analogy). All three of these links discuss this issue and the situations that arise from it, and how to deal with them.
This group was not on the same page as you, and were not what you were after. Another group might be.
Best Answer
I'm going to make one critical assumption about your gaming group. If it's untrue, I don't know if my answer will be helpful: The friendship of the people at the table is more important than the game you're playing. Going forward I'm assuming you're all friends foremost, and you play games as a form of mutual recreation. Now, on to my answer.
TL;DR: This is not a game-mechanic problem, and game-mechanic solutions won't fix it. I learned the hard way that if I need game-rule punishments to get players to behave the way I want, it's already gone too far. Solve it as a social challenge, not a game problem. The group needs an out-of-game talk about agreeing on goals and playstyles.
So, you've made it clear that you want to run a game with a particular kind of attitude toward metagaming and you're willing to enforce that attitude punitively.
Some people in your group have made it clear they don't want a game with that attitude, and are willing to endure punitive measures in order to play the kind of game they want to play.
No amount of mechanical leverage is going to fix this situation, because you're trying to use game rules to address a social-level disconnect about the kind of game the group is playing. If you manage to find punishments that are harsh enough to force them into playing the way you want them to, they'll leave instead.
The way to handle this situation is to treat it as the social challenge it is, rather than a game problem. Have a group discussion about playstyle and goals. Hold it outside of play time, maybe over a meal. And since nobody in the group, GM or not, can order other people how to have fun, the discussion needs to be one in which friends are working out how to have fun together. Some of the answers to this question may be useful. Take off your GM hat and have a chat with your friends about how to make game time enjoyable for everyone.
The purpose of the discussion should be finding mutually compatible goals and playstyles that the group can agree on. If that proves impossible (I hope not! but it happens), then the group will know for sure that they aren't all going to be able to have fun in the game together. You can stop trying to force unwanted behaviour on the group and instead spend your energy playing fun games with the people whose playstyles match your own, and the people you can't collaborate with will be free to find groups more suited to their goals.