# How to affect all players in the map (Verse)

**URL:** <https://forums.unrealengine.com/t/how-to-affect-all-players-in-the-map-verse/1240891>\
**Category:** Verse\
**Tags:** unreal-editor-for-fortnite, fortnite-creative, question, fortnite\
**Created:** [July 26, 2023, 5:41pm UTC](https://forums.unrealengine.com/t/how-to-affect-all-players-in-the-map-verse/1240891 "2023-07-26T17:41:55Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![LyssaSugarNya](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/lyssasugarnya/32/722321_2.png) [@LyssaSugarNya](https://forums.unrealengine.com/u/LyssaSugarNya)\
**Post date:** [July 26, 2023, 5:41pm UTC](https://forums.unrealengine.com/t/how-to-affect-all-players-in-the-map-verse/1240891/1 "2023-07-26T17:41:55Z")

</div>

Hello, I just learned a bit of verse from the documentation and I just made a button which gives health to the player who presses it (I’ve attached screenshot of the code below). Now, my question is… how do I make the button give health to everyone on the island when the button is pressed?  
I would appreciate any answers or suggestions because it would help me a lot. Thanks.

 ![image](https://d3kjluh73b9h9o.cloudfront.net/original/4X/4/1/1/411498a63df86475d9186e7966556c55f5690d9f.png)

---

<div class="post-metadata">

**Author:** ![ManualPotato](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/manualpotato/32/1144902_2.png) [@ManualPotato](https://forums.unrealengine.com/u/ManualPotato)\
**Post date:** [July 26, 2023, 6:24pm UTC](https://forums.unrealengine.com/t/how-to-affect-all-players-in-the-map-verse/1240891/2 "2023-07-26T18:24:15Z")

</div>

Hi, Assuming you don’t have reference to all your players somewhere else, that could be done by getting the players from the `fort_playspace`. Here’s a quick snippet showing how:

```auto
using { /Fortnite.com/Devices }
using { /Fortnite.com/Characters }
using { /UnrealEngine.com/Temporary/Diagnostics }

test_device := class(creative_device):

    HealAllPlayers(HealAmount: float):void=

        Playspace := GetPlayspace()
        
        for (Agent : Playspace.GetPlayers(), FortCharacter := Agent.GetFortCharacter[]):
            
            FortCharacter.Heal(HealAmount)

```

---

<div class="post-metadata">

**Author:** ![LyssaSugarNya](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/lyssasugarnya/32/722321_2.png) [@LyssaSugarNya](https://forums.unrealengine.com/u/LyssaSugarNya)\
**Post date:** [July 26, 2023, 6:34pm UTC](https://forums.unrealengine.com/t/how-to-affect-all-players-in-the-map-verse/1240891/3 "2023-07-26T18:34:45Z")

</div>

Thank you sm for taking the time to answer my question. It’s been a great help

---

<div class="post-metadata">

**Author:** ![system](https://d3kjluh73b9h9o.cloudfront.net/original/4X/7/1/3/713c9d3f58553f0de89543d76a8a3a2779dc9fa4.png) [@system](https://forums.unrealengine.com/u/system)\
**Post date:** [August 25, 2023, 6:34pm UTC](https://forums.unrealengine.com/t/how-to-affect-all-players-in-the-map-verse/1240891/4 "2023-08-25T18:34:46Z")

</div>

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.
