Differences
This shows you the differences between two versions of the page.
Both sides previous revision Previous revision | |||
learngs2:whatjusthappened [2023/02/24 12:12] – twinny | learngs2:whatjusthappened [2023/02/24 12:23] (current) – twinny | ||
---|---|---|---|
Line 2: | Line 2: | ||
====== What Just Happened ====== | ====== What Just Happened ====== | ||
+ | |||
+ | Assuming everything just ran successfully, | ||
+ | |||
+ | **__function onCreated __** - All code should be contained within functions that can be executed. onCreated is a default function that will be executed the first time the function is created. In our case, this is whenever we first create the weapon, update the weapon or if the server is restarted | ||
+ | |||
+ | **__{ } - __** We wrap all code within these curly braces. By putting all our code within function onCreated() { .... } , it's saying that particular code belongs to the onCreated function. The code will only be executed if onCreated is called | ||
+ | |||
+ | **__echo() | ||
+ | |||
+ | __**" | ||
+ | |||
+ | Again I really want to point out that you needn' | ||