Forums WoW Modding Support Archives WoWModding Threads [DiscordArchive] I'm looking to have a lever that, when toggled, causes a platform to move up or down (depending on w

[DiscordArchive] I'm looking to have a lever that, when toggled, causes a platform to move up or down (depending on w

[DiscordArchive] I'm looking to have a lever that, when toggled, causes a platform to move up or down (depending on w

Pages (3): Previous 1 2 3 Next
rektbyfaith
Administrator
0
03-12-2025, 07:43 PM
#11
Archived author: stoneharry • Posted: 2025-03-12T19:43:57.158000+00:00
Original source

almost forgot to reply to this

you can implement it a number of different ways

you could check for nearby platforms and use the closest one, you could fetch the object with the GUID, you could filter by DB GUID Low, you could have 1 script per lever

I've done something very very similar with actual transports rather than just lifts (elevators).
rektbyfaith
03-12-2025, 07:43 PM #11

Archived author: stoneharry • Posted: 2025-03-12T19:43:57.158000+00:00
Original source

almost forgot to reply to this

you can implement it a number of different ways

you could check for nearby platforms and use the closest one, you could fetch the object with the GUID, you could filter by DB GUID Low, you could have 1 script per lever

I've done something very very similar with actual transports rather than just lifts (elevators).

rektbyfaith
Administrator
0
03-12-2025, 07:44 PM
#12
Archived author: stoneharry • Posted: 2025-03-12T19:44:21.507000+00:00
Original source

I don't know of anywhere else in retail that controls lifts/transports with levers, and SmartAI only handles common scenarios (since each scenario needs to be implemented)
rektbyfaith
03-12-2025, 07:44 PM #12

Archived author: stoneharry • Posted: 2025-03-12T19:44:21.507000+00:00
Original source

I don't know of anywhere else in retail that controls lifts/transports with levers, and SmartAI only handles common scenarios (since each scenario needs to be implemented)

rektbyfaith
Administrator
0
03-12-2025, 07:46 PM
#13
Archived author: stoneharry • Posted: 2025-03-12T19:46:34.558000+00:00
Original source

with transports I do it like this (all custom script APIs)

```lua
local transport = pUnit:CreateTransport(OBJECT.BoatTransport)
if transport then
transport:EnableMovement(false)
DATA[instanceId].TRANSPORT = transport:GetGUID()
```
So we disable movement on creation of the object.

Then to start movement I simply invoke: `ship:EnableMovement(true)`

And to have it stop at the next scripted checkpoint, I just disable movement again (it has to be a few seconds after movement started)
rektbyfaith
03-12-2025, 07:46 PM #13

Archived author: stoneharry • Posted: 2025-03-12T19:46:34.558000+00:00
Original source

with transports I do it like this (all custom script APIs)

```lua
local transport = pUnit:CreateTransport(OBJECT.BoatTransport)
if transport then
transport:EnableMovement(false)
DATA[instanceId].TRANSPORT = transport:GetGUID()
```
So we disable movement on creation of the object.

Then to start movement I simply invoke: `ship:EnableMovement(true)`

And to have it stop at the next scripted checkpoint, I just disable movement again (it has to be a few seconds after movement started)

rektbyfaith
Administrator
0
03-12-2025, 11:42 PM
#14
Archived author: Xahnder • Posted: 2025-03-12T23:42:39.289000+00:00
Original source

FYI, I just found an example of this in 3.3.5. The Tram in Ulduar. It's a type 11 transport that has a type 1 activation button.
rektbyfaith
03-12-2025, 11:42 PM #14

Archived author: Xahnder • Posted: 2025-03-12T23:42:39.289000+00:00
Original source

FYI, I just found an example of this in 3.3.5. The Tram in Ulduar. It's a type 11 transport that has a type 1 activation button.

rektbyfaith
Administrator
0
03-12-2025, 11:45 PM
#15
Archived author: stoneharry • Posted: 2025-03-12T23:45:40.036000+00:00
Original source

good point
rektbyfaith
03-12-2025, 11:45 PM #15

Archived author: stoneharry • Posted: 2025-03-12T23:45:40.036000+00:00
Original source

good point

rektbyfaith
Administrator
0
03-13-2025, 12:17 PM
#16
Archived author: Xahnder • Posted: 2025-03-13T12:17:57.074000+00:00
Original source

Adding notes for anyone who looks for this. Attached is how my (working) implementation looks. (the text I accidentally cut off in pic one on line 62 is "->GetPauseTime())")
[Image: image.png?ex=690c91f4&is=690b4074&hm=ccf...a1a350446&]

[Image: image.png?ex=690c91f4&is=690b4074&hm=012...180db1f76&]

2025-03-13_07-17-03.mp4
rektbyfaith
03-13-2025, 12:17 PM #16

Archived author: Xahnder • Posted: 2025-03-13T12:17:57.074000+00:00
Original source

Adding notes for anyone who looks for this. Attached is how my (working) implementation looks. (the text I accidentally cut off in pic one on line 62 is "->GetPauseTime())")
[Image: image.png?ex=690c91f4&is=690b4074&hm=ccf...a1a350446&]

[Image: image.png?ex=690c91f4&is=690b4074&hm=012...180db1f76&]

2025-03-13_07-17-03.mp4

rektbyfaith
Administrator
0
07-31-2025, 09:00 PM
#17
Archived author: Travven • Posted: 2025-07-31T21:00:09.657000+00:00
Original source

<@271350028985958408> hello harry, i created a subject with the same problem as this guy, so when i mod the Transsport.dbc and add it to a patch-enUS-4.MPQ, my client crashes
rektbyfaith
07-31-2025, 09:00 PM #17

Archived author: Travven • Posted: 2025-07-31T21:00:09.657000+00:00
Original source

<@271350028985958408> hello harry, i created a subject with the same problem as this guy, so when i mod the Transsport.dbc and add it to a patch-enUS-4.MPQ, my client crashes

rektbyfaith
Administrator
0
07-31-2025, 09:00 PM
#18
Archived author: Travven • Posted: 2025-07-31T21:00:18.646000+00:00
Original source

i was like, WTF
rektbyfaith
07-31-2025, 09:00 PM #18

Archived author: Travven • Posted: 2025-07-31T21:00:18.646000+00:00
Original source

i was like, WTF

rektbyfaith
Administrator
0
07-31-2025, 09:00 PM
#19
Archived author: Travven • Posted: 2025-07-31T21:00:31.158000+00:00
Original source

do i need to make another entrance somewhere??
rektbyfaith
07-31-2025, 09:00 PM #19

Archived author: Travven • Posted: 2025-07-31T21:00:31.158000+00:00
Original source

do i need to make another entrance somewhere??

rektbyfaith
Administrator
0
07-31-2025, 09:00 PM
#20
Archived author: stoneharry • Posted: 2025-07-31T21:00:52.601000+00:00
Original source

start with small edits. Test it little by little. It's very finicky, and some DBCs demand gapless IDs in order for example
rektbyfaith
07-31-2025, 09:00 PM #20

Archived author: stoneharry • Posted: 2025-07-31T21:00:52.601000+00:00
Original source

start with small edits. Test it little by little. It's very finicky, and some DBCs demand gapless IDs in order for example

Pages (3): Previous 1 2 3 Next
Recently Browsing
 1 Guest(s)
Recently Browsing
 1 Guest(s)