Tiny Tiny Town - Army

Anything to do with GTA1/GTA2 modding (tools, scripts and more).
Post Reply
User avatar
elypter
Immortal
Posts: 1121
Joined: 26 Dec 2009, 23:53
GH nick: elypter

Tiny Tiny Town - Army

Post by elypter »

since it is now possible to play with max wanted level in multiplayer i made a script for tiny tiny town
In the current state its just the usual map with higher wanted level but originally i wanted the players to start with wanted level 4 after death.
I used this script commands:

Code: Select all

ALTER_WANTED_LEVEL_NO_DROP  (  p1  ,  4  )

WHILE ( loop = 1 )

IF (CHECK_CHARACTER_HEALTH(p1, 0))
ALTER_WANTED_LEVEL_NO_DROP (p1, 4) // SWAT
ENDIF

ENDWHILE
But now the wanted level doesn't get higher anymore.
tested with&without the looo and with ALTER_WANTED_LEVEL_NO_DROP and ALTER_WANTED_LEVEL.

can anyone help?
yur sa'nok ngeyä

User avatar
Pyro
Immortal
Posts: 414
Joined: 17 Mar 2010, 04:07
GH nick: Pyro
Location: Wales, UK

Re: Tiny Tiny Town - Army

Post by Pyro »

Try:

Code: Select all

ALTER_WANTED_LEVEL ( player_name , 6 )
Besides, the code you posted changes the wanted level to 4 not 6! Again, the ALTER_WANTED_LEVEL_NO_DROP is used if the player has LESS than the wanted level needed.

User avatar
elypter
Immortal
Posts: 1121
Joined: 26 Dec 2009, 23:53
GH nick: elypter

Re: Tiny Tiny Town - Army

Post by elypter »

i want the maximum wanted level to be 6 but after death players should start with wanted level 4. when i activate the out-commented lines the wanted level doesn't get higher than 4 anymore.

the complete code:

Code: Select all

//tinytinytown script+map by elypter

// Players
PLAYER_PED p1 = (57.5, 129.5, 255.0) 10 0
PLAYER_PED p2 = (73.5, 120.5, 255.0) 13 90
PLAYER_PED p3 = (93.5, 114.5, 255.0) 7 270
PLAYER_PED p4 = (52.5, 111.5, 255.0) 11 0
PLAYER_PED p5 = (67.5, 114.5, 255.0) 9 90
PLAYER_PED p6 = (70.5, 131.5, 255.0) 0 270


//Cars
CAR_DATA  carinv1  =   ( 76.5 , 123.5 ) 0 180 ISETLIMO
CAR_DATA  carinv2  =   ( 71.5 , 123.5 ) 27 90 VTYPE
CAR_DATA  carrok1  =   ( 87.5 , 130.5 ) 2 180 ISETTA
CAR_DATA  carrok2  =   ( 88.5 , 130.5 ) 0 180 SPRITE


// Weapons
GENERATOR coctail1 =  ( 49.5 , 116.0 ) 0 COLLECT_04 6000 6000 8
GENERATOR shotgun =  ( 66.5 , 128.5 ) 0 COLLECT_06 6000 6000 12
GENERATOR rocket =  ( 93.5 , 129.5 ) 0 COLLECT_02 6000 6000 5
GENERATOR health =  ( 57.5 , 115.5 ) 0 COLLECT_30 6000 6000 1
GENERATOR grenade =  ( 81.5 , 125.5 ) 0 COLLECT_05 6000 6000 12
GENERATOR pistol1 =  ( 78.5 , 118.5 ) 0 COLLECT_00 6000 6000 40
GENERATOR pistol2 =  ( 56.5 , 130.5 ) 0 COLLECT_00 6000 6000 40
GENERATOR dual =  ( 51.0 , 118.0 ) 0 COLLECT_10 6000 6000 30
GENERATOR mg1 =  ( 64.5 , 115.5 ) 0 COLLECT_01 6000 6000 10
GENERATOR mg2 =  ( 90.5 , 115.5 ) 0 COLLECT_01 6000 6000 10
GENERATOR electro =  ( 80.5 , 108.5 ) 0 COLLECT_03 6000 6000 6
GENERATOR flamer =  ( 56.5 , 125.0 ) 0 COLLECT_08 6000 6000 10
GENERATOR coctail2 =  ( 61.5 , 130.5 ) 0 COLLECT_04 6000 6000 8
GENERATOR oil =  ( 55.5 , 117.5 ) 0 COLLECT_16 6000 6000 6
GENERATOR mines =  ( 66.5 , 120.5 ) 0 COLLECT_17 6000 6000 4
GENERATOR vmg =  ( 95.5 , 119.5 ) 0 COLLECT_18 6000 6000 10
GENERATOR amour =  ( 84.5 , 116.5 , 2.0 ) 0 COLLECT_31 6000 6000 1
GENERATOR invuln =  ( 76.5 , 124.5 ) 0 COLLECT_34 6000 6000 1
GENERATOR gang =  ( 58.5 , 123.5 ) 0 COLLECT_40 6000 6000 1

