Graal Forums

Graal Forums (https://forums.graalonline.com/forums/index.php)
-   NPC Scripting (https://forums.graalonline.com/forums/forumdisplay.php?f=8)
-   -   Creating Weapons Help (https://forums.graalonline.com/forums/showthread.php?t=134263064)

Astram 05-01-2011 06:35 PM

Creating Weapons Help
 
Hi, I was trying to create a GUI that lets you create a weapon. Is there a way to create a weapon that does certain things through a script?
For Example:
I want a GUI that makes a weapon, and it contains what you chose in the GUI.

Its not easy to explain but, if you understand. Please help me ^^

Emera 05-01-2011 06:48 PM

Like different attributes?

Astram 05-01-2011 07:00 PM

Quote:

Originally Posted by Emera (Post 1646889)
Like different attributes?

huh? :confused:

cbk1994 05-01-2011 07:22 PM

Pretty sure it's not possible to add weapons via script without editing files directly, which you should avoid if at all possible.

If you're trying to do this for staff use, just have it generate the code and have a staff member upload it.

If you're tryign to do this for player use, you're doing it wrong.

Cubical 05-01-2011 07:26 PM

i think he's trying to do something similar to an archetype editor.

Astram 05-01-2011 07:41 PM

archetype editor?

Emera 05-01-2011 08:19 PM

If he did this i would love to see it in action.

Devil_Lord2 05-01-2011 08:44 PM

It would be interesting to see a "choose your power" type thing, be able to have w/e skillpoints and choose the damage, speed, and gani of a weapon out of various weapons as you would do on MMORPG type games.. that sounds like something able to do ..

But I don't know if that is what you mean.. at all lol

Astram 05-01-2011 10:23 PM

Quote:

Originally Posted by Devil_Lord2 (Post 1646914)
It would be interesting to see a "choose your power" type thing, be able to have w/e skillpoints and choose the damage, speed, and gani of a weapon out of various weapons as you would do on MMORPG type games.. that sounds like something able to do ..

But I don't know if that is what you mean.. at all lol

That made absolutely no sense at all to this thread

Emera 05-02-2011 10:18 AM

Astram, take your time and explain slowly.

Tricxta 05-02-2011 10:24 AM

An option you could have is all the posibilities scripted into the the actual weapon script and only sections are chosen through an array generated by your gui, at least... thats how I would do it since I only code in gs1 since gs2 is too poorly documented for my liking.

fowlplay4 05-02-2011 03:23 PM

This thread is basically a request for an item system.

Basic Item System:

1. Create a DB to hold the item information.
2. Use clientr.flags to store the item information on the player for quick client-side read access.
3. Also use clientr.flags to store the item, it's identifier, and the quantity.

You can use the clientr.flags to display the items in an inventory and throughout other GUIs.

You could also make a GUI for adding items to the DB.

Unfortunately I believe this is beyond your skill level, and a problem that should be broken in to chunks and addressed-per-issue. I may (other experienced scripters are welcome as well) post a basic system with expandability in mind, since this is a pretty common system people like to implement.

I would recommend searching the NPC Scripting forums for 'Item System' and 'MUDLib' and reading the problems and solutions of the past.

Emera 05-02-2011 06:57 PM

I don't think thats what he means but ok :)

Astram 05-03-2011 10:03 PM

I want to create a weapon containing a script. You know how in a script you can create a level? Yes, well I want to know if you can create a weapon like that

cbk1994 05-03-2011 10:15 PM

Quote:

Originally Posted by Astram (Post 1647385)
I want to create a weapon containing a script. You know how in a script you can create a level? Yes, well I want to know if you can create a weapon like that

You can, but don't.

Astram 05-05-2011 10:32 PM

Quote:

Originally Posted by cbk1994 (Post 1647386)
You can, but don't.

why not...

cbk1994 05-05-2011 11:23 PM

Quote:

Originally Posted by Astram (Post 1647826)
why not...

Scripts shouldn't be created by other scripts on-the-fly. Not only can it cause problems when you update the text files directly, but it's just a mess. If you want to create custom items, make an item system capable of it.


All times are GMT +2. The time now is 07:18 PM.

Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2026, vBulletin Solutions Inc.
Copyright (C) 1998-2019 Toonslab All Rights Reserved.