# Proper way of using linkage..?

**URL:** <https://forum.kirupa.com/t/proper-way-of-using-linkage/235810>\
**Category:** flash\
**Created:** [August 14, 2007, 10:00pm UTC](https://forum.kirupa.com/t/proper-way-of-using-linkage/235810 "2007-08-14T22:00:12Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![JD77](https://avatars.discourse-cdn.com/v4/letter/j/e56c9b/32.png) [@JD77](https://forum.kirupa.com/u/JD77)\
**Post date:** [August 14, 2007, 10:00pm UTC](https://forum.kirupa.com/t/proper-way-of-using-linkage/235810/1 "2007-08-14T22:00:12Z")

</div>

```php
    
           this["EN"+E] = new ENE1();
            this.addChild(this["EN"+E]);
            this["EN"+E].visible = false;
            this["EN"+E].M = new Matrix(1, 0, 0, 1, 0, 0);
            this["EN"+E].M.tx = mouseX;
            this["EN"+E].M.ty = mouseY;
            this["EN"+E].C = new Matrix(1, 0, 0, 1, 0, 0);
            this["EN"+E].C.tx = PCAM.tx;
            this["EN"+E].C.ty = PCAM.ty;
            this["EN"+E].DEL2 = true;
            this["EN"+E].INROT = 0;
            this["EN"+E].ANGLE = 0;
            this["EN"+E].SPD = 5;
            this["EN"+E].IN.rotation = this["EN"+E].INROT;
            this["EN" + E].addEventListener(Event.ENTER_FRAME, ENEMOVE);

```

How could i make that work in “faster” way i.e. using a class and stuff.

ENE1 is the linkage of a movieclip in the library. plus how can i delete the object i made with event.target via the EventListerner.
