Hi..
What I want to do is this.. A (alcove has a dagger in it) the player takes the dagger out of the Alcove door opens and Blockers are destroyed..
A message comes up then a sound..
X Monster X
door1--------door2
alcove1
(with dagger in it).
I can it to work when a dagger is placed into the Alcove but not sure about the other way around.. I tried this connected to the alcove:
function StealNo()
if ha2:getItemCount() == 0 then
block2:destroy()
hermitdoor1:open() else
hermitdoor1:close()
end
end
Any Help with this Thxs..
Take item out of Alcove
- Eleven Warrior
- Posts: 752
- Joined: Thu Apr 18, 2013 2:32 pm
- Location: Australia
Re: Take item out of Alcove
Have you tried it with 'activate always' checked for the alcove? That should make any interaction trigger its event(s).Eleven Warrior wrote:Hi..
I can it to work when a dagger is placed into the Alcove but not sure about the other way around.. I tried this connected to the alcove:
- Eleven Warrior
- Posts: 752
- Joined: Thu Apr 18, 2013 2:32 pm
- Location: Australia
Re: Take item out of Alcove
Hi..
Yeah I did that and it works, the trouble is say the player puts the Dagger back in the Alcove thinking they are safe now. That's when I get a Duplicate error or the Editor said the (Blocker is a Nil Value (Destroy Blocker). See the Blocker in destroyed already and when Dagger is returned it tries to do the Destroy Function again, maybe my function is looping not sure..
Yeah I did that and it works, the trouble is say the player puts the Dagger back in the Alcove thinking they are safe now. That's when I get a Duplicate error or the Editor said the (Blocker is a Nil Value (Destroy Blocker). See the Blocker in destroyed already and when Dagger is returned it tries to do the Destroy Function again, maybe my function is looping not sure..
Re: Take item out of Alcove
That would seem to call for a script. Perhaps add a counter that increments to 1 on the first use, and if it's later found to be 1 (or more?) then it could bypass the alcove/blocker code block; (unless you want the alcove to refuse the dagger entirely).Eleven Warrior wrote:Hi..
Yeah I did that and it works, the trouble is say the player puts the Dagger back in the Alcove thinking they are safe now. That's when I get a Duplicate error or the Editor said the (Blocker is a Nil Value (Destroy Blocker). See the Blocker in destroyed already and when Dagger is returned it tries to do the Destroy Function again, maybe my function is looping not sure..
Or just put in a check for the Blocker's id string; and if that doesn't exist, don't try to destroy it.
Re: Take item out of Alcove
might be better to simply activate or deactivate the blocker
Finished Dungeons - complete mods to play
- Eleven Warrior
- Posts: 752
- Joined: Thu Apr 18, 2013 2:32 pm
- Location: Australia
Re: Take item out of Alcove
Hi .. Guys
Damm i should have relised that Komag, i forgot the Blockers can be Deactivated (LOL). Ill script it in.
blocker_1:deactivate() That makes more sense.
Another way i did it was when I destroyed the Blockers I destroyed the alcove and spawned another alcove in its place, this also worked.
In the end i put a Wall grate in front of the alcove, player opens the grate, takes dagger, grate close's and blockers destroyed, Ogre attacks the party.. This method is effective and i like it. 3 ways to do what i wanted LOL..
Thxs again guys for your help..
Damm i should have relised that Komag, i forgot the Blockers can be Deactivated (LOL). Ill script it in.
blocker_1:deactivate() That makes more sense.
Another way i did it was when I destroyed the Blockers I destroyed the alcove and spawned another alcove in its place, this also worked.
In the end i put a Wall grate in front of the alcove, player opens the grate, takes dagger, grate close's and blockers destroyed, Ogre attacks the party.. This method is effective and i like it. 3 ways to do what i wanted LOL..
Thxs again guys for your help..
Re: Take item out of Alcove
I didn't catch that you were working with real blockers; I was still thinking it was Cube related. 
- Eleven Warrior
- Posts: 752
- Joined: Thu Apr 18, 2013 2:32 pm
- Location: Australia
Re: Take item out of Alcove
hi Isaac..
Yeahi should have mentioned that sorryY they are the normal blockers and the one you made..
Yeahi should have mentioned that sorryY they are the normal blockers and the one you made..
