You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
kvirc/doc/scriptexamples/widget2.kvs

24 lines
329 B

# a stupid game :) (version 2)
class(mystupidgame,widget)
{
constructor
{
srand $unixTime;
$$->$setCaption(":)");
$$->$setGeometry($rand(770),$rand(570),30,30);
}
mouseEnterEvent
{
$$->$move($rand(770),$rand(570));
}
mousePressEvent
{
echo "You got me!"
delete $$
}
}
%w = $new(mystupidgame,0)
%w->$show()