Graal Forums  

Go Back   Graal Forums > Search Forums
FAQ Members List Calendar Search Today's Posts Mark Forums Read

Showing results 1 to 8 of 8
Search took 0.00 seconds.
Search: Posts Made By: fowlplay4
Forum: NPC Scripting 08-09-2011, 09:20 PM
Replies: 35
Views: 2,599
Posted By fowlplay4
It's in pixels, so no. I don't think it will be...

It's in pixels, so no. I don't think it will be touched until the "wall" of your player collides with it on the server-side.
Forum: NPC Scripting 08-09-2011, 08:53 PM
Replies: 35
Views: 2,599
Posted By fowlplay4
For normal NPCs 48 by 48 will do fine on...

For normal NPCs 48 by 48 will do fine on server-side, and you're right on about the hit box.

The point of your shop class is to make it accept any shop id, so in your NPC you should be setting the...
Forum: NPC Scripting 08-09-2011, 07:37 PM
Replies: 35
Views: 2,599
Posted By fowlplay4
To call it from other scripts like in my class...

To call it from other scripts like in my class example, yes.
Forum: NPC Scripting 08-09-2011, 07:17 PM
Replies: 35
Views: 2,599
Posted By fowlplay4
Here's one way of doing it, you assign a shop id...

Here's one way of doing it, you assign a shop id to your npc.

I.e: this.shop_id = "basicshop";


function onCreated() {
this.shop_id = "basicshop";
this.join("shopkeeper");
}
Forum: NPC Scripting 08-09-2011, 12:55 AM
Replies: 35
Views: 2,599
Posted By fowlplay4
'this' refers to the GuiShowImgCtrl instead of...

'this' refers to the GuiShowImgCtrl instead of the level npc or weapon. You have to use thiso to access your listofitems.

I would recommend doing.. new GuiShowImgCtrl("Split_ShopItem_" @...
Forum: NPC Scripting 08-06-2011, 09:17 PM
Replies: 35
Views: 2,599
Posted By fowlplay4
You'd have to rig something together using a...

You'd have to rig something together using a trigger system or attributes. For the fairly new scripter that task could be overwhelming and/or adds un-needed complexity right now.

Whereas if you...
Forum: NPC Scripting 08-06-2011, 07:55 PM
Replies: 35
Views: 2,599
Posted By fowlplay4
Your best bet would be to do something like this:...

Your best bet would be to do something like this:


function onCreated() {
this.items = {
{"Item Name", "Description", "Price"}
};
this.join("shopkeeper");
}
Forum: NPC Scripting 08-06-2011, 07:00 PM
Replies: 35
Views: 2,599
Posted By fowlplay4
You can cut down on your 'itemSelected' code with...

You can cut down on your 'itemSelected' code with catchevent. I.e:


new GuiShowImgCtrl("Shop_Item_Fireball") {
// existing code...
thiso.catchevent(this.name, "onMouseDown",...
Showing results 1 to 8 of 8

 
Forum Jump

All times are GMT +2. The time now is 11:40 PM.


Powered by vBulletin® Version 3.8.3
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (C) 1998-2008 Linux cyberjoueurs All Rights Reserved.