Line 133: |
Line 133: |
| | | |
| If you're using SMAPI: | | If you're using SMAPI: |
− | :<source lang="C#"> | + | :<syntaxhighlight lang="C#"> |
| public override void Entry(IModHelper helper) | | public override void Entry(IModHelper helper) |
| { | | { |
Line 149: |
Line 149: |
| Game1.locations.Add(location); | | Game1.locations.Add(location); |
| } | | } |
− | </source> | + | </syntaxhighlight> |
| | | |
| : '''Note:''' | | : '''Note:''' |
Line 162: |
Line 162: |
| | | |
| If you're using SMAPI: | | If you're using SMAPI: |
− | :<source lang="c#"> | + | :<syntaxhighlight lang="c#"> |
| public override void Entry(IModHelper helper) | | public override void Entry(IModHelper helper) |
| { | | { |
Line 188: |
Line 188: |
| location.map.LoadTileSheets(Game1.mapDisplayDevice); | | location.map.LoadTileSheets(Game1.mapDisplayDevice); |
| } | | } |
− | </source> | + | </syntaxhighlight> |
| : To change tiles using the new tilesheet, see [[#Tiles]] below. | | : To change tiles using the new tilesheet, see [[#Tiles]] below. |
| | | |
Line 210: |
Line 210: |
| | | |
| If you're using SMAPI: | | If you're using SMAPI: |
− | : <source lang="c#"> | + | : <syntaxhighlight lang="c#"> |
| public override void Entry(IModHelper helper) | | public override void Entry(IModHelper helper) |
| { | | { |
Line 229: |
Line 229: |
| Game1.currentLocation.map.Properties.Remove("Music"); | | Game1.currentLocation.map.Properties.Remove("Music"); |
| } | | } |
− | </source> | + | </syntaxhighlight> |
| | | |
| If you're using Tiled: | | If you're using Tiled: |
Line 239: |
Line 239: |
| | | |
| If you're using SMAPI: | | If you're using SMAPI: |
− | : <source lang="C#"> | + | : <syntaxhighlight lang="C#"> |
| public override void Entry(IModHelper helper) | | public override void Entry(IModHelper helper) |
| { | | { |
Line 264: |
Line 264: |
| //tile.TileIndexProperties.Remove("Diggable"); // NOTE: removing a tile index property will affect all tiles of this type | | //tile.TileIndexProperties.Remove("Diggable"); // NOTE: removing a tile index property will affect all tiles of this type |
| } | | } |
− | </source> | + | </syntaxhighlight> |
| | | |
| If you're using Tiled: | | If you're using Tiled: |
Line 289: |
Line 289: |
| | | |
| If you're using SMAPI: | | If you're using SMAPI: |
− | :<source lang="c#"> | + | :<syntaxhighlight lang="c#"> |
| public override void Entry(IModHelper helper) | | public override void Entry(IModHelper helper) |
| { | | { |
Line 313: |
Line 313: |
| location.waterTiles[tileX, tileY] = false; // true: water, false: not water | | location.waterTiles[tileX, tileY] = false; // true: water, false: not water |
| } | | } |
− | </source> | + | </syntaxhighlight> |
| | | |
| If you're using Tiled: | | If you're using Tiled: |
Line 323: |
Line 323: |
| | | |
| If you're using SMAPI: | | If you're using SMAPI: |
− | :<source lang="c#"> | + | :<syntaxhighlight lang="c#"> |
| public override void Entry(IModHelper helper) | | public override void Entry(IModHelper helper) |
| { | | { |
Line 347: |
Line 347: |
| ); | | ); |
| } | | } |
− | </source> | + | </syntaxhighlight> |
| | | |
| If you're using Tiled: | | If you're using Tiled: |
Line 364: |
Line 364: |
| | | |
| If you're using SMAPI: | | If you're using SMAPI: |
− | :<source lang="c#"> | + | :<syntaxhighlight lang="c#"> |
| public override void Entry(IModHelper helper) | | public override void Entry(IModHelper helper) |
| { | | { |
Line 383: |
Line 383: |
| tile.Properties["@Flip"] = 1; | | tile.Properties["@Flip"] = 1; |
| } | | } |
− | </source> | + | </syntaxhighlight> |
| | | |
| If you're using Tiled: | | If you're using Tiled: |