SHARE
TWEET

Untitled

a guest May 19th, 2019 77 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1.    
  2. using Microsoft.Xna.Framework;
  3. using Terraria;
  4. using Terraria.ID;
  5. using Terraria.ModLoader;
  6. using Terraria.ObjectData;
  7.  
  8. namespace upsector.Tiles
  9. {
  10.     public class workStation : ModTile
  11.     {
  12.         public override void SetDefaults() {
  13.             Main.tileSolidTop[Type] = true;
  14.             Main.tileFrameImportant[Type] = true;
  15.             Main.tileNoAttach[Type] = true;
  16.             Main.tileTable[Type] = true;
  17.             Main.tileLavaDeath[Type] = true;
  18.             TileObjectData.newTile.CopyFrom(TileObjectData.Style5x4);
  19.             TileObjectData.newTile.CoordinateHeights = new[] { 80 };
  20.             TileObjectData.addTile(Type);
  21.             AddToArray(ref TileID.Sets.RoomNeeds.CountsAsTable);
  22.             ModTranslation name = CreateMapEntryName();
  23.             name.SetDefault("Work Station");
  24.             AddMapEntry(new Color(200, 200, 200), name);
  25.             dustType = DustID.Dirt;
  26.             disableSmartCursor = true;
  27.             adjTiles = new int[] { TileID.WorkBenches };
  28.         }
  29.  
  30.         public override void NumDust(int i, int j, bool fail, ref int num) {
  31.             num = fail ? 1 : 3;
  32.         }
  33.  
  34.         public override void KillMultiTile(int i, int j, int frameX, int frameY) {
  35.             Item.NewItem(i * 16, j * 16, 16*5, 16*4, mod.ItemType("workStation"));
  36.         }
  37.     }
  38. }
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top