i-shop (shop creation) -
iggy1 - 04.11.2010
i-shop
Introduction
With this include you can create shops ingame on command (checkpoints that bring up weapon dialogs ect that have 3d text displaying the shop name and a map icon). At the moment it only has weaponshops but in the next update it will hopefully have a bug-free car ownership shop spawner too and more configurable! You will need some includes zcmd and y_hooks also two plugins sscanf2 and the streamer plugin to compile/run.
Pastebin
>> Click Me To Download ishop! <<
Usage
first download the file and put it in your your pawno include folder.
Put this in your gamemode/filterscript with other includes and compile.
pawn Code:
//just compile this with your gamemode!
#include <ishop>
//Done!
If you dont want heavy weps like rpg's comment the following line
Commands (all rcon otherwise it will return "UNKNOWN COMMAND"
/createshop [shopname][shoptype] - Creates a shop with the name of your choice. If its null it will create a weaponshop called "weapon shop"
/deleteshop [shopname] - deletes the shop of your choice. if null it will delete the last shop created.
/deleteallshops - will delete all shops.
Callbacks
pawn Code:
forward OnPlayerBoughtWeapon(playerid, weaponid, weaponname[]);
forward OnPlayerEnterShopCp(playerid, shopid, shopname[]);
Requirements & Links
Includes
zcmd
y_hooks
Plugins
sscanf2 (include needed too)
streamer 2.5(include needed too)
Please report any bugs and/or suggestions.
Credits to
****** for sscanf, y_hooks and IsPlayerinRangeofPoint function.
ZeeX for zcmd
Incognito for the streamer plugin
Chuck norris
ps, forgive the presentation im crap with bbcode.
Re: i-shop (shop creation) -
vyper - 04.11.2010
good
![Smiley](images/smilies/smile.png)
i like it
Re: i-shop (shop creation) -
barneystinson - 04.11.2010
Deletes shop as soon as its made for me and just shows name nothing else
Re: i-shop (shop creation) -
iggy1 - 04.11.2010
Quote:
Originally Posted by barneystinson
Deletes shop as soon as its made for me and just shows name nothing else
|
Are you sure you have the right plugins and includes? I tested it with 20 shops and deleted them all one at a time.
Re: i-shop (shop creation) -
barneystinson - 04.11.2010
Well yeah i downloaded them from your links except now when i jump at the shop it shows the marker and lets me buy weapons
although walking/running doesnt do anything, on creating it it all shows up then the checkpoint dissapears and i get in console shop deleted when i minimize game..
Re: i-shop (shop creation) -
iggy1 - 04.11.2010
I don't know what to say iv just tested it again and its still working for me. I'll have to wait for more comments see if anyone else gets that problem.
Re: i-shop (shop creation) -
Kewizzle - 04.11.2010
my server says Script[gamemodes/CANG.amx]:Run time error 19: "File or function is not found"
btw CANG.amx is my gamemode
help me why isnt it working is my code right?
Code:
#include <a_samp>
//just compile this with your gamemode!
#include <ishop>
//Done!
//Colores
#define BLANCO 0xFFFFFFFF
#define NEGRO 0x000000FF
#define ROJO 0xFF0000FF
#define AZUL 0x0000FFFF
#define VERDE 0x00FF00FF
#define VERDEO 0x008000FF
#define NARANJO 0xFF8000FF
#define AMARILLO 0xFFFF00FF
#define GRIS 0x808080FF
#define ROJOO 0x800000FF
#define CELESTE 0x00FFFFFF
#define NEGROA 0x000000BE
#define MORADO 0xFF0080FF
#define ALLOW_ALLWEAPONS
//Equipos
#define CIVILES 1
#define PACOS 2
#define CAOS 3
#define MEDICOS 4
Re: i-shop (shop creation) -
iggy1 - 04.11.2010
Looks like your missing a plugin, check requirements on 1st post. You could also remove the comments to make it look like this,
pawn Code:
#include <a_samp>
#include <ishop>
Re: i-shop (shop creation) -
PANTHER12 - 05.11.2010
y_hooks include needed no links =(
Re: i-shop (shop creation) -
iggy1 - 05.11.2010
The link for y_hooks is right underneath the link to zcmd it has been since i made the topic.