SphereCommunity
How doors work? - Printable Version

+- SphereCommunity (https://forum.spherecommunity.net)
+-- Forum: Sphere 0.56d (/Forum-Sphere-0-56d)
+--- Forum: General Help (/Forum-General-Help)
+--- Thread: How doors work? (/Thread-How-doors-work)



How doors work? - Shaklaban - 06-28-2012 02:14 PM

Hi, i want to use shadow, crystal doors etc. on my shard but they are not working. I just look at the metal door base script but shadow doors won't open. Here is my shadow door script:

Code:
[itemdef 13967]
defname=i_door_shadow
type=t_door
dupelist=13969,13963,13965,13971,13973,13975,13977

[itemdef 13969]
dupeitem=13967

[itemdef 13963]
dupeitem=13967

[itemdef 13965]
dupeitem=13967

[itemdef 13971]
dupeitem=13967

[itemdef 13973]
dupeitem=13967

[itemdef 13975]
dupeitem=13967

[itemdef 13977]
dupeitem=13967

[itemdef 13968]
type=t_door_open
dupelist=13970,13964,13966,13972,13974,13976,13978

[itemdef 13970]
dupeitem=13968

[itemdef 13964]
dupeitem=13968

[itemdef 13966]
dupeitem=13968

[itemdef 13972]
dupeitem=13968

[itemdef 13974]
dupeitem=13968

[itemdef 13976]
dupeitem=13968

[itemdef 13978]
dupeitem=13968



RE: How doors work? - Gil Amarth - 06-28-2012 07:28 PM

Have you checked if in your tiledata.mul are marked as "Doors"?

Tiledata.mul is essential for a lot of functions, so you probably have to patch your tiledata.mul and distribute it to your players.


RE: How doors work? - Terrikate - 06-28-2012 08:50 PM

http://tracker.sphere.torfo.org/bugs/view.php?id=2054


RE: How doors work? - Gil Amarth - 06-29-2012 08:35 AM

Uhm, yes, it doesn´t work, but it is easy to replicate doors with a bit of scripting:

Quote:[ITEMDEF 0369a]
DEFNAME = i_strange_door
NAME = strange door
WEIGHT = 1
type = t_door

ON=@DCLICK
SERV.NEWITEM = 03699
NEW.P = <P>
NEW.TIMER = 60
SFX 00ea
REMOVE
RETURN 1

[ITEMDEF 03699]
DEFNAME = 03699
NAME = strange door
WEIGHT = 1
type = t_door

ON=@DCLICK
SERV.NEWITEM = 0369a
NEW.P = <P>
SRC.SFX 00eb
REMOVE
RETURN 1

ON=@TIMER
SERV.NEWITEM = 0369a
NEW.P = <P>
SFX 00eb
REMOVE
RETURN 1

And you have a door who faces north. I have tested it and works. Smile


RE: How doors work? - Skul - 06-29-2012 02:05 PM

no attr on that opened door = stolen door
i was trying to remember if there was a TDATAx value but appears there is none, I could've sworn there was something, it was written on the old Taran's World site.


RE: How doors work? - Gil Amarth - 06-29-2012 06:21 PM

Fixed.

Code:
[ITEMDEF 0369a]
DEFNAME = i_strange_door
NAME = strange door
WEIGHT = 1
type = t_door

ON=@CREATE
    ATTR |= attr_move_never

ON=@DCLICK
    SERV.NEWITEM = 03699
    NEW.P = <P>
    NEW.TIMER = 60
    SFX 00ea
    REMOVE
    RETURN 1
    
[ITEMDEF 03699]
DEFNAME = 03699
NAME = strange door
WEIGHT = 1
type = t_door

ON=@CREATE
    ATTR |= attr_move_never

ON=@DCLICK
    SERV.NEWITEM = 0369a
    NEW.P = <P>
    SFX 00eb
    REMOVE
    RETURN 1
    
ON=@TIMER
    SERV.NEWITEM = 0369a
    NEW.P = <P>
    SFX 00eb
    REMOVE
    RETURN 1

(06-29-2012 02:05 PM)Skul Wrote:  i was trying to remember if there was a TDATAx value but appears there is none, I could've sworn there was something, it was written on the old Taran's World site.

In Taran´s Guide of Scripting there is only this about TDATA:

t_door
t_door_locked

TDATA1 = Sound to make when the door is opened or closed

And:

t_door
t_door_open
t_door_locked

MORE1 = The lock code, which is normally the UID of the key, or sometimes the UID of a parent item (like a house). Usually is the same as LINK.
MORE2 = How hard this lock is to pick (on a scale of 0 to 1000)
LINK = If there is no MORE1, the MORE1 of the linked item will be checked


RE: How doors work? - Valios - 07-04-2012 02:39 AM

All the posts not related to the topic were deleted, mine included. We need to stop all the shit talking.