# Am I writing this class right? Need Help with OOP Plz

**URL:** <https://forum.kirupa.com/t/am-i-writing-this-class-right-need-help-with-oop-plz/245576>\
**Category:** flash\
**Created:** [December 1, 2007, 5:12am UTC](https://forum.kirupa.com/t/am-i-writing-this-class-right-need-help-with-oop-plz/245576 "2007-12-01T05:12:35Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![combustion007](https://avatars.discourse-cdn.com/v4/letter/c/f9ae1b/32.png) [@combustion007](https://forum.kirupa.com/u/combustion007)\
**Post date:** [December 1, 2007, 5:12am UTC](https://forum.kirupa.com/t/am-i-writing-this-class-right-need-help-with-oop-plz/245576/1 "2007-12-01T05:12:35Z")

</div>

cheers,

I am getting my feet wet with OOP and wrote this class but am not sure if it is right and if the constructor is written right. Appreciate your help…thx

```php

public class PlayVideo{

var vid_arr:Array = new Array();

public static function PlayVideo()

   {

    var net_nc:NetConnection = new NetConnection();
    net_nc.connect(null);
    var stream_ns:NetStream = new NetStream(net_nc);
    my_video.attach(stream_ns);
    stream_ns.play(vid_arr);

   }
}

var myMoive:PlayVideo = new PlayVideo();

```
