Skocz do zawartości

Nowy szablon forum

mygo.pl

Stworzyliśmy dla Was nowy wygląd forum. Z pewnością znajdziesz rzeczy, które wg Ciebie mogą zostać zmienione - wspomnij o tym w specjalnym wątku.

Czytaj więcej

Jak założyć własną sieć

serwerów CS

Zastanawiasz się nad prowadzeniem własnej sieci serwerów? Przeczytaj podstawowe informacje, na które należy zwrócić uwagę, przy takim projekcie.

Czytaj więcej

Tworzymy spis sieci

dodaj swoją

Dodaj sieć do której należysz, pozwoli to na promocję i budowę ogólnopolskiej bazy sieci CS.

Czytaj więcej

[L4D1 AND L4D2] Improved Flying Tank


MYGO.pl
 Udostępnij

Rekomendowane odpowiedzi

  • RSSy
[L4D1 AND L4D2] Improved Flying Tank


About
This is an improvement to the original Flying Tank plugin by Panxiaohai, when I used this plugin for the first time I really liked its concept and idea, but something puzzled me and it was when the Tank flew, it lost its colors, this created an incompatibility with other plugins that I used, So I was curious to check the source code, and I saw that it could improve some things so make modifications to the code according to my tastes :wink:
(If you want to see the list of changes, it is inside the file, from the original version 1.5 to the current version 2.6)

Description
The most notorious is that the tank has the opportunity to fly and follow its target through the air, but unlike the original have some extra effects, tif a player has control of the tank he can control it when it's flies and new Cvars, when a tank flies have new sound and light in his jetpack, it also has a crown effect, it's possible choose the maps where the plugin will run, and the game modes, run only in endings, activate and deactivate the plugin, tank status ads, it doesn't interfere with the rendering of the tanks, so it can be used with other plugins that use this feature, it use GetEntityRenderColor function to color glow and jetpack models.

Screenshot in L4D1, Tank remains static while flying, and him can defend with fist.
68747470733a2f2f737465616d75736572696d61

Screenshot in L4D2, the tank keeps walking while flying, and him can defend with fist. fist.
68747470733a2f2f737465616d75736572696d61

(In this case it was combined with Super Tanks, from here https://forums.alliedmods.net/showpo...92&postcount=5)

How to control the tank
In case of being controlled by a player, the tank is still subject to the assigned flight probabilities, it is more likely to start to fly if it jumps.

Key Jump (Space) Ascends in the direction of the crosshair.
Key Speed (Shift) Move in the direction of the crosshair at seventy-five percent of maximum speed.
Key Speed + Forward (Shift + W) Move in the direction of the crosshair at maximum allowed speed.
key Duck (Ctrl) Move in the crosshair direction at thirty-three percent of maximum speed.
key Duck + Forward (Ctrl + W) Move in the direction of the crosshair at fifty percent of maximum speed.
Key Forward (W) Gradually move forward.
Key Back (S) Gradually move back.
Key Moveright (D) Gradually move to the right.
Key Moveleft (A) Gradually move to the left.
Key Use (E) Descend.

Credits
Panxiaohai for his Flying Tank plugin and original idea (Original Plugin https://forums.alliedmods.net/showthread.php?p=1544648).
Silvers for his stock code of game modes allowed in his plugins.
Marttt for his stock of map code allowed in his plugins.
All of them thank you for your original ideas and code stocks. :bacon!:

Convars
PHP Code:

// Enables/Disables the plugin. 0 = Plugin OFF, 1 = Plugin ON.
// -
// Default: "1"
// Minimum: "0.000000"
// Maximum: "1.000000"
l4d_flyinginfected_enable "1"

// Enables/Disables the ability to fly for Tanks only in final events.
// 0 = Finals OFF.
// 1 = Finals ON
// -
// Default: "0"
// Minimum: "0.000000"
// Maximum: "1.000000"
l4d_flyinginfected_finale_only "0"



// Turn on the plugin in these game modes, separate by commas (no spaces). (Empty = all).
// -
// Default: ""
l4d_flyinginfected_gamemodes_on ""

// Turn off the plugin in these game modes, separate by commas (no spaces). (Empty = none).
// -
// Default: ""
l4d_flyinginfected_gamemodes_off ""

// Turn on the plugin in these game modes.
// 0 = All, 1 = Coop, 2 = Survival, 4 = Versus, 8 = Scavenge.
// Add numbers together.
// -
// Default: "0"
// Minimum: "0.000000"
// Maximum: "15.000000"
l4d_flyinginfected_gamemodes_toggle "0"

// Allow the plugin being loaded on these maps, separate by commas (no spaces). Empty = all.
// Example: "l4d_hospital01_apartment,c1m1_hotel"
// -
// Default: ""
l4d_flyinginfected_maps_on ""

// Prevent the plugin being loaded on these maps, separate by commas (no spaces). Empty = none.
// Example: "l4d_hospital01_apartment,c1m1_hotel"
// -
// Default: ""
l4d_flyinginfected_maps_off ""



// Set the speed of the Tank when him is flying.
// -
// Default: "300.0"
// Minimum: "100.000000"
// Maximum: "450.000000"
l4d_flyinginfected_speed "300.0"

// Set the max flight time.
// -
// Default: "100.0"
// Minimum: "10.000000"
// Maximum: "1000.000000"
l4d_flyinginfected_maxtime "100.0"



// Probability of flying when the Tank throws a rock.
// -
// Default: "50.0"
// Minimum: "0.000000"
// Maximum: "100.000000"
l4d_flyinginfected_chance_throw "50.0"

// Probability of flying when the Tank hits.
// -
// Default: "45.0"
// Minimum: "0.000000"
// Maximum: "100.000000"
l4d_flyinginfected_chance_tankclaw "45.0"

// Probability of flying when the Tank jumps.
// -
// Default: "75.0"
// Minimum: "0.000000"
// Maximum: "100.000000"
l4d_flyinginfected_chance_tankjump "75.0"



// Enables/Disables the crown when Tank is fliying.
// 0 = Crown of light OFF.
// 1 = Crown of light ON.
// -
// Default: "1"
// Minimum: "0.000000"
// Maximum: "1.000000"
l4d_flyinginfected_crown "1"

// Enables/Disables the light effect of the jetpack when the Tank is flying.
// 0 = JetPack Light OFF.
// 1 = JetPack Light ON.
// -
// Default: "1"
// Minimum: "0.000000"
// Maximum: "1.000000"
l4d_flyinginfected_light_system "1"

// Enables/Disables the warning message to the player when is chased by the Tank when him is flying.
// 0 = Messaje OFF
// 1 = Messaje ON.
// -
// Default: "1"
// Minimum: "0.000000"
// Maximum: "1.000000"
l4d_flyinginfected_message "1"

// Enables/Disables the ads about Tank status.
// 0 = Ads OFF
// 1 = Ads ON.
// -
// Default: "1"
// Minimum: "0.000000"
// Maximum: "1.000000"
l4d_flyinginfected_ads "1" 

Installation

1 - Click "Get Plugin" and put the "l4d_flying_tank.smx" file into your server or game \addons\sourcemod\plugins\ folder.
(If you have any previous version please delete the file or move from plugins folder and cfg folder)

Attached Files
File Type: sp Get Plugin or Get Source (l4d_flying_tank.sp - 60.2 KB)

Wyświetl pełny artykuł

Odnośnik do komentarza
Udostępnij na innych stronach

Gość
Ten temat został zamknięty. Brak możliwości dodania odpowiedzi.
 Udostępnij

×
×
  • Dodaj nową pozycję...