Forum

> > CS2D > Scripts > LFC: Toggled timer
ForenübersichtCS2D-Übersicht Scripts-ÜbersichtEinloggen, um zu antworten

Englisch LFC: Toggled timer

7 Antworten
Zum Anfang Vorherige 1 Nächste Zum Anfang

alt LFC: Toggled timer

Ace Howl
User Off Offline

Zitieren
Hello...
Toggled timer is like 'flashlight and battery'. Example: If I enable flashlight, decrease timer will begin. And if I off the flash, it will stop decreasing.

Active flashlight: 100% - 1% every interval
Off flashlight: +1% every interval until max (such as max 100%)
I need this also for other function, not just flashlight thing.

This is the only request for now.

What is LFS and LFC (Just info) >


PS: I can't find similar post and I don't know its title

alt Re: LFC: Toggled timer

Marcell
Super User Off Offline

Zitieren
like in Zombie Plague?


Look in to that "Flashlight" script, and learn it, then make your own

alt Re: LFC: Toggled timer

Ace Howl
User Off Offline

Zitieren
Oh . I don't realise that player flashlight can't be changed. By the way, I will research the script like stated user Marcell. Thanks for the alert.
Edit 1(New):
Oh yeah, I remember. If the energy[id] gets low and I turn on the flashlight, the player will stop moving and energy[id] increased 1 per interval. When the energy[id] full, it will show message "Energy full" and interval stop acting. Like sleeping.

alt Re: LFC: Toggled timer

Rainoth
Moderator Off Offline

Zitieren
You could use my file cs2d Run Lua
It's really similar to what you need. You just have to change the hook to flashlight and change the speedmod stuff into imagealpha/image.

alt Re: LFC: Toggled timer

Alistaire
User Off Offline

Zitieren
user Rainoth hat geschrieben
You could use my file cs2d Run Lua
It's really similar to what you need. You just have to change the hook to flashlight and change the speedmod stuff into imagealpha/image.


The flashlight is controlled by F. You can't change behaviour of the flashlight for one person. It's impossible with the flashlight hook.

alt Re: LFC: Toggled timer

Rainoth
Moderator Off Offline

Zitieren
user Alistaire hat geschrieben
user Rainoth hat geschrieben
You could use my file cs2d Run Lua
It's really similar to what you need. You just have to change the hook to flashlight and change the speedmod stuff into imagealpha/image.


The flashlight is controlled by F. You can't change behaviour of the flashlight for one person. It's impossible with the flashlight hook.


Ye but it's just a little sprite rotating. I'm talking about using an image. Like in ZP.

alt Re: LFC: Toggled timer

r4ndxm
User Off Offline

Zitieren
user Alistaire hat geschrieben
The flashlight is controlled by F. You can't change behaviour of the flashlight for one person. It's impossible with the flashlight hook.


This is my map script, it actually builds a menu when the flashlight is on.

1
2
3
4
5
6
addhook("flashlight","weirdmenu")
function weirdmenu(id,state)
     if state==1 then
        menu(id,"WeirdMenu,NumberOne,NumberTwo,NumberThree")
     end
end

This is possible, just change the menu to whatever you want it to be.
Zum Anfang Vorherige 1 Nächste Zum Anfang
Einloggen, um zu antworten Scripts-ÜbersichtCS2D-ÜbersichtForenübersicht