Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- Def.ActorProxy {
- Name="BannerProxy";
- BeginCommand=function(self)
- local WF = SCREENMAN:GetTopScreen():GetChild('Banner');
- local CDou, FDou, PGwan;
- -- I don't understand WHY these return 1, but they do.
- -- Maybe this is a StepMania bug?
- -- this returns 1
- CDou = WF:GetWidth();
- -- this also returns 1
- FDou = WF:GetHeight();
- -- this is 1/1 which evaluates to 1!
- PGwan = CDou/FDou;
- -- SCREENMAN:SystemMessage() will print out the values
- -- and is a good means of inspecting variables.
- SCREENMAN:SystemMessage("CDou: " .. CDou .. ", FDou: " .. FDou .. ", PGwan: " .. PGwan);
- -- this will never happen
- if PGwan > 3.17 and PGwan < 3.23 then
- WF:scaletoclipped(256,80);
- -- this will also never happen
- elseif PGwan > 2.53 and PGwan < 2.59 then
- WF:scaletoclipped(204.8,80);
- -- this will always happen
- else
- WF:scaletoclipped((256,80);
- end;
- self:SetTarget(WF);
- end;
- };
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement