Page 3 of 3

Re: MultiAlcoveManager

Posted: Tue Jan 20, 2015 4:59 pm
by THOM
You can take the stuff and you can put it back. Concerning the weapon-only-racks there is the restriction that some weapon just fit on certain places.

Re: MultiAlcoveManager

Posted: Tue Jan 20, 2015 5:07 pm
by AdrTru
TheStoryteller01 wrote:This looks amazing.

Is it actually possible to take stuff from the racks or is this just for the looks?
Normal situation is free manipulation with items like another alcove object. But is possible to set variable with script in object ( canRemove = false) for disabling to take item from rack.
That means you may have some rack as decoration and some as standard alcove.
This correctly working in last version - v1.1
THOM wrote:You can take the stuff and you can put it back. Concerning the weapon-only-racks there is the restriction that some weapon just fit on certain places.
Yes this positions of object in rack is stricly defined for each item( group of items if they have simmilar root position and type ) separately. But this system is open and it is possible to add new positions for custom items if it need.

Re: MultiAlcoveManager

Posted: Sun Feb 08, 2015 8:53 pm
by AdrTru
I published version 1.5 of this mod.

There is massive bugfix for savevariables.
there is added short documentation

When you use older version of MAM is it neccessary to remove old rack from dung and put new ones after reloading dung with new scrips.

Re: MultiAlcoveManager

Posted: Mon Jun 15, 2015 10:24 am
by Duncan1246
AdrTru wrote:I published version 1.5 of this mod....
Hi AdrTru,
I use several multialcoves manager in my mod. Each time, the same issue occurs: when I have one elevation above or under the racks, party can't move if in front of the rack in the dir of the rack... I think perhaps it's because of this part of code:
SpoilerShow

Code: Select all

function onMoveThru(dir)
	local dx, dy = getForward(dir)
	local tile = party.map:entitiesAt(party.x, party.y)
    for ent in tile do
		if ent.mamdata ~= nil and ent.mamdata.getCanMoveThru() ~= nil and MAM_Racks[ent.id] ~= nil then
			local canMoveThru = MAM_Racks[ent.id].canMoveThru or MAM_onMoveThru or false
			if (canMoveThru == false) and (ent.facing == dir) then return false end
		end
	end
	local tile = party.map:entitiesAt(party.x + dx, party.y + dy)
	for ent in tile do
		if ent.mamdata ~= nil and MAM_Racks[ent.id] ~= nil then
			if (MAM_Racks[ent.id].canMoveThru == false) and (ent.facing == (dir + 2) % 4) then return false end
		end
	end

	return true
end

... but rather to attempt to change it by myself, what do you suggest (except to don't use it in multielevations map :mrgreen: )?
Duncan

Re: MultiAlcoveManager

Posted: Mon Jun 15, 2015 5:22 pm
by AdrTru
Oki, thank you for report.

There is changed function for respected Elevation.
SpoilerShow

Code: Select all

function onMoveThru(dir)
   local dx, dy = getForward(dir)
   local tile = party.map:entitiesAt(party.x, party.y)
    for ent in tile do
      if ent.mamdata ~= nil and ent.mamdata.getCanMoveThru() ~= nil and MAM_Racks[ent.id] ~= nil then
         local canMoveThru = MAM_Racks[ent.id].canMoveThru or MAM_onMoveThru or false
         if (canMoveThru == false) and (ent.facing == dir) and (ent:getElevation() == party:getElevation()) then return false end
      end
   end
   local tile = party.map:entitiesAt(party.x + dx, party.y + dy)
   for ent in tile do
      if ent.mamdata ~= nil and MAM_Racks[ent.id] ~= nil then
         if (MAM_Racks[ent.id].canMoveThru == false) and (ent.facing == (dir + 2) % 4) and (ent:getElevation() == party:getElevation()) then return false end
      end
   end

   return true
end
But for OOR3 project I changed MAM like Pedestal ( there isnt need this function )
I will create new mod version for nexus site asap.

Re: MultiAlcoveManager

Posted: Mon Jun 15, 2015 7:27 pm
by Duncan1246
AdrTru wrote:Oki, thank you for report.

There is changed function for respected Elevation.
SpoilerShow

Code: Select all

function onMoveThru(dir)
   local dx, dy = getForward(dir)
   local tile = party.map:entitiesAt(party.x, party.y)
    for ent in tile do
      if ent.mamdata ~= nil and ent.mamdata.getCanMoveThru() ~= nil and MAM_Racks[ent.id] ~= nil then
         local canMoveThru = MAM_Racks[ent.id].canMoveThru or MAM_onMoveThru or false
         if (canMoveThru == false) and (ent.facing == dir) and (ent:getElevation() == party:getElevation()) then return false end
      end
   end
   local tile = party.map:entitiesAt(party.x + dx, party.y + dy)
   for ent in tile do
      if ent.mamdata ~= nil and MAM_Racks[ent.id] ~= nil then
         if (MAM_Racks[ent.id].canMoveThru == false) and (ent.facing == (dir + 2) % 4) and (ent:getElevation() == party:getElevation()) then return false end
      end
   end

   return true
end
But for OOR3 project I changed MAM like Pedestal ( there isnt need this function )
I will create new mod version for nexus site asap.
Thanks a lot! I have tested it just now and it works fine. I don't use your asset in ORR3, only in the mod I am working on.
Duncan

Re: MultiAlcoveManager

Posted: Thu Jun 18, 2015 10:18 pm
by AdrTru
In Nexus is new version MAM.

- mod now worked without need fw hook.
- keep compatibility with object in dung ( read readme.txt for instalation )
- add hook for hanging shields on wall
- racks are redefined lke pedestal for manipulating items from both sides
- fix for bug on moving thru rack in different elevations ( as pedestal )

Re: MultiAlcoveManager

Posted: Sun Jun 21, 2015 7:52 pm
by Duncan1246
AdrTru wrote:In Nexus is new version MAM.

- mod now worked without need fw hook.
- keep compatibility with object in dung ( read readme.txt for instalation )
- add hook for hanging shields on wall
- racks are redefined lke pedestal for manipulating items from both sides
- fix for bug on moving thru rack in different elevations ( as pedestal )
Hi AdrTru,
I tried to install the new version, but some issue happens: armours and weapons don't take theirs positions on the racks (except on the ledge) even on new racks. I have suppressed the script "mam" in the dungeon, following the "readme" but perhaps it's necessary to recreate it? For the moment I reinstall the precedent version ...

Re: MultiAlcoveManager

Posted: Thu Jun 25, 2015 8:34 am
by AdrTru
Hi,
unfortunately I am dont able to simulate this situation.
This qiuck update worked for near last versions. If you have older version, this replacing is little difficult.