COUNTER loop = 1
DECLARE_POLICELEVEL (6)


LEVELSTART

SET_AMBIENT_LEVEL (1.0, 0)

//ALTER_WANTED_LEVEL  (  p1  ,  4  ) // SWAT
//ALTER_WANTED_LEVEL  (  p2  ,  4  ) // SWAT
//ALTER_WANTED_LEVEL  (  p3  ,  4  ) // SWAT
//ALTER_WANTED_LEVEL  (  p4  ,  4  ) // SWAT
//ALTER_WANTED_LEVEL  (  p5  ,  4  ) // SWAT
//ALTER_WANTED_LEVEL  (  p6  ,  4  ) // SWAT


// Weapons
SWITCH_GENERATOR (coctail1, ON)
SWITCH_GENERATOR (shotgun,  ON)
SWITCH_GENERATOR (rocket,   ON)
SWITCH_GENERATOR (health,   ON)
SWITCH_GENERATOR (grenade,  ON)
SWITCH_GENERATOR (pistol1,  ON)
SWITCH_GENERATOR (pistol2,  ON)
SWITCH_GENERATOR (dual,     ON)
SWITCH_GENERATOR (mg1,      ON)
SWITCH_GENERATOR (mg2,      ON)
SWITCH_GENERATOR (electro,  ON)
SWITCH_GENERATOR (flamer,   ON)
SWITCH_GENERATOR (coctail2, ON)
SWITCH_GENERATOR (oil,      ON)
SWITCH_GENERATOR (mines,    ON)
SWITCH_GENERATOR (vmg,      ON)
SWITCH_GENERATOR (amour,    ON)
SWITCH_GENERATOR (invuln,   ON)
SWITCH_GENERATOR (gang,     ON)

//WHILE ( loop = 1 )

//IF (CHECK_CHARACTER_HEALTH(p1, 0))
//ALTER_WANTED_LEVEL (p1, 4) // SWAT
//ENDIF
//IF (CHECK_CHARACTER_HEALTH(p2, 0))
//ALTER_WANTED_LEVEL (p2, 4) // SWAT
//ENDIF
//IF (CHECK_CHARACTER_HEALTH(p3, 0))
//ALTER_WANTED_LEVEL (p3, 4) // SWAT
//ENDIF
//IF (CHECK_CHARACTER_HEALTH(p4, 0))
//ALTER_WANTED_LEVEL (p4, 4) // SWAT
//ENDIF
//IF (CHECK_CHARACTER_HEALTH(p5, 0))
//ALTER_WANTED_LEVEL (p5, 4) // SWAT
//ENDIF
//IF (CHECK_CHARACTER_HEALTH(p6, 0))
//ALTER_WANTED_LEVEL (p6, 4) // SWAT
//ENDIF

//ENDWHILE

LEVELEND
yur sa'nok ngeyä

User avatar
Sektor
Boss
Boss
Posts: 1384
Joined: 04 Mar 2008, 06:51
GH nick: Sektor
Location: GTAMP.com
Contact:

Re: Tiny Tiny Town - Army

Post by Sektor »

IF (HAS_CHARACTER_DIED(p1))
ALTER_WANTED_LEVEL (p1, 4)
ENDIF

User avatar
elypter
Immortal
Posts: 1121
Joined: 26 Dec 2009, 23:53
GH nick: elypter

Re: Tiny Tiny Town - Army

Post by elypter »

i thought i did something like that before without success but now and with some other tweaks it works. thanks :)

i will post it on the snipped thread.
yur sa'nok ngeyä

User avatar
elypter
Immortal
Posts: 1121
Joined: 26 Dec 2009, 23:53
GH nick: elypter

Re: Tiny Tiny Town - Army

Post by elypter »

last week i made this extensive scripting for tiny tiny town - army:
http://gtamp.com/forum/viewtopic.php?p=2386#p2386

I want to ask if someone could help me with some things i couldn't make progress.
Most of the implemented stuff works as intended but there are some things i couldn't figure out.
-LEVELSTART/SETUP:
ONSCREEN COUNTER doesn't work, it just doesn't get displayed (not that important, atm i just wanted to use it for testing)

-LEVELSTART/mainloop/CARMODEL CHECK/IF (CHECK_CHARACTER_HEALTH(p1, 0))/IF (IS_CHARACTER_IN_ANY_CAR ( p1 ) ):
the trigger for the elvis gang (Powerup for LIMO & LIMO2) doesn't work

Tanker:
-sometimes when when the tanker explodes(i needed to make it by a workaround) a bus remains
-when you are too far away or too near to the tanker it will be spawned incorrectly or the trailer doesn't get connected. I have no idea why.
and i also have a general question:
-what is the difference between WHILE and WHILE_EXEC ? afaik WHILE_EXEC is executed every game cycle but when i switch the mainloop to WHILE_EXEC it doesn't get slower but some things don't work anymore
yur sa'nok ngeyä

Post Reply