English New Env_Item icon

6 comments
11.06.12 05:13:01 am
like 2 like it!
2 kb, 74 Downloads
MikuAuahDark
User
Offline Off
i create a new script again. it's called New Env_Item because it uses Env_Item entity for the system.

How To Use:
• create Env_Item on map
• open Env_Item properties
• put the command on Trigger tab(Not name)
• change the Item ID(of course) because this is second parameter that required
• make sure that Spawn setting on "On Trigger only" so it not spawn
• save the map and Have Fun

Commands:
• equip - give the "Item ID(on Env_Item)" weapon
• switch - set your weapon to "Item ID"(if you have)
• strip - strip your "Item ID" weapon(if you have)
• exists - it check are you have "Item ID" weapon or not

How To Install:
• extract newenv_item.txt that on sys > lua to <cs2ddir>/sys/lua
• open server.lua
• add this on end of server.lua:
Code:
1
dofile("sys/lua/newenv_item.txt")

• close and save server.lua and Have Fun

the command is mixable, it means that you can insert more that 1 command for example:
Code:
1
equip switch

it give you "Item ID" and switch your weapon to "Item ID"

also there is a Example map that use "Item ID" to P90. if you want to use it, just extract Envitemtest.map located on maps folder to maps folder on CS2D

and of course is editable. so you can add more commands but it little harder if you newbie.

Rights:
√ Use it at your server
√ Edit it w/o my permission(but don't reupload on us.de)
√ Say user MikuAuahDark made it
√ Reupload at another site(but give me credits)
× Steal
× Reupload on us.de
imageimageimageimageimage
ok This file has been reviewed and approved by Seekay (04.12.15 01:10:41 pm)

Comments

6 comments
Goto Page
To the start Previous 1 Next To the start

Log in!

You need to log in to be able to write comments!Log in
12.06.12 04:33:36 pm
like I like it!
Up
xSkyLordx
User
Offline Off
hmm, amateurish but useful
12.06.12 03:32:59 pm
Up
omg
User
Offline Off
kratos, u obviously didnt even look at the code...
12.06.12 03:56:31 am
Up
MikuAuahDark
User
Offline Off
@user omg: i forgot to delete the tonumber
@user Avo: "You can use normal Env_Item to equip player. " yes but about strip and check not.
11.06.12 09:43:14 pm
like I like it!
Up
krabob
User
Offline Off
@omg, tonumber makes string into a number, I think. It probably had been used because the function being called by a timer

about script: might come in useful for people
11.06.12 07:42:48 pm
Up
omg
User
Offline Off
wtf is this LOL
this contains some of the most repetitive code ive ever seen
example:
Code:
1
2
3
4
5
function useequip(id,weapon)
id = tonumber(id)--id is already a number LOL! tonumber(id)==id!
weapon = tonumber(weapon)--same as above
parse("equip "..id.." "..weapon)--the functions only purpose was to do this? u might as well not have the function -.-
end

this part bothers me as well...
Code:
1
2
3
4
5
6
7
if commands:find("equip")~=nil then
list.equip=true
end
...--later
if list.equip then--the code ends up using list.equip a second time later on for no reason...u could just move useequip() to after the first if statement and it would be shorter, better, and "list" wouldnt even need to be created
useequip(id,weapon)
end

also, the code relies on the map which defeats the purpose of having it as a global script. the code is also in a .txt for some reason
11.06.12 05:18:02 pm
Up
Avo
User
Offline Off
It's practically nosense. You can use normal Env_Item to equip player.
To the start Previous 1 Next To the start