Simple usage of maniascript for Controller plugins:

You can talk about ManiaScript for ManiaPlanet here

Moderator: English Moderator

Post Reply
User avatar
kapsubm
Posts: 238
Joined: 16 Aug 2011, 23:38
Location: Vienna, Austria
Contact:

Simple usage of maniascript for Controller plugins:

Post by kapsubm »

As i used a little maniscript for my teamspeak plugin , here now some lines of code to get a frame movin by mouseover:

For questions , just ask.

Code: Select all

[code]<?xml version="1.0" encoding="utf-8" standalone="yes" ?>
<manialink version="1" background="0">
<frame id="294"  posn="138 40" sizen = "120 8" scale="0.8"  >
<timeout>0</timeout>
<quad id="295" posn="0 0 1" sizen="160 8"  ScriptEvents="1" />
<quad posn="0 0 3"  image="http://www.teamspeak.com/media_repository/files/mediakit/buttons/button02_100x45.jpg" sizen="28 9" />
<script><!--
declare teamspeak = (Page.GetFirstChild("294") as CGameManialinkFrame);
while(True) {
yield;
foreach(Event in PendingEvents)
{    if(Event.Type == CGameManialinkScriptEvent::Type::MouseOver) {
     if(Event.ControlId == "295")
  { for (a , 0 , 39) { declare f=teamspeak.PosnX; if (f>=60){ teamspeak.PosnX += -2; sleep(1); } } } }
    else if(Event.Type == CGameManialinkScriptEvent::Type::MouseOut) {
if(Event.ControlId == "295")
    { teamspeak.PosnX += 80;} } } }--></script>

</frame>
</manialink>
Join CSeSports Platform Server

[url=maniaplanet://:maniaplanet://#join=cs.esports@Platform@nadeolive]CS.eSportsPlatform 0-60K With Fox Control[/url]
[url=maniaplanet://:maniaplanet://#join=csesports2@SMStorm]CS.eSports SM Royal 0-60 k 40 players With Smart Servercontroller[/url]
[url=maniaplanet://:maniaplanet://#join=cs.esports1@TMCanyon]CS.eSports Stunts in Canyon with Smart Servercontroller[/url]
Post Reply

Return to “ManiaScript”

Who is online

Users browsing this forum: No registered users and 1 guest