Sie sind nicht angemeldet.

Lieber Besucher, herzlich willkommen bei: sourceserver.info. Falls dies Ihr erster Besuch auf dieser Seite ist, lesen Sie sich bitte die Hilfe durch. Dort wird Ihnen die Bedienung dieser Seite näher erläutert. Darüber hinaus sollten Sie sich registrieren, um alle Funktionen dieser Seite nutzen zu können. Benutzen Sie das Registrierungsformular, um sich zu registrieren oder informieren Sie sich ausführlich über den Registrierungsvorgang. Falls Sie sich bereits zu einem früheren Zeitpunkt registriert haben, können Sie sich hier anmelden.

Gesetz-des-Zorns

Fortgeschrittener

  • »Gesetz-des-Zorns« ist der Autor dieses Themas

Beiträge: 417

Wohnort: 127.0.0.1

Rootserver vorhanden: Ja

  • Nachricht senden

1

Donnerstag, 13. Februar 2014, 14:25

Stammplugin für CS:GO umschreiben

Hi @ all,

Ich suche jemanden der mir das Zusatzplugin : MoreAmmo (Stamm) für CS:GO umschreiben könnte.
Da ja manche Waffen fehlen oder heute ja eine neue Waffe hinzugefügt wurde.
Vllt. findet sich ja jemand der so nett ist und es macht :)

Spoiler Spoiler

PHP-Quelltext

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
[code]
#include <sourcemod>
#include <sdktools>
#undef REQUIRE_PLUGIN
#include <stamm>

#pragma semicolon 1

new ammo;

new Handle:c_ammo;
new Handle:thetimer;

new bool:WeaponEdit[MAXPLAYERS 1][2024];

new String:basename[64];

public Plugin:myinfo =
{
    name "Stamm Feature MoreAmmo",
    author "Popoklopsi",
    version "1.1",
    description "Give VIP's more ammo",
    url "https://forums.alliedmods.net/showthread.php?t=142073"
};

public OnAllPluginsLoaded()
{
    if (!LibraryExists("stamm")) SetFailState("Can't Load Feature, Stamm is not installed!");
}

public OnPluginStart()
{
    new Handle:myPlugin GetMyHandle();
    
    GetPluginFilename(myPluginbasenamesizeof(basename));
    ReplaceString(basenamesizeof(basename), ".smx""");
    ReplaceString(basenamesizeof(basename), "stamm/""");
    ReplaceString(basenamesizeof(basename), "stamm""");
    
    HookEvent("player_death"PlayerDeath);
    
    if (GetStammGame() == GameTF2)
    {
        HookEvent("teamplay_round_start"RoundStart);
        HookEvent("arena_round_start"RoundStart);
    }
    
    c_ammo CreateConVar("ammo_amount""20""Ammo increase in percent each level!");
    
    AutoExecConfig(true"moreammo""stamm/features");
}

public OnMapStart()
{
    if (thetimer != INVALID_HANDLEKillTimer(thetimer);
    
    thetimer CreateTimer(1.0CheckWeapons_TIMER_REPEAT);
}

public OnConfigsExecuted()
{
    ammo GetConVarInt(c_ammo);
}

public PlayerDeath(Handle:eventString:name[], bool:dontBroadcast)
{
    new client GetClientOfUserId(GetEventInt(event"userid"));
    
    for (new x=02024x++) WeaponEdit[client][x] = false;
}

public RoundStart(Handle:eventString:name[], bool:dontBroadcast)
{
    for (new x=02024x++)
    {
        for (new i=0<= MaxClientsi++) WeaponEdit[i][x] = false;
    }
}

public Action:CheckWeapons(Handle:timerany:data)
{
    for (new 1<= MaxClientsi++)
    {
        new client i;
        
        if (IsStammClientValid(client) && IsPlayerAlive(client) && (GetClientTeam(client) == || GetClientTeam(client) == 3))
        {
            if (IsClientVip(client1) && ClientWantStammFeature(clientbasename))
            {
                for (new x=02x++)
                {
                    new weapon GetPlayerWeaponSlot(clientx);

                    if (weapon != -&& !WeaponEdit[client][weapon])
                    {
                        new ammotype GetEntProp(weaponProp_Send"m_iPrimaryAmmoType");

                        if (ammotype != -1)
                        {
                            new cAmmo GetEntProp(clientProp_Send"m_iAmmo"_ammotype);
                            
                            if (cAmmo 0)
                            {
                                new newAmmo RoundToZero(cAmmo + ((float(cAmmo)/100.0) * (GetClientStammLevel(client) * ammo)));
                                
                                SetEntProp(clientProp_Send"m_iAmmo"newAmmo_ammotype);
                                
                                WeaponEdit[client][weapon] = true;
                            }
                        }
                    }
                }
            }
        }
    }
    
    return Plugin_Continue;
}

public OnStammReady()
{
    LoadTranslations("stamm-features.phrases");
    
    new String:description[256];
    
    Format(descriptionsizeof(description), "%T""GetMoreAmmo"LANG_SERVERammo);
    
    AddStammFeature(basename"VIP MoreAmmo"description);

    for (new i=1<= GetStammLevelCount(); i++)
    {
        Format(descriptionsizeof(description), "%T""YouGetMoreAmmo"LANG_SERVERammo i);
        AddStammFeatureInfo(basenameidescription);
    }
}
[/code]


Mit freundlichen Grüßen
Gesetz-des-Zorns
Rechtschreibfehler sind voll normal und passieren nunmal 8)
Ich gebe keine Antworten auf PN, dazu ist das komplette Forum da um Anfragen zu beantworten ...



Ähnliche Themen