Welcome to Keen Software House Forums! Log in or Sign up to interact with the KSH community.
  1. You are currently browsing our forum as a guest. Create your own forum account to access all forum functionality.

How to add Scripts to Blocks

Discussion in 'Modding' started by dwarfenhoschi, Nov 8, 2016.

Thread Status:
This last post in this thread was made more than 31 days old.
  1. dwarfenhoschi Trainee Engineer

    Hey Guys!
    I am trying to dabble in modding for ME - however, it seems I fail to do the simplest things - I keep thinking that I kind of understand how it should work, but I feel something eludes me - I also did not find any form of helpful documentation on this.

    I already managed to create new Blocks that can be placed in the game, that part was easy. Next thing that would really help me is how to get a Class to be attached to a Block.
    Here's what I am guessing so far:
    * Script connection works via the "xsi:type=" parameter in the .sbc file. This connects the Script to an "Object Builder" class that takes care of building and configuring the instances.
    * Scripts for Blocks are based on the "MyEntityGameLogic" class, as it seems to have functions and events necessary to do a Block script.
    * I have no idea how these two connect/How the OBject Builder has to be set up to work.

    There's a number of Mods that have functional Blocks so I am supposing I am missing something major here (and/or am too stupid for this) - Any hints?
    Last edited: Nov 8, 2016
  2. Coggernaut Trainee Engineer

    I can help you out, in my signature is a useful guide on modding everything in Medieval Engineers. Though the guide is a work in progress, it does currently explain how to mod tools and put them in-game :)
Thread Status:
This last post in this thread was made more than 31 days old.