msw-ai-tf/maplestory-worlds-creator-docs huggingface dataset:
SpotTypeOverlayLightInfo

The information about a Spot-type light source that will spawn in the map.

# Properties

[{"index":"Color Color","0":"The color of the light source."}]

[{"index":"float FalloffIntensity","0":"Controls the softness of the curves when the light source starts to disappear. The larger the value, the more blurred and softer the edge looks. The smaller the value, the sharper and clearer the edge looks."}]

[{"index":"float InnerRadius","0":"The radius of the internal light source area that has the max brightness if the light source is a Spot-type. It can't be larger than the OuterRadius value."}]

[{"index":"Entity Instigator","0":"An entity that belongs to the map where a light source will be added."}]

[{"index":"float Intensity","0":"The intensity of the light source."}]

[{"index":"float Lifetime","0":"The amount of time the light source will display. The created light source will automatically disappear upon reaching the specified time. However, when a value equal to or lower than 0 is input, the light source will remain indefinitely."}]

[{"index":"int32 LightOrder","0":"Determines the rendering order of a light source light texture. The light source with a smaller number will be rendered first, and then, the larger number light source will be rendered on top. Operates when OverlapOperation is set to AlphaBlend. Global-type light sources don't have LightOrder as an exception."}]

[{"index":"float OuterRadius","0":"The outer range that determines the radius of a Spot-type light source. The light will begin to get weaker from the end of the InnerRadius, and the light strength will be 0% when it reaches the radius."}]

[{"index":"OverlayLightOverlapOperation OverlapOperation","0":"How to calculate a light source. Global-type light sources don't have OverlapOperation."}]

[{"index":"float SpotInnerAngle","0":"The inner angle of a Spot-type light source. The wider the angle, the larger the interval. All of the pixels have 100% of the light intensity applied to them. It can't be larger than the SpotOuterAngle value."}]

[{"index":"float SpotOuterAngle","0":"The outer angle of a Spot-type light source. The larger the value, the wider the angle. The light will begin to get weaker from the end of the SpotInnerAngle, and the light strength will be 0% when it reaches the SpotOuterAngle."}]

[{"index":"Vector3 WorldPosition","0":"The world's spacial coordinates for the light source."}]

[{"index":"float WorldZRotation","0":"The world's spatial z-axis-based rotation value for where the light source will be applied."}]

# Constructors

[{"index":"SpotTypeOverlayLightInfo(Entity instigator)","0":"Applies SpotTypeOverlayLightInfo with the specified value."}]

[{"index":"SpotTypeOverlayLightInfo(Entity instigator, float lifetime, Vector3 worldPosition, float worldZRotation, Color color, float intensity, OverlayLightOverlapOperation overlapOperation, int32 lightOrder, float innerRadius, float outerRadius, float spotInnerAngle, float spotOuterAngle, float falloffIntensity)","0":"Initializes SpotTypeOverlayLightInfo to the specified value."}]
AttachedSpotTypeOverlayLightInfo

The Spot-type light source information that will spawn as a child of an entity.

# Properties

[{"index":"Color Color","0":"The color of the light source."}]

[{"index":"float FalloffIntensity","0":"Controls the softness of the curves when the light source starts to disappear. The larger the value, the more blurred and softer the edge looks. The smaller the value, the sharper and clearer the edge looks."}]

[{"index":"float InnerRadius","0":"The radius of the internal light source area that has the max brightness if the light source is a Spot-type. It can't be larger than the OuterRadius value."}]

[{"index":"float Intensity","0":"The intensity of the light source."}]

[{"index":"float Lifetime","0":"The amount of time the light source will display. The created light source will automatically disappear upon reaching the specified time. However, when a value equal to or lower than 0 is input, the light source will remain indefinitely."}]

[{"index":"int32 LightOrder","0":"Determines the rendering order of a light source light texture. The light source with a smaller number will be rendered first, and then, the larger number light source will be rendered on top. Operates when OverlapOperation is set to AlphaBlend. Global-type light sources don't have LightOrder as an exception."}]

[{"index":"Vector3 LocalPosition","0":"The parent entity's spatial coordinates for where the light source will be placed."}]

[{"index":"float LocalZRotation","0":"The parent entity's spatial z-axis-based rotation value for where the light source will be applied."}]

