![]() |
Getting Information from Arrays in DB
Welllll, what I did was create a Database for all my weapons and items on the server.
Much more efficient than a MUD and much simpler. However, I've gotten stuck as far as showing the images for icons in our inventory. We're using regular showimg controls. Could anyone help me with this issue? |
There is no way to read from DB-NPCs clientside.
To read (serverside) just use: dbName.var |
GS1 you would use with (getnpc(blah)), but with object oriented programming, the DB itself is an object, and thus, as napo stated, you can do dbName.var as an alternative, which is much more efficient and faster to use.
I think the GS2 version of with (getnpc(blah)) would be with (findnpc("blah")) or whatever, but you don't need a with for this. |
I suggest using public functions
Inside of the database create a public function like so PHP Code:
PHP Code:
Inside of the database, add this PHP Code:
PHP Code:
|
Quote:
|
| All times are GMT +2. The time now is 07:17 PM. |
Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2026, vBulletin Solutions Inc.
Copyright (C) 1998-2019 Toonslab All Rights Reserved.