AlliedModders

AlliedModders (https://forums.alliedmods.net/index.php)
-   Store (https://forums.alliedmods.net/forumdisplay.php?f=157)
-   -   Release Steambot - Item to Credits (https://forums.alliedmods.net/showthread.php?t=273105)

Arkarr 10-12-2015 14:42

Steambot - Item to Credits
 
11 Attachment(s)
this plugin require [ANY] Steambot !
FIXED!

Description :

This plugin detect when someone finish a trade with the bot and give that someone some credits !
See exemple :

Commands:
Invite the steambot to trade with you, and tada ! You got your credits !

Installation :
1) Download the smx, put it in the plugins folder
2) Configure the CVAR [IMPORTANT]
3) Put Steambot_CustomPrices.txt in CONFIGS folder ! This file allow you to give extra rewards for item. For exemple :
[ITEM DEFINITION INDEX OR NAME]:[NUMBER OF CREDITS]
A few exemple :
Code:

5000:9000                          ->      Will give '9000' credits for the item definition index '5000' (Scrap Metal)
AK-47 | Cartel (Well-Worn):98745    ->      Will give  '98745' credits for the item with the name 'AK-47 | Cartel (Well-Worn)'

My config file :
http://puu.sh/rljKr/e1bbca27a8.jpg
Note, DO NOT put name of item for all TF2 related stuff. Only Item definition index.
4) Write in the server console : sm plugins load SteamBotStoreCredits or restart the server.

By default, the plugin multiply the trade value by '1000'. For exemple, if you put a "Chroma 2 Case" and "Chroma Case", the trade value would be of 0.09$. (Chroma Case = 0.06$ and Chroma 2 Case = 0.03$, wich means 0.03+0.06 = 0.09, it's simple math ;3), now let's multiply the result by 1000, the user will have 90 CREDITS ! Now let's complicate things a little bit. Let's say you have put "Chroma 2 Case" in the config file like this :
Code:

Chroma 2 Case:800
The number of credits the user will have is.... come one.... you can do it... CORRECT ! 890 CREDITS ! (800 from the config file + 90 of trade value ;3 !)

That's all what you need, enjoy !


Request :

None for the moment... feel free to ask !

Logs :
1.0 : First public release.

Robin955 10-12-2015 14:52

Re: Steambot - Scarp / key to credits
 
a bit bad explanation.
This will make a bot in the map located somewhere or will it be a chat bot? that will what? trade with him?

are you saying this is something that you can sell ur items to and get credits back? cause if so i like this idea alot better than using !sell :D.
but where would this bot even generate in the map/maps? and will it walk around?

and where is the setting.json file? could put that in the OP.

supreeda 10-12-2015 15:08

Re: Steambot - Scarp / key to credits
 
amazing this plugins but it bug ?
Dont use Steambot
Trojan.Kazy.D90E50
and many Virus

Arkarr 10-12-2015 16:43

Re: Steambot - Scarp / key to credits
 
Quote:

Originally Posted by supreeda (Post 2352426)
amazing this plugins but it bug ?
Dont use Steambot
Trojan.Kazy.D90E50
and many Virus

Dude, I swear, there is NOTHING like viruses on my Steambot. Please, give the file name wich is SUPPOSED to be infected.

Also, stop to spread sh*t, thanks.

Quote:

Originally Posted by Robin955 (Post 2352424)
a bit bad explanation.
This will make a bot in the map located somewhere or will it be a chat bot? that will what? trade with him?

are you saying this is something that you can sell ur items to and get credits back? cause if so i like this idea alot better than using !sell :D.
but where would this bot even generate in the map/maps? and will it walk around?

and where is the setting.json file? could put that in the OP.

I do understand that leak of information. Now, let me just fix that for ya.

Drixevel 10-12-2015 17:16

Re: Steambot - Scarp / key to credits
 
Plugin looks great, it'll also work with Store 2.0 out of the box. Let me know if you want me to add anything to the system for you to use.

Cheers,
- The guy with the worst name on the internet.

Arkarr 10-12-2015 17:31

Re: Steambot - Scarp / key to credits
 
Quote:

Originally Posted by r3dw3r3w0lf (Post 2352466)
Plugin looks great, it'll also work with Store 2.0 out of the box. Let me know if you want me to add anything to the system for you to use.

Cheers,
- The guy with the worst name on the internet.

Actually, I would like to find away to add credits to user by steamID (I don't know if you read the code fully, but you can clearly see a retarded PrintToServer() line.). Now I need the player to be connected to add him credit (wich is not that great, but that's just what I think, I may be wrong ?).

Drixevel 10-12-2015 18:49

Re: Steambot - Scarp / key to credits
 
Quote:

Originally Posted by Arkarr (Post 2352467)
Actually, I would like to find away to add credits to user by steamID (I don't know if you read the code fully, but you can clearly see a retarded PrintToServer() line.). Now I need the player to be connected to add him credit (wich is not that great, but that's just what I think, I may be wrong ?).

Something like this?
Code:

native bool Store_GiveSteamIDCredits(char[] sSteamID, int credits, bool bClientCheck = true);
1st & 2nd field are obvious, 3rd field will be the check if they're in the server or not and if they are, send them a message stating they received the credits. It would also return a boolean based on if the SteamID was found in the database or not.

Thoughts?

Arkarr 10-13-2015 01:35

Re: Steambot - Scarp / key to credits
 
@r3dw3r3w0lf damn i'm sorry, I should have search better. If I had thought ? Well, this store project is awesome and I hope he will never die, keep doing duch amazing work !

Drixevel 10-13-2015 01:52

Re: Steambot - Scarp / key to credits
 
Quote:

Originally Posted by Arkarr (Post 2352559)
@r3dw3r3w0lf damn i'm sorry, I should have search better. If I had thought ? Well, this store project is awesome and I hope he will never die, keep doing duch amazing work !

No, I haven't implemented that yet. I'm giving an example on how I picture the native to work. Thoughts?

Also, thanks.

Arkarr 10-13-2015 03:32

Re: Steambot - Scarp / key to credits
 
Quote:

Originally Posted by r3dw3r3w0lf (Post 2352561)
No, I haven't implemented that yet. I'm giving an example on how I picture the native to work. Thoughts?

Also, thanks.

That would be perfect. Sorry for late reply, store changelog on girhib, right ?

Also, what happen if the steamId is not found in database ? We can't add credits ?


All times are GMT -4. The time now is 13:27.

Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.