SA-MP Forums

Go Back   SA-MP Forums > SA-MP Scripting and Plugins > Filterscripts

Reply
 
Thread Tools Display Modes
Old 30/09/2010, 11:29 AM   #1
[HiC]TheKiller
High-roller
 
Join Date: Mar 2008
Location: New Zealand
Posts: 3,076
Reputation: 406
Default [PHP][MYSQL][FS]Object Adder!

Object Adder!

Introduction
This was a script that was originally thought up by Realcop228 (The base idea of loading objects through a MySQL databse). What this script does is it allows you to add whole maps through a web document without having to restart your server or add a filterscript/edit your gamemode. It is good for servers that don't like restarting when they have a bunch of players to add a map quickly.

Scripting
This isn't a simple script to install and I'll try make it more "Noob friendly" next release. The instructions are pretty straight forward to me but they may not be for other people so please don't hesitate to ask questions. If you are wondering why I'm using the sscanf plugin; that's because if people use it for long periods of time it will be much, much more efficient. You must have the MySQL plugin which is located here. Also the sscanf plugin is needed. I recommend not using this to load all of your objects but a few maps would be fine. You are able to use either CreateObject, F_CreateObject (Fallout's streamer) or CreateDynamicObject (Streamer plugin) for now but I will make more if people ask.

Videos

The more recent one is from the finished product. It is using the streamer plugin as a example.

This one is from the early development when I had only finished the adding of objects part.


Instructions
These are some nice long instructions, please post if you are unclear on any of these steps.

Code:
1. Firstly you must setup your database and tables. 
a. Go into the folder SQL table located in the same directory as these instructions and make sure the file "tables.sql" is there
b. Go into PhpMyAdmin in your hosts control panel (If you are using other software look for a import button of some sort).
c. If you have not already created a database your host make one now
d. Find the tab that says import up the top and click it
e. Browse for that "Tables.sql" and insert it.
f. Your mysql should now be set up. Make sure you remember those mysql details (Host, user, pass, database).

