Unwalkable cell in Instance

Aeromesi

Custom Instance Maniac
Messages
821
Points
0
Age
33
Location
Custom Instances
Discord
Aeromesi#0293
Github
http://www.github.com/aeromesi
Emulator
So I've been banging my head on how to do this for a while now. Basically I'm trying to set an unwalkable cell within an instance, I've successfully done it, but it effects the original map "yuno_fild02" as well, I tried with if(has_instance) and if(instance_id) etc, but to no avail it doesn't work...

Here's my code for the "working" one that effects the original map as well as the emulated instanced map:

- script setwallcake -1,{ end;OnInit: setwall "yuno_fild02",89,185,7,6,false,"cakewall";}



This is my instance version that loads no errors but doesn't work:

Code:
-	script	setwallcake	-1,{	end;OnInstanceInit:if (has_instance("yuno_fild02", .@instance)) { {	setwall "yuno_fild02",89,185,7,6,false,"cakewall";}}}
Any help on this?

The instanced map is 1@cake by the way. Not sure if that's needed, but that's the emulation name.

 
@@Aeromesi

Did you emulate the map? You need to use the emulated name not the original map name. Also you did use .@instance which is nowhere defined in that script.

You can omit the variable since it will use the instance it is currently attached to. You also had atleast one pair of {} too many.

Code:
-	script	SetCakeWall	-1,{	OnInstanceInit:		if ( has_instance("EMULATED_MAP_NAME" ) )			setwall "EMULATED_MAP_NAME", 89, 185, 7, 6, false, "cakewall";	end;}
 
OnInstanceInit won't be executed.

Since it executes on the map of instance.

You have map as none...

Also you need to use emulated name for setwall, but original map name for npc.

 
Last edited by a moderator:
Code:
yuno_fild02,0,0,0    script    setwallcake    -1,{    end;OnInstanceInit:	setwall strnpcinfo(4),89,185,7,6,false,"cakewall";	end;}
 
How i do to set command "delwall" in other label?

Por example:

OnInstanceInit:setwall strnpcinfo(4),89,185,7,6,false,"cakewall";
for now, i want to delete wall when mob are died, like this:

OnMyModDead:delwall "cakewall";end;
but, this command on other label is not works

script make a wall normal, but don't delete wall in other label...

ps: sorry my bad english '-'

 
You are putting this label in the same NPC that's in the instance right?

 
Last edited by a moderator:
Don't worry guys I figured it out a while ago with some help
default_tongue.png


 
Back
Top