give rain constructor class like actionscript