[{"index":"float OuterRadius","0":"The outer range that determines the radius of a light source. The light will begin to get weaker from the end of the InnerRadius, and the light strength will be 0% when it reaches the radius."}]

[{"index":"OverlayLightOverlapOperation OverlapOperation","0":"How to calculate a light source. Global-type light sources don't have OverlapOperation."}]

[{"index":"Entity ParentEntity","0":"An entity that will have a created light source added to it."}]

[{"index":"float SpotInnerAngle","0":"The inner angle of a Spot-type light source. The wider the angle, the larger the interval. All of the pixels have 100% of the light intensity applied to them. It can't be larger than the SpotOuterAngle value."}]

[{"index":"float SpotOuterAngle","0":"The outer angle of a Spot-type light source. The larger the value, the wider the angle. The light will begin to get weaker from the end of the SpotInnerAngle, and the light strength will be 0% when it reaches the SpotOuterAngle."}]

# Constructors

[{"index":"AttachedSpotTypeOverlayLightInfo(Entity parentEntity)","0":"Initializes AttachedSpotTypeOverlayLightInfo to the specified value."}]

[{"index":"AttachedSpotTypeOverlayLightInfo(Entity parentEntity, float lifetime, Vector3 localPosition, float localZRotation, Color color, float intensity, OverlayLightOverlapOperation overlapOperation, int32 lightOrder, float innerRadius, float outerRadius, float spotInnerAngle, float spotOuterAngle, float falloffIntensity)","0":"Initializes AttachedSpotTypeOverlayLightInfo to the specified value."}]
Wigs

# Course Introduction

Here is the production sheet for wigs. First, please refer to the [Basics of Creating Avatar Items](/docs?postId=588%7B%22target%22:%22_self%22%7D) to understand the basic concept of avatars.

# Preparation

Adobe Photoshop is required to produce items. Install the software and then download and open the file below. $$attachFile {"name":"Avatar_Cap_D.psd","url":"https://mod-file.dn.nexoncdn.co.kr/storage/Avatar_psd/version4_230221/Avatar_Cap_D.psd"} $$

> Tip We recommend making caps within 120 x 120 pixels based on the avatar's feet. [png](16769485559327fc72cf03aca4128998b423540c3e049)

# Production Sheet Description

The cap sheet is divided into gray, yellow, and red layers. The gray layer has a data folder for image datafication, an avatar body layer to help with the image creation, and a line layer for guidance. All gray layers are locked, and no modifications are required while working. The creator can draw the actual item on the yellow layer. The red layer determines the priority between the cap and the hair.

> Tip If you edit or delete the names of layers, you will not be able to register the item. Never change the layer names.

### Gray Layer/Red Layer

  1. data folder: A data folder is required for the datafication of items. It does not affect image production. 
     * data:origin: This marks the center of the data with a red dot.
     * data:type:Cap: This indicates the data type.
     * data:use_zmap_preset1: The images that form an avatar are produced by being piled in layers. The structure is to pile the images of clothes, shields, and weapons in layers in a sequence based on the avatar's body to produce the avatar's various movements.  
Zmap is a file wherein the heights of each sprite, separated by items, are organized in order.
  2. guide_layer: This is an avatar's sample body. The internal rule is that the bigger the number attached after the layer name, it places below.
  3. (Red layer) data:vslot:CpH1H2H3H4H5H6HfHsHbHc: The red layer is a concept only for hats. The vslot layer in a hat file plays a role in determining whether hair or hat takes priority when the two overlap. [png](1677033750714bee6e496b432440aa917a6c4fceeb4ca)



### Yellow Layer

The creator draws the actual wig on the yellow layer.

  1. case1.front: This contains a layer to draw the front of the wig and front view samples of normal hair and pressed hair. 
     * edithere:cap_cap_34: This layer lets you draw the front of the wig.
  2. case2.back: This contains a layer to draw the back of the wig and back view samples of normal hair and pressed hair. 
     * edithere:cap_backCap_92: This layer lets you draw the back of the wig. [png](16770337662241601c8da5b484bb2b9fa358959c05109)
AI ToolKit

You can create worlds using simple commands by activating the AI ToolKit function provided by MapleStory Worlds. Before using the AI ToolKit, you must make the proper preparations and subscribe to a separate AI agent.

## Local Workspace

