PDA

View Full Version : [Visual] Freeform Combo Transparency



Majora
04-12-2014, 05:09 PM
Is gone. I have some 2x2 tile FFCs and the transparent pixels are black.

XMuppetSB
04-12-2014, 07:43 PM
I tested this in 2.50.1RC2 and I'm not seeing this. Would you mind posting a test quest?

Majora
04-13-2014, 11:59 AM
I'll get a test quest later but in the meantime,
https://www.dropbox.com/s/fjn513ae85mn3pm/zelda007.png

https://www.dropbox.com/s/nrd0bgce7ceig0s/zelda008.png

It might have something to do with the script I have on those rocks so here it is:


//Moosh's Large Push Block Script V1.0//D0: Set this to 1 if you want the block to only be pushable once
//D1: Push directions:
// 0=Up
// 1=Down
// 2=Left
// 3=Right
// 4=Vertical
// 5=Horizontal
// 6=4-Way
//D2: Set this to 1 if you want the block to trigger a temporary secret
// Set this to 2 if you want the block to trigger a permanent secret
//D3: If you want the push block to require an item to use, set this to the ID # of the item
//Set the screen's under combo for the under combo the block uses
//Be sure to check the quest rule that makes FFCs visible while the screen is scrolling
ffc script BigPush{
bool CanWalkFlag(int flag, int x, int y, int dir, int step, bool full_tile) {
int c=8;
int xx = x+15;
int yy = y+15;
if(full_tile) c=0;
if(dir==0) return !(Screen->ComboF[ComboAt(x,y+c-step)]==flag||Screen->ComboF[ComboAt(x+8,y+c-step)]==flag||Screen->ComboF[ComboAt(xx,y+c-step)]==flag);
else if(dir==1) return !(Screen->ComboF[ComboAt(x,yy+step)]==flag||Screen->ComboF[ComboAt(x+8,yy+step)]==flag||Screen->ComboF[ComboAt(xx,yy+step)]==flag);
else if(dir==2) return !(Screen->ComboF[ComboAt(x-step,y+c)]==flag||Screen->ComboF[ComboAt(x-step,y+c+7)]==flag||Screen->ComboF[ComboAt(x-step,yy)]==flag);
else if(dir==3) return !(Screen->ComboF[ComboAt(xx+step,y+c)]==flag||Screen->ComboF[ComboAt(xx+step,y+c+7)]==flag||Screen->ComboF[ComboAt(xx+step,yy)]==flag);
return false;
}
bool CanWalkBig(ffc f, int x, int y, int dir, int step){
if(dir==DIR_UP||dir==DIR_DOWN){
if(dir==DIR_DOWN)y+=16*(f->TileHeight-1);
for(int i=0; i<=f->TileWidth-1; i++){
if(!CanWalk(x+i*16, y, dir, step, true))return false;
}
return true;
}
else if(dir==DIR_RIGHT||dir==DIR_LEFT){
if(dir==DIR_RIGHT)x+=16*(f->TileWidth-1);
for(int i=0; i<=f->TileHeight-1; i++){
if(!CanWalk(x, y+i*16, dir, step, true))return false;
}
return true;
}
}
bool CanWalkFlagBig(int flag, ffc f, int x, int y, int dir, int step){
if(dir==DIR_UP||dir==DIR_DOWN){
if(dir==DIR_DOWN)y+=16*(f->TileHeight-1);
for(int i=0; i<=f->TileWidth-1; i++){
if(!CanWalkFlag(flag, x+i*16, y, dir, step, true))return false;
}
return true;
}
else if(dir==DIR_RIGHT||dir==DIR_LEFT){
if(dir==DIR_RIGHT)x+=16*(f->TileWidth-1);
for(int i=0; i<=f->TileHeight-1; i++){
if(!CanWalkFlag(flag, x, y+i*16, dir, step, true))return false;
}
return true;
}
}
void MoveBlock(ffc f, int dir){
Game->PlaySound(SFX_PUSHBLOCK);
for(int x=0; x<=f->TileWidth-1; x++){
for(int y=0; y<=f->TileHeight-1; y++){
Screen->ComboD[ComboAt(f->X+8+x*16, f->Y+8+y*16)]=Screen->UnderCombo;
Screen->ComboC[ComboAt(f->X+8+x*16, f->Y+8+y*16)]=Screen->UnderCSet;
}
}
for(int i=0; i<=15; i++){
if(dir==DIR_DOWN)f->Y++;
else if(dir==DIR_UP)f->Y--;
else if(dir==DIR_RIGHT)f->X++;
else if(dir==DIR_LEFT)f->X--;
WaitNoAction();
}
for(int x=0; x<=f->TileWidth-1; x++){
for(int y=0; y<=f->TileHeight-1; y++){
Screen->ComboD[ComboAt(f->X+8+x*16, f->Y+8+y*16)]=f->Data+x+4*y;
Screen->ComboC[ComboAt(f->X+8+x*16, f->Y+8+y*16)]=f->CSet;
}
}
}
void run(int temp, int dir, int trigger, int itemreq){
int tics=0;
bool pushable=true;
this->X=GridX(this->X+8);
this->Y=GridY(this->Y+8);
for(int x=0; x<=this->TileWidth-1; x++){
for(int y=0; y<=this->TileHeight-1; y++){
Screen->ComboD[ComboAt(this->X+8+x*16, this->Y+8+y*16)]=this->Data+x+4*y;
Screen->ComboC[ComboAt(this->X+8+x*16, this->Y+8+y*16)]=this->CSet;
}
}
while(true){
if(itemreq==0||Link->Item[itemreq]){
if(dir!=2&&dir!=3&&dir!=5&&Link->X>=this->X-8&&Link->X<=this->X+8+(this->TileWidth-1)*16&&this->Y>0&&this->Y<160-(this->TileHeight-1)*16){
if(dir!=0&&pushable&&CanWalkBig(this, this->X, this->Y, DIR_DOWN, 16)&&CanWalkFlagBig(67, this, this->X, this->Y, DIR_DOWN, 16)&&Link->Y==this->Y-16&&Link->Dir==DIR_DOWN&&Link->InputDown){
tics++;
if(tics==5){
MoveBlock(this, DIR_DOWN);
if(temp>0)pushable=false;
if(trigger>0){
Game->PlaySound(SFX_SECRET);
Screen->TriggerSecrets();
if(trigger>1)Screen->State[ST_SECRET]=true;
}
}
}
else if(dir!=1&&pushable&&CanWalkBig(this, this->X, this->Y, DIR_UP, 16)&&CanWalkFlagBig(67, this, this->X, this->Y, DIR_UP, 16)&&Link->Y==this->Y+8+(this->TileHeight-1)*16&&Link->Dir==DIR_UP&&Link->InputUp){
tics++;
if(tics==5){
MoveBlock(this, DIR_UP);
if(temp==1)pushable=false;
if(trigger>0){
Game->PlaySound(SFX_SECRET);
Screen->TriggerSecrets();
if(trigger>1)Screen->State[ST_SECRET]=true;
}
}
}
else if(tics!=0)tics=0;
}
else if(dir!=0&&dir!=1&&dir!=4&&Link->Y>=this->Y-8&&Link->Y<=this->Y+(this->TileHeight-1)*16&&this->X>0&&this->X<240-(this->TileWidth-1)*16){
if(dir!=2&&pushable&&CanWalkBig(this, this->X, this->Y, DIR_RIGHT, 16)&&CanWalkFlagBig(67, this, this->X, this->Y, DIR_RIGHT, 16)&&Link->X==this->X-16&&Link->Dir==DIR_RIGHT&&Link->InputRight){
tics++;
if(tics==5){
MoveBlock(this, DIR_RIGHT);
if(temp==1)pushable=false;
if(trigger>0){
Game->PlaySound(SFX_SECRET);
Screen->TriggerSecrets();
if(trigger>1)Screen->State[ST_SECRET]=true;
}
}
}
else if(dir!=3&&pushable&&CanWalkBig(this, this->X, this->Y, DIR_LEFT, 16)&&CanWalkFlagBig(67, this, this->X, this->Y, DIR_LEFT, 16)&&Link->X==this->X+16+(this->TileWidth-1)*16&&Link->Dir==DIR_LEFT&&Link->InputLeft){
tics++;
if(tics==5){
MoveBlock(this, DIR_LEFT);
if(temp==1)pushable=false;
if(trigger>0){
Game->PlaySound(SFX_SECRET);
Screen->TriggerSecrets();
if(trigger>1)Screen->State[ST_SECRET]=true;
}
}
}
else if(tics!=0)tics=0;
}
}
Waitframe();
}
}
}

Saffith
04-29-2014, 11:13 PM
The script starts out by changing the combos under the FFC to the next ones in the list. Do you have those set up correctly?

Tamamo
11-09-2015, 11:15 AM
Majora
Can you confirm if this is still happening?