Are Functions global objects?

Discussion and feedback on Construct 2

Post » Tue Mar 18, 2014 1:07 am

Hi friends,

I searched in the forum an information but I have not found an answer.
Functions are global in the Construct 2? All Layouts are able to see a function?

How to create a global function?

thanks,

:D
GABAMOBI
B
15
S
7
G
3
Posts: 14
Reputation: 2,436

Post » Tue Mar 18, 2014 1:11 am

Yes.
You could test that by adding a new layout and trying to add another function object.
Image ImageImage
B
169
S
50
G
170
Posts: 8,291
Reputation: 108,726

Post » Tue Mar 18, 2014 3:44 am

newt, I think what he is asking is if he creates a function on one event sheet, is it accessible from other event sheets by default. I don't believe it is global in that sense.

I will typically create a new event sheet called Functions, and then Include that event sheet on all other event sheets that need to access those functions. You can do that by right clicking a black area of your event sheet and choosing "Include Event Sheet"
B
101
S
32
G
11
Posts: 1,552
Reputation: 21,667


Return to Construct 2 General

Who is online

Users browsing this forum: ditocruz, SysDiman, zenox98 and 8 guests