You must use the local workpace and ExtendedScriptFormat to use the AI ToolKit. Refer to the [LocalWorkspace](docs/?postId=1165) guide to learn more about the local workspace. The AI ToolKit functions normally only when the local workspace, MCP server, and AI skill set tabs are completely set-up from AI ToolKit Settings.

  1. Create a new world with Create - Create World with AI or Create - Create new - AI Starter Template.

[{"index":"Create Button","0":"[png](1779353818776a4e26c18fe634009b6bd3a55217be287)"},{"index":"AI Starter Template","0":"[png](1779360155464759176e069e043bca3fa9e92b8508d45)"}]

  2. Press the AI Settings button or AI Lab - AI ToolKit Settings.

[{"index":"Pop-Up Button","0":"[png](1779360182729fc2acf1c4c074f99bc8c4ed9bdb2b227)"},{"index":"AI Lab Menu","0":"[png](17793602054810da48bfe35224bd78d283600f24f95bb)"},{"index":"Go Now Button","0":"[png](1779777266102597ce420134c4be0bd81ea5c1685c9a6)"}]

  3. Select Local Workspace - Use Local Workspace and select where the world will be saved to.

  4. Activate ExtendedScriptFormat. [png](1779360408062d9f1bdac22ee407bbd9aec2d2b9127a6)




## MCP Server

Reference [MSW MCP](docs/?postId=1368) to learn how to link an MCP and how to issue API Keys.

[png](17793538693200c3c7c3841554cd7bc055b4ba8016b3e)

  1. Activate MSW Maker MCP use from the MCP server tab.
  2. Press the [Link] button for the AI agent the creator will use.



## AI Skill Set

Select and link the AI tool that will be used to write or edit the world file from the [AI Skill Set](/docs?postId=1373%7B%22target%22:%22_blank%22%7D) tab. Press the [Link] button to automatically install the desired item. Please refer to the guide above for more details.

[png](1779353961022eea460b339094bacb87673bcea67a3cb)

> Tip The update button will be active if the AI agent needs to be updated. 

## Starting AI

You can open the linked AI agent from the Start AI tab. [png](17793539806115b82f93f24274604b3e41e788e7cf514)

> Tip You can easily start Claude Code CLI with the Go To button on the top right of the maker once linked. [png](177935399435730396d6c7abf497fb1ff7cb5f9451248)
Set Background

# Course Introduction

Let's set up the map's background using Preset List and BackgroundComponent.

# Setting a Template Background

You can select various backgrounds of MapleStory from Preset List - Background. [png](1660872151969aea4b5e0f90c4c2ab1c556a2ea900127)

After selecting a preset background, you can adjust the speed at which it moves (i.e. ScrollRate). [png](1676524214491fd465cd70f484b7baa55a9c7cceb1a78)

The higher the ScrollRate value, the faster the background will move. A negative ScrollRate will cause the background to move in the opposite direction.

[{"ScrollRate":"1","Image":"[gif](1676524614371f682d76a305e4987aa04507430a3f891)"},{"ScrollRate":"10","Image":"[gif](1676524628557d5e56dce60f74ab59a962793a594b408)"},{"ScrollRate":"-10","Image":"[gif](16765246400798c2f36ddf63a47bc92883f9d493b22d6)"}]

# Setting Solid Background

You can set a solid background from Preset List - Solid Background. [png](1660872533050bd027ce1934b47669a0f3d3f82994180)

If you want to set different colors from those provided as presets, press the [+] button to open the color selector and set the color you want. [png](1660872694830338c5a59114a46aa9d41eeecbfae1203)

# Setting a Gradient Background

Select Hierarchy - Current Map - Background and change Type to Gradient in BackgroundComponent of the Property Editor to set a gradient background. [png](1675686701848d25aebc9b2b645519a894cb17489b07a) Select the top, middle top, middle bottom, and bottom colors for gradation from the color palette. In addition, use the MiddleTopRatio, MiddleBottomRatio properties to decide where to place the middle top and middle bottom colors. Likewise, you can easily create a gradient background in the desired style by using Gradient Type.

# Setting Image Background

## Setting the Background with a Saved Image

In Preset List - Image Background, you can set the background using an image you have saved. [png](166242041253011d9fd857ab84531a074ed6982123704)

## Setting Web Image Background

