Quote:
Originally Posted by napo_p2p
You might get away with just putting the GS1 script up, but it's good practice to use only GS2 online.
You can mostly go line-by-line and make a direct change from GS1->GS2.
If you haven't checked it out already:
http://wiki.graal.net/index.php/Creation/Dev/GS1_To_GS2
That article gives a pretty good overview of the types of changes you need to make.
|
Ok, well for displaying showtext I presume this is the GS2 equivalent of what I have done for my hud.
PHP Code:
function onCreated() {
temp.p = {5, 5};
temp.txt = "HP:" @ clientr.player_hp @ "/" @ clientr.player_hpmax;
temp.i = showtext(200, temp.p[0], temp.p[1], "Arial", "b", temp.txt);
temp.i.layer = 4;
temp.txt = "MP:" @ clientr.player_mp @ "/" @ clientr.player_mpmax;
temp.i = showtext(201, temp.p[0], temp.p[1] + 20, "Arial", "b", temp.txt);
temp.i.layer = 4;
}
As far as I can tell, this works the same, but I don't understand "temp.p" and "temp.i", "temp.i.layer". I presume temp.i.layer is the same as changeimgvis, but what I don't understand is why the text being on layer 4 works, when I thought only 5 and up works for the screen instead of the playing field?
This script is something another scripter made/posted on my RC and I'm trying to learn off it and/or convert it to match what I have done in GS1, since it seems nearly identical but with strange syntax differences.
This really confuses me as to why everyone says "GS2 is easier to understand" or "GS2 makes more sense" because GS1 makes sense to me, but looking at this stuff, I am like.. what?!