Page 1 of 1

Again,questions.

Posted: 26 Aug 2016, 1:13
by Alvespires
To FINISH my episode,I need to make one thing on a level activate the event of another (ex=Mario kills a Goomba on one level and make a door open on another)
I also need permanent events(ex=If Mario makes a event that opens a door,everytime you enter the level the door will be open.
I really need to make a npc say the name of person you're playing,for exemple say "Mario" if P-1 is Mario, or "Luigi" if P-1 is Luigi.I also need to set different start points from characters in one-player game (ex=P-1 will start on one point if he is with Mario and in another if he's with Luigi)
Also,There's an block that you fall through it from up,but act like a normal block blocking you from jumping back.Is there any?

Please awnser...and many thanks

Posted: 29 Aug 2016, 0:21
by Alvespires
Please...I'm not able to start my episode without those...It's really important to make a descent one...I have so many ideas...

Posted: 29 Aug 2016, 3:43
by Lx Xzit
Alvespires wrote:To FINISH my episode,I need to make one thing on a level activate the event of another (ex=Mario kills a Goomba on one level and make a door open on another) I also need permanent events(ex=If Mario makes a event that opens a door,everytime you enter the level the door will be open.

You need to use a global variable for it. Open the world map editor an make a new global variable, put as value 0.
Then. go to the level of the goomba and make a new Scripts, insert this code:

Code: Select all

gval(GlobalVariable) = gval(GlobalVariable) + 1


Then, when the goomba dies it will activate this Script. Make a New Script > Others > (The Script you've recently done). Pick the Goomba > Death > (The event you recently made). Now go to the other level were the door will open, make a new Layer (the layer of the door) and make a new Script. Insert this code:

Code: Select all

if gval(GlobalVariable1) = 1 then
call LSet("Layer name of the door", 0, 1)
end if


Now make the layer of the door invisible of course. By last, go to events > level start > Scripts > (the script you've recently done). Here you can fin more info about "Call LSet" functions:

Spoiler
[LSet]
LSet(layername, type, nosmoke)
To change the visiblity of a layer.
layername (Layer) Layer name.
type(Double) Style,0 = Show,1 = Hide,2 = Toggle
nosmoke(Double) Whether smoke effects are shown,set to 0 to show them,set to values other than 0 to stop them from showing.


I really need to make a npc say the name of person you're playing,for exemple say "Mario" if P-1 is Mario, or "Luigi" if P-1 is Luigi.

Use conditional Scripts.

Code: Select all

If Char(1).ID = X then
call ShowMSG("your message here")
end if


X is the ID of the current player, insert:
0 = for Mario
1 = for Luigi
2 = for Peach
3 = for Toad
4 = for Link.

This Script will be activated when you talk with a NPC of course.

I also need to set different start points from characters in one-player game (ex=P-1 will start on one point if he is with Mario and in another if he's with Luigi)
You also can do this through Scripts:

Code: Select all

if Char(1).ID then
Char(1).X = "X position that you want the player appear"
Char(1).Y = "Y position that you want the player appear"
end if


To get the X and Y position active this tool and keep pressing F11:
Spoiler
Image

Also,There's an block that you fall through it from up,but act like a normal block blocking you from jumping back.Is there any?
Nope as I know.

Posted: 29 Aug 2016, 4:08
by Alvespires
Wow thank you ALOT i can Make My story episodes with that :D

Posted: 29 Aug 2016, 4:38
by Lx Xzit
No problem :)

Posted: 23 Sep 2016, 2:32
by Alvespires
Lx Xzit wrote:if Char(1).ID then
Char(1).X = "X position that you want the player appear"
Char(1).Y = "Y position that you want the player appear"
end if

I'm sorry for replying that late but...I put the player start position if he's mario in one section and if luigi on another.Now the player die when the level start.There's a way to make it on diferent sections?

Posted: 23 Sep 2016, 5:12
by Lx Xzit
Can you show me the script you made? it shouldn't produce errors.

Posted: 23 Sep 2016, 14:32
by Alvespires
No,the Script don't matter at all,because I put them at same section and worked,but the player died when it's from another section other than where the start point is.Not putting any start points don't start the game at all,But if you really think they'll help...
Spoiler
if Char(1).ID = 1 then
Char(1).X = -139584
Char(1).Y = -140224
else
Char(1).X = -119584
Char(1).Y = -120192
end if