You can set images from the web as the background.

  1. Copy the image link that you want to set as the background. [png](1662420478272932b474fef2c4e7589e49f76d4ce4b4f)   

  2. After setting the Type of BackgroundComponent to Web, paste the copied address into WebURL. [png](1662419129189d4b5d5fb2028458baa10f740ecfbac45)   

  3. Let's press  Start and test. You can see that the image on the web has been set as the background as below. [gif](166241921017719b68e8cb4674133892283180eb6a3e2)
Localized Entity

# Course Introduction

Let's learn about localized entities that are only created in the client.

##### Reference Guide

[Server and Client](/docs?postId=207%7B%22target%22:%22_blank%22%7D) [Server Verification Example](/docs?postId=1084%7B%22target%22:%22_blank%22%7D) [Preparation for Packet Modulation](/docs?postId=1102%7B%22target%22:%22_blank%22%7D) [Effective MSW 2](/docs/?postId=560%7B%22target%22:%22_blank%22%7D)

# Localized Entities

A Localized Entity indicates entities that are only created in the client. In the Hierarchy window, it is displayed as an entity marked with [png](1744353390721e6e7eb37353d4042aabf7d24c432ba27). Entities in MapleStory Worlds are created in both the server and client by default. This is to help with easy multiplayer working and creating. However, the more the created entities on the server, the more load the server needs to handle. If an entity doesn't need to be managed by the server, it can be created as a Localized Entity that is only created in the client. By localizing entities or data used as decorative elements for a world that don't have to be saved, less communication is required between the server and client for sychronization, making a more efficient world.

When using Localized Entities, you must keep 4 things in mind.

  1. They are affected by Parent-Child relationships. Changing a parent entity to a localized entity will also change all of its child entities as well.
  2. Server Execution Control Functions can't be used.
  3. Since verification can't be done from the server, they are succeptible to falsification and hacking. Entities that play a crucial role in the world's ecosystem should not be localized entities.
  4. The PortalComponent is unavailable for localized entities. Also some of the functions in components that use server functions may not run as intended.



# Creating Localized Entities

There are 3 ways to use default entities that synchronize with the server as localized entities.

#### Activating the Localize Property

You can localize entites with the Localize property. This property can only be activated in entities below world. When this function is activated, entities will only be created in the client, even when they are placed directly in Scene. Activates `Localize` from Property Window - Model Property for entities placed under Hierarchy - World - maps. [png](174433695073900c80e0cc0604735bd090b707991c89b)

#### Create as UI Entity

UI Entities created in ui - UI Group can only be created in the client. UI Entities have no Localize property in the Property Editor window, since the default value is localized. [png](1744354007080d2ad5568bf8c4085889573254f82f4ea)

#### Create a Dynamic Using SpawnService

You can create Localized Entities with dynamics by calling `SpawnService` in the client space. When creating entities using dynamics, you must call SpawnService an equal number of times as the number of entities that will be created. This may decrease world creation efficiency, so it's recommended that you only use it when needed.
Hoods

# Course Introduction

Here is the production sheet for hoods. First, please refer to the [Basics of Creating Avatar Items](/docs?postId=588%7B%22target%22:%22_self%22%7D) to understand the basic concept of avatars.

# Preparation

Adobe Photoshop is required to produce items. Install the software and then download and open the file below. $$attachFile {"name":"Avatar_Cap_G.psd","url":"https://mod-file.dn.nexoncdn.co.kr/storage/Avatar_psd/version4_230221/Avatar_Cap_G.psd"} $$

> Tip We recommend making caps within 120 x 120 pixels based on the avatar's feet. [png](16769485559327fc72cf03aca4128998b423540c3e049)

# Production Sheet Description

The cap sheet is divided into gray, yellow, and red layers. The gray layer has a data folder for image datafication, an avatar body layer to help with the image creation, and a line layer for guidance. All gray layers are locked, and no modifications are required while working. The creator can draw the actual items in the yellow layer. The red layer determines the priority between the cap and the hair.

> Tip If you edit or delete the names of layers, you will not be able to register the item. Never change the layer names.

### Gray Layer/Red Layer

  1. data folder: A data folder is required for the datafication of items. It does not affect image production. 
     * data:origin: This marks the center of the data with a red dot.
     * data:type:Cap: This indicates the data type.
     * data:use_zmap_preset1: The images that form an avatar are produced by being piled in layers. The structure is to pile the images of clothes, shields, and weapons in layers in a sequence based on the avatar's body to produce the avatar's various movements.  
