[FilterScript] Radioactive Zone
#1

My first scripts.Consist in the area51 is a radioactive zone , coming down your health and you get dizzy.Sorry for my english,iam uruguayan.

Credits:
Ygzeb(help in SetTimer)
Irinel and Otacon(areas tutorial)





pawn Код:
//Zona radioactiva by smoke - Radioactive Zone by smoke
 

 
#include <a_samp>
#include <streamer>
#pragma tabsize 0
 
new VidaTimer[MAX_PLAYERS];
new smoke;
new radiacion_smoke;
 
 
public OnPlayerEnterDynamicArea(playerid, areaid)
{
if(areaid == smoke)
    {
      GameTextForPlayer(playerid, "~w~You have entered a radioactive area , ~r~ care", 4000, 3);
      SetPlayerDrunkLevel(playerid,50000);
      VidaBajando(playerid);
      }
    return 1;
}
 
public OnPlayerLeaveDynamicArea(playerid, areaid)
{
     if(areaid == smoke)
    {
        GameTextForPlayer(playerid, "~w~You have left the radioactive zone,~n~~b~you are now safe!", 4000, 3);
        SetPlayerDrunkLevel(playerid,0);
        }
    return 1;
      }
 
    forward VidaBajando(playerid);
        public VidaBajando(playerid)
        {
        new Float:Health;
        GetPlayerHealth(playerid,Health);
        SetPlayerHealth(playerid,Health-5);
        return VidaTimer[playerid]=SetTimerEx("VidaBajando", 3000,0,"d",playerid);
        }
 
public OnGameModeInit()
{
smoke = CreateDynamicRectangle(-81.74512, 1623.225, 397.0478, 2183.763, -1, -1, -1);
radiacion_smoke = GangZoneCreate(-93.423, 1611.547, 420.4035, 2148.729);
return 1;
}
 
public OnPlayerSpawn(playerid)
{
GangZoneShowForPlayer(playerid, radiacion_smoke, 0xFF000096);//default colour is red
return 1;
}
 
public OnPlayerDisconnect(playerid, reason)
{
KillTimer(VidaTimer[playerid]);
return 1;
}
Reply
#2

Nice and simple filterscript

Also, your translations to english are a little wrong :P

Fix:
pawn Код:
GameTextForPlayer(playerid, "~w~You have entered a radioactive zone,~n~~r~be careful!", 4000, 3);
and
pawn Код:
GameTextForPlayer(playerid, "~w~You have left the radioactive zone,~n~~b~you are now safe!", 4000, 3);
Reply
#3

Very simple and very poorly defined

KillTimer(VidaTimer[playerid]); = Leave zone
Reply
#4

Good job for your skill level, keep it up! I remember when I sucked this bad, just don't give up.
Reply
#5

I didn't know these functions you have used, gonna study them right now.

Nice filterscript .
Reply
#6

Quote:
Originally Posted by Crayder
Посмотреть сообщение
Good job for your skill level, keep it up! I remember when I sucked this bad, just don't give up.
Thanks

Quote:
Originally Posted by Vasco
Посмотреть сообщение
Nice and simple filterscript

Also, your translations to english are a little wrong :P

Fix:
pawn Код:
GameTextForPlayer(playerid, "~w~You have entered a radioactive zone,~n~~r~be careful!", 4000, 3);
and
pawn Код:
GameTextForPlayer(playerid, "~w~You have left the radioactive zone,~n~~b~you are now safe!", 4000, 3);
Thanks and fix translate in code

Quote:
Originally Posted by Boot
Посмотреть сообщение
I didn't know these functions you have used, gonna study them right now.

Nice filterscript .
Thanks!
Reply
#7

Nice idea and good job
Reply
#8

Nice one.
Reply
#9

Good work
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)