Forum

> > CS2D > Scripts > Need help with CrossFire 2D script !!!
Forums overviewCS2D overview Scripts overviewLog in to reply

English Need help with CrossFire 2D script !!!

13 replies
To the start Previous 1 Next To the start

old Need help with CrossFire 2D script !!!

phihung940
User Off Offline

Quote
IMG:https://ossweb-img.qq.com/images/cf/act/a20090325evil/evil_photo_pic03.jpg


Can some body help me make a HUD like this picture.
I wanna make:
1) HUD Kill: When you kill somebody, the picture apear in 3 second then Disapear. (Like number 8 on Pic)
2) First/Last kill: When you are the first/last kill, the picutre apear then disapear (Like number 7 on Pic)
3) Avatar of Character: Avatar apear on the bottom left of the pic (Number 4 on Pic) if this in CS2D, the "Character Avatar" should higher than the HP hud
4) Weapon Avatar: this "WA" will on right next to the "Character Avatar" in 1 line.

And somebody help me make the "Zombies Class" + Knockback please

Thank so much !

old Re: Need help with CrossFire 2D script !!!

HoRnS
User Off Offline

Quote
batlaizys has written
Mhm. Nobody will do everything for you. Learn lua and make it yourself.



But he don't asked for others make for he, he askd for help.

I don't know much about Scripts but I think that is a great idea.

old Re: Need help with CrossFire 2D script !!!

Banaan
User Off Offline

Quote
Killimage:

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
addhook("kill","cf_killImage")
addhook("second","cf_killImageCount")

cf_ki={}

function cf_killImage(id)
	cf_ki[id]={image("path/to/kill_image",0,1,2,id),0}
	imagealpha(cf_ki[id][1],0.5)
	imagepos(cf_ki[id][1],320,350,0)
end
	
function cf_killImageCount()
	for i,v in ipairs(cf_ki) do
		cf_ki[i][2]=v[2]+1
		if v[2]==3 then freeimage(cf_ki[i][1]) cf_ki[i]=nil end
	end
end

old Re: Need help with CrossFire 2D script !!!

phihung940
User Off Offline

Quote
@Bannaan: I'm not totally understand... so in this line:
1
cf_ki[id]={image("path/to/kill_image",0,1,2,id),0}
I'm change to:
1
cf_ki[id]={image("gfx/killmark/kill1.bmp",0,1,2,id),0}
Am I right ?

old Re: Need help with CrossFire 2D script !!!

phihung940
User Off Offline

Quote
OK, I need all those killmark:
1) Machete (B.C Axe) killmark
2) Plant C4
3) Defuse C4
4) Kill zombie
5) Grenade kill
6) Headshot
7) Knife kill
Knife doublekill
9) Knife triple kill
10) Knife ultrakill (Kill 4 player)
11) Kill player (you already do this)
12) Double kill
13) Triplekill (kill 3 player)
14) Ultrakill (... 4 player)
15) Unstopaple ( 5 player)
16) Godlike (6 player)
17) Revenge killmark
18) Last kill
19) First kill
20) Infected mark (infected player)
21) Failed Infected (hit player, but his not infacted)

That's all :D, I think we should edit the apear time to 2 second, cause I've test the script and I think 3 second is too long. oh, yes. My friend said that the killmark dont disapear after he kill player 5 second ???

old Re: Need help with CrossFire 2D script !!!

Banaan
User Off Offline

Quote
Small fix to prevent that:

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
addhook("kill","cf_killImage")
addhook("second","cf_killImageCount")

cf_ki={}

function cf_killImage(id)
	if cf_ki[id] then freeimage(cf_ki[id]) end
	cf_ki[id]={image("path/to/kill_image",0,1,2,id),0}
	imagealpha(cf_ki[id][1],0.5)
	imagepos(cf_ki[id][1],320,350,0)
end
	
function cf_killImageCount()
	for i,v in ipairs(cf_ki) do
		cf_ki[i][2]=v[2]+1
		if v[2]>=3 then freeimage(cf_ki[i][1]) cf_ki[i]=nil end
	end
end

I'll need some time to implement all the other images...

old Re: Need help with CrossFire 2D script !!!

phihung940
User Off Offline

Quote
@Banaan: Yah man. After the "Killmark" script... we have a large of other people script to fix =.=. Hey, I was added "Dead body" for the game :D, I also added the "Quest System" script... but, I see it not so good for my Mod . You just do the script, I'm already have a image

old Re: Need help with CrossFire 2D script !!!

phihung940
User Off Offline

Quote
@HeaDHunTeR_Tr: Alright... so, can you help me make the Character Avatar + Weapon Avatar ? here is the example image (i'm made by Photoshop):
IMG:https://i662.photobucket.com/albums/uu348/phihung940/example.jpg?t=1294287502


@RedFrix: Ok, Host for me. thank so much.
To the start Previous 1 Next To the start
Log in to reply Scripts overviewCS2D overviewForums overview