Zmap is a file wherein the heights of each sprite, separated by items, are organized in order.
  2. guide_layer: This is an avatar's sample body. The internal rule is that the bigger the number attached after the layer name, it places below.  

  3. (Red layer) data:vslot:CpH1H3H4H5H6HfHbHcAe: The red layer is a concept only for hats. The vslot layer in a hat file determines the priority of when to show the hair or hat when the two overlap.. [png](16770341216345bee47ec320b47038b44a99935ece7a2)



### Yellow Layer

The creator can draw hoods that the creator wants to produce in the yellow layer.

  1. case1.front: This contains a layer to draw the front view of the hood and front-view samples of normal hair and pressed hair. 
     * edithere:cap_cap_34: This layer lets you draw the front view of the hood.
  2. case2.back: This contains a layer to draw the back view of the hood and back-view samples of normal hair and pressed hair. 
     * edithere:cap_backCap_92: This layer lets you draw the back view of the hood. [png](1677034101578d0917d0379e545b2b4bf30612376cdbf)
SpawnService

Provides functions related to spawning entities.

# Methods

[{"index":"Entity Clone(string name, Entity original, Entity parent = nil, boolean posOffset = true, boolean dynamic = true) (Deprecated)","0":"This function is now deprecated. Use the SpawnByEntity (Entity, string, Vector3, Entity, boolean) function."}]

[{"index":"Entity SpawnByEntity(Entity entity, string name, Vector3 spawnPosition, Entity parent = nil, boolean includeChild = true)","0":"Spawns a new entity based on the entity. The name will be the name of an entity being spawned. The spawnPosition is the location. The parent is the parent entity. If it's nil, the entity's parent entity will be set up as a parent. If includeChild is false, the entity's child entity will not be spawned."}]

[{"index":"Entity SpawnByEntityTemplate(Entity entityTemplate, string name, Vector3 spawnPosition, boolean includeChild = true, boolean dynamic = true, boolean needSync = true, boolean nameEditable = true) (Deprecated)","0":"This function is now deprecated. Use the SpawnByEntity (Entity, string, Vector3, Entity, boolean) function."}]

[{"index":"Entity SpawnByModelId(string id, string name, Vector3 spawnPosition, Entity parent)","0":"Spawns a new entity based on the model corresponding to the id. The name is the name of the model to spawn, the spawnPosition is the location, and the parent is the parent entity."}]

[{"index":"Entity SpawnByModelId(string id, string name, Vector3 spawnPosition, Entity parent, string ownerId, boolean dynamic = true, boolean needSync = true, boolean nameEditable = true) (Deprecated)","0":"This function is now deprecated. Use the SpawnByModelId (string, string, Vector3, Entity) function."}]

##### inherited from Service:

[{"index":"EventHandlerBase ConnectEvent(string key, IScriptFunction eventHandler)","0":"Links events. When a key-type event occurs in this service, a handler is notified. The handler receives event parameters."}]

[{"index":"EventHandlerBase ConnectEvent(Type eventType, IScriptFunction eventHandler)","0":"Links events. This service notifies a handler when an eventType event occurs. The handler receives event parameters."}]

[{"index":"boolean DisconnectEvent(string key, EventHandlerBase eventHandler)","0":"Disconnects the event with the key-type event and the handler."}]

[{"index":"boolean DisconnectEvent(Type eventType, EventHandlerBase eventHandler)","0":"Disconnects the eventType event from its handler."}]

[{"index":"void SendEvent(EventType sendEvent)","0":"Generates an event."}]

# Examples

The following is an example of duplicating an Entity and spawning a model as a child Entity of the duplicated Entity.
    
    
    @Component
    script HierarchicalSpawner extends Component
        @ExecSpace("ServerOnly")
        method void OnBeginPlay()
        local entity = _EntityService:GetEntityByPath("Entity Path")
        local clone1 = _SpawnService:SpawnByEntity(entity, "clone1", Vector3(1, 0, 0))
    
        local modelId = "Model Entry Id"
        local clone2 = _SpawnService:SpawnByModelId(modelId, "clone2", Vector3(0, 1, 0), clone1)
        end
    end
    

# SeeAlso

  * EntityService