2. Secondly must setup the pawn script. 
a. If you are using either F_Streamer (Fallout's) or the streamer plugin uncomment the includes
b. Edit the database information to what you use (Host, User, Password, Database). If you are using wamp on localhost than it's already default.
c. You will need the MySQL plugin and include (http://forum.sa-mp.com/showthread.php?t=56564) and the sscanf2 plugin and include (http://forum.sa-mp.com/showthread.php?t=120356)
d. If you are using CreateObject, leave the COB, CDO, FCO as it is. If you are using the streamer plugin, Uncomment CDO and comment COB. If you are using fallouts, uncomment FCO and comment COB
e. Compile the script and make sure all the plugins are working.
f. If you are planning on pre-loading more than 500 objects at a time change the MAX_LOAD_OBJECT value to a higher value.
g. If you have any problems with compiling make sure you have put all the includes including MySQL and Sscanf2 into your includes folder
h. If you are still having problems, download the full server package with it already installed (Link down the bottom)

3. Lastly you must setup your site.
a. Go into the online FTP in your host.
b. Click upload
c. Select all the files for the site. If you cannot do that just winzip the whole site, upload the .zip and extract it.
d. You should upload it somewhere that isn't on the main index.
e. If you have issues with uploading, contact your host.

4. Lastly the instructions to use it

i.
a. Go into the main directory of your site and you should find yourself with a page to do with Database information
b. Insert it from earlier when you setup your mysql (Host, user, pass, database) and press submit.
c. If you get a message saying incorrect information, try it again.
d. If the problem persists and you have your MySQL hosted somewhere else (Other than the website host), ask your host to unblock external MySQL connections or you can do it if there is a option in the control panel

ii.
a. After logging in and thinking what a shitty website design you can add some objects.
b. To add a object click the Add objects option on the menu. Chose your format and make a reference (Reference is used to delete later so don't forget it) then insert some objects!
c. If you get the error that the table is missing, make sure you inserted the SQL file into Phpmyadmin and make sure that the tables are the right case (CreateObject instead of createobject)

iii.
a. After getting bored of a map you can delete it by clicking the delete objects link in the menu 
b. Put your format and reference number you got before and if your server is running tick the immediate box
There is a copy of the instructions with the package.

Downloads
The PHP + Script + SQL table
The whole server (If you are unable to set it up).

Please report any Minor or major bugs you find or if you are unable to complete one of these steps either post here, send me a PM or contact me on MSN (Look in my signature).
__________________
People seem to enjoy negitive repping me for topics that I made in 2009.
Therefore, if you want to view my releases, you can go here.

Skype: TheKiller@dr.com
I do NOT script for cash. Add me on MSN if you need help with small issues.
[HiC]TheKiller is offline   Reply With Quote
Old 30/09/2010, 11:34 AM   #2
saiberfun
High-roller
 
saiberfun's Avatar
 
Join Date: Nov 2008
Location: Germany
Posts: 3,598
Reputation: 378
Default Re: [PHP][MYSQL][FS]Object Adder!

I thought of that once too but cba to do it
__________________
saiberfun is offline   Reply With Quote
Old 30/09/2010, 12:05 PM   #3
Andrus
Little Clucker
 
Join Date: Mar 2009
Location: ☺
Posts: 48
Reputation: 0
Default Re: [PHP][MYSQL][FS]Object Adder!

Nice one man
Andrus is offline   Reply With Quote
Old 30/09/2010, 12:19 PM   #4
[HiC]TheKiller
High-roller
 
Join Date: Mar 2008
Location: New Zealand
Posts: 3,076
Reputation: 406
Default Re: [PHP][MYSQL][FS]Object Adder!

Quote:
Originally Posted by saiberfun View Post
I thought of that once too but cba to do it
Took me about 3 days. Was pretty hard and I did get frustrated with the bugs .

Quote:
Originally Posted by Andrus View Post
Nice one man
Thanks Andrus.
__________________
People seem to enjoy negitive repping me for topics that I made in 2009.
Therefore, if you want to view my releases, you can go here.

Skype: TheKiller@dr.com
I do NOT script for cash. Add me on MSN if you need help with small issues.
[HiC]TheKiller is offline   Reply With Quote
Old 30/09/2010, 12:27 PM   #5
Ernis456
Big Clucker
 
Join Date: Jul 2010
Location: Lithuania
Posts: 180
Reputation: -4
Default Re: [PHP][MYSQL][FS]Object Adder!

Nice. This FS can stream objects ?
Ernis456 is offline   Reply With Quote
Old 30/09/2010, 01:07 PM   #6
Flyfishes
Huge Clucker
 
Flyfishes's Avatar
 
Join Date: Jul 2010
Location: Stockholm, Sweden
Posts: 357
Reputation: 4
Default Re: [PHP][MYSQL][FS]Object Adder!

Awesome
__________________
Flyfishes is offline   Reply With Quote
Old 30/09/2010, 01:23 PM   #7
Johnny_Xayc
Huge Clucker
 
Johnny_Xayc's Avatar
 
Join Date: Aug 2009
Posts: 322
Reputation: 0
Default Re: [PHP][MYSQL][FS]Object Adder!

you megaMan!
Johnny_Xayc is offline   Reply With Quote
Old 30/09/2010, 01:29 PM   #8
Hal
High-roller
 
Hal's Avatar
 
Join Date: May 2010
Location: Toronto, Canada
Posts: 1,219
Reputation: 43
Default Re: [PHP][MYSQL][FS]Object Adder!

wow, thats a great idea. But i still like putting my objects in my GM. I may transfer this over, but it will be a while :P
__________________

Wanna start a project thats NOT sa-mp with me? I have a bunch of server space, PM me.
Hal is offline   Reply With Quote
Old 30/09/2010, 01:39 PM   #9
Karlip
High-roller
 
Join Date: Oct 2007
Location: Click To Show
Posts: 1,884
Reputation: 100
Default Re: [PHP][MYSQL][FS]Object Adder!

Great job! Also looks very fast.
__________________
Karlip is offline   Reply With Quote
Old 30/09/2010, 02:47 PM   #10
RealCop228
Godfather
 
Join Date: Feb 2010
Location: Springboro, OH
Posts: 8,274
Reputation: 669
Default Re: [PHP][MYSQL][FS]Object Adder!

I'm glad to see it got released. Amazing work, bro!
__________________
Putting [URGENT] in the thread title stops me from opening the thread. Nobody else's problem on this forum is more important that another person's. Try not to be self-centered!
RealCop228 is offline   Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
[FilterScript] [FS] In Game Object Editor [0.3] - All object list into menu - By Breadfish [BR]Allan Filterscripts 148 18/07/2014 10:45 PM
[FilterScript] [FS] DVA - Dynamic vehicle adder v1.1 [0.3] Striker_Moe Filterscripts 27 07/04/2013 11:46 AM
[Include] C-MySQL. (Advanced MySQL Account Configuration) Carlton Includes 44 18/08/2012 08:19 AM
Global Object + Player Object Stas92 Help Archive 5 20/04/2010 07:32 PM
[Include] [INC] >>Object Streamer Object<<< (OStreamerO) DorkAZoid Includes 9 11/12/2009 03:28 PM


All times are GMT. The time now is 12:24 AM.


Powered by vBulletin® Version 3.8.6
Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.