![]() |
GS2 npcprogramming.doc?
Has anyone made that npcprgramming.doc into GS2? I tried looking but couldn't see anything. I know there is many wiki sites, and this site, and that site... but I'm seriously scripting challenged. I like the pretty pictures, and the basic story book like explanations.
|
You've looked at my guide, no?
|
I kinda did - but I got a bit lost o.O
I'm not to sure how we got from point 1 to point 2. I really wanna learn, the basics, but my scripting consists of dontblock; drawunderplayer; drawoverplayer; - all in GS1. I dont even get where to start on GS2, and to convert the.. if created to what ever it is these days. I'm seriously seriously scripting retarded. (ask Twinny) |
You have access to a npc server. Just make up a script of some random functions, find out what's the effect of them and read up on object oriented programming in general, it's worth the time if you don't know what a class is or a function.
Edit: I looked through this,http://en.wikipedia.org/wiki/Object-...ed_programming and it's not what you need. Basically... Just remember that classes are libraries of functions so you don't have to retype the same code and they can be joined to level npcs or weapons. I'd also recommend reading fowlplays guide, I thought it was really simple and showed all the basics of gs2 required to produce a script. Just read through it slowly and test the examples to see their effect. |
Okay, so if we are talking the upmost basics of GS1...
if (playertouchsme) { lay greenrupee; hide; } would it be.. function onCreated () { - I'm already stuck.. I have a feeling it's not onCreated - but I dont know what the others are? I can't see anything on these sites. *face plants into desk* see, this npcprogramming puts it all down: - playerenters set when the player currently enters the level - playertouchsother set when another npc is touched by the player - playerlaysitem set when an item is layed by the player or another npc - compusdied set when the last baddy has died - playerendsreading set when the player ends reading a sign - timeout set when the npc's timeout runs out |
Quote:
|
well I figured the most basics would be where you start, which would be at the start. further I went down, the more I got lost. But I shall continue on..
edit: function onPlayerTouchsMe() { - okay, got that bit. Rest, I still don't know. |
Well there is a document just like the commands.rtf for GS2. It does not have all commands and so on in it, but for the basics it should be fine.
http://forums.graalonline.com/forums...ad.php?t=69323 |
Quote:
|
Okay, excellent - thanks guys. I will continue to venture forth.
|
Personally I think it would be hard to learn GS2 without any prior programming experience. Learning another language (with more documentation) would really help. It helped me greatly.
|
3 Attachment(s)
Quote:
Quote:
Sometimes it is just confusing, like the math problem that says it should work but would never work.. And anything that uses foobar crap that has nothing to do with programming or variables most likely, like myself, confuse the heck out of newcomers. ===== I personally would love to see npcprogramming2.doc and wanted to do it my self when I had time. (probably wouldn't be as efficient as someone else doing it) For those that don't have it, it is listed below. ZeroG sent me it a while ago. npcprogramming.doc = GS1 commands.txt = GS1 commands2.txt = GS2 I added one line into commands 2, findimg(). I'd like to add more but I don't know them and they are floating around randomly. The owner quit this, but I tried to give user-friendly information here... It definitely needs more added and I'd like to redo it with images, possibly videos. http://scriptingschool.forumotion.com/ |
Thanks DL :)
|
Converting gs1 to a gs2 like structure is relatively easy
if (playertouchsme) { lay greenrupee; hide; } function onPlayertouchsme(){ lay("greenrupee"); hide(); } Strings require quotes instead of the yucky #s(some string) buisness, and every function requires brackets even if there are no arguments as you saw in the example given. |
| All times are GMT +2. The time now is 03:51 AM. |
Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2026, vBulletin Solutions Inc.
Copyright (C) 1998-2019 Toonslab All Rights Reserved.