优化座驾特效入场标题

This commit is contained in:
pllx
2026-04-30 10:29:11 +08:00
parent 18acd7d890
commit 221f629ec2
12 changed files with 91 additions and 41 deletions
+6
View File
@@ -39,6 +39,8 @@ class EffectBroadcast implements ShouldBroadcastNow
* @param string $operator 触发特效的用户名(购买者)
* @param string|null $targetUsername 接收者用户名(null = 全员)
* @param string|null $giftMessage 附带赠言
* @param string|null $effectTitle 特效画面标题
* @param string|null $rideName 座驾名称
*/
public function __construct(
public readonly int $roomId,
@@ -46,6 +48,8 @@ class EffectBroadcast implements ShouldBroadcastNow
public readonly string $operator,
public readonly ?string $targetUsername = null,
public readonly ?string $giftMessage = null,
public readonly ?string $effectTitle = null,
public readonly ?string $rideName = null,
) {}
/**
@@ -73,6 +77,8 @@ class EffectBroadcast implements ShouldBroadcastNow
'operator' => $this->operator,
'target_username' => $this->targetUsername, // null = 全员
'gift_message' => $this->giftMessage,
'effect_title' => $this->effectTitle,
'ride_name' => $this->rideName,
];
}
}