TKC-Community

Hacking and Art => Armed Assault 3 => Armed Assault => Topic started by: IllAssembly on January 06, 2008, 07:39:28 am

Title: COPS: Sahrani
Post by: IllAssembly on January 06, 2008, 07:39:28 am
ok well i need to start somewhere and if someone would like to help that would be awesome! but the scripting is mad easy i just dont know what to do so i need instruction. if someone would be so kind.

this is what i want to do:  to my revolution 05 map.[evo] kind of

whenever firefights break out, there are no fleeing pedestrian cars or anything. its completely emppty. i would ike to create a script to have vehicles spawn/ flee the populated areas and also have a reactionary [hostile] police force respond to situations in a timely manner. maybe have section patrols for the police also. please help i want to play this asap and it will be made so you can take credit for the script just so i can use it. lol.

part 2.

okay whether or not thats alot already, i would also like to have some scripting where whenever a police force is sent to a situation, you get notified of what and where[coord] so u too can respond to the action. please help as soon as possible like i already stated you help me make you get all the credit for the finished products my reward will be using the scripts in my free time. this would be my biggest arma project to date so it would help me learn more about creating scripts. some1 please help me accomplish this thanks.

basically i want a cop squad to patrol around and find situations and just hover around the border and not get into the action too much, but close enough to get shot at. i would like the police to be hostile to both sides, so you have to destroy or avoid them.
Title: Re: COPS: Sahrani
Post by: ZOldDude on January 06, 2008, 08:02:51 am
A very interesting concept and project which I feel would help teach allot of how ArmA scripting works in general.

Besides those on the SCP project we have many here who do script ArmA maps/game/ad-dons and hope that you find support from them.
Doolittle,Doc2 and Dwarden (under another name) are perhaps -the leaders- in that respect (or know of scriptors) and I would encourage them to assist you.
Title: Re: COPS: Sahrani
Post by: Doolittle on January 06, 2008, 09:28:06 am
I'd love to assist such a fine, outstanding human of a being. Have the BIS forums been unable to help you?
Title: Re: COPS: Sahrani
Post by: IllAssembly on January 06, 2008, 09:48:23 am
lol, im not dedicated enough to learn the whole arma language ive spent about 3 total minutes reading the dictionary things with commands n shit . this is the first time ive ever said anything about it. i guess the first place to start is to create some new .sqs's?
Title: Re: COPS: Sahrani
Post by: ZOldDude on January 06, 2008, 12:43:29 pm
Doolittle.......

Again I vote you a 1 plus karma point.
Your expressed position to assist your fellow man/gamer is not without my knowledge/view or personal approval.

I further urge those with a karma vote to add to your ranking on the TKC forum as such.

By the way...I am a Human but will forever object to being ever being called a Human Being as it is a leagale term coined by a former King to denote the leagal status of his unwed offsring.
Human=everyone
Human Being = a Monster with out any Rights to iherintents (spelling?) or protection under the Law.
Knowing the source of the term  makes Human Being a suck ass thing to be called.

Z
Title: Re: COPS: Sahrani
Post by: Doolittle on January 06, 2008, 10:44:52 pm
For part 1, that's hard to do.. create a life-like situation. First, how do you detect a fight? You have a trigger that sees if any civilians were killed? Then you have to createUnit some vehicles and put a created civilian in them, then you have to tell them to move to a point away from that spot. Also do the same with cops and have them move into the spot. But once they get to the fight zone you have to tell them to get out and attack the perpetrators. Hard to do.

If you want the police hostile from the get-go then just make them on the resistance side. Plus, make this a bookmark: http://community.bistudio.com/wiki/Category:Scripting_Commands_ArmA (http://community.bistudio.com/wiki/Category:Scripting_Commands_ArmA)
Title: Re: COPS: Sahrani
Post by: IllAssembly on January 07, 2008, 04:16:30 am
lol human being.


could you not do something similar to placing markers so when anything is hit or detonated on the marker or in its radius it triggers a patrol to come check around the area? then when the patrol is triggered a hint would hint you of the markers location?  or maybe just like the click map gbu, click where you want a patrol to patrol around.

edit: ive been playng around with the "dynamic ambush system" and personally i think it belongs in the toilet. with all due respect.   it was almost half of what i was looking for, except the markers are permantly placed, therefore whenever you radio any support they dont go where you put them or even to you, they go to the markers, everytime. plus i somehow think they made the script way too complicated because i run it 2x and my game gets so laggy. i have a nice system.
Title: Re: COPS: Sahrani
Post by: Doolittle on January 07, 2008, 05:56:09 am
Here's easiest way to do it: place resistance in the towns, then change them to civilians via text edit mission.sqm. Then place resistance somewhere else on the map and have them go to a GUARD waypoint and change those to civilian cops.

Now, whenever someone is spotted by the resistance civilians, the civilian cops will rush in & fight back.
Title: Re: COPS: Sahrani
Post by: IllAssembly on January 07, 2008, 10:16:54 am
so...in that nature i could make a police station or outpost in multiple locations of the map so when anything gets in range they notify a police patrol

how would i place one of them in a tower or guarded position so even if i kill off most of the spotters someone is still spotting?

also wouldnt the patrol only be notified 1 time? i need it so along side of the battle i want the police harrassing me
Title: Re: COPS: Sahrani
Post by: Doolittle on January 07, 2008, 10:48:37 am
I think SCP has a script that does that already.
Title: Re: COPS: Sahrani
Post by: Easy_tiger on January 07, 2008, 02:34:38 pm
lol, im not dedicated enough to learn the whole arma language ive spent about 3 total minutes reading the dictionary things with commands n shit . this is the first time ive ever said anything about it. i guess the first place to start is to create some new .sqs's?

Its really worth reading up on scripting. I know it may seem like a drag but it really does pay off in the long run. Also remember that all you learn now will also be applicable to ArmA2

Start off with some small sqs files to get your confidence up, forget sqf's & functions for now thats advanced stuff which you wont need till you understand sqs script files properly.
Title: Re: COPS: Sahrani
Post by: Doolittle on January 07, 2008, 10:22:50 pm
To rebuff Easy_tiger: if you're just learning, I'd say avoid .SQS and always work with .SQF since .SQS is being phased out.
Title: Re: COPS: Sahrani
Post by: IllAssembly on January 08, 2008, 02:49:50 am
which one overrides the other; sqs or sqf? i have both in my mission for init[.sqs] and [.sqf] and depending on what each one has in it my mission has the different options. when both are in, which one applies?
Title: Re: COPS: Sahrani
Post by: [TKC]Wesker on January 08, 2008, 03:30:50 am
which one overrides the other; sqs or sqf? i have both in my mission for init[.sqs] and [.sqf] and depending on what each one has in it my mission has the different options. when both are in, which one applies?
I've never tried this but I think the init.SQS
ArmA loads addons in alphabetical order. Last one to load is the overrider!
I say think because I have no idea if mission/addon content is loaded in the same fashion.
Title: Re: COPS: Sahrani
Post by: IllAssembly on January 08, 2008, 03:59:31 am
cool im gonna play arma for a lil while and then study the scripting dictionary doolittle linked me 2   :icon_teehee
Title: Re: COPS: Sahrani
Post by: Easy_tiger on January 08, 2008, 01:16:25 pm
To rebuff Easy_tiger: if you're just learning, I'd say avoid .SQS and always work with .SQF since .SQS is being phased out.


True, but if someone has no programming experience then SQS syntax is simpler than the more formal SQF equivelent. 

Quote
which one overrides the other; sqs or sqf? i have both in my mission for init[.sqs] and [.sqf] and depending on what each one has in it my mission has the different options. when both are in, which one applies?

Neither, sqs scripts run interpreted code/commands, sqf functions are really meant to be complied and used as commands. For example you could make a script called "myAddWeapons.sqf", compile it and then use it your .sqs script file as "this myAddWeapons select 0".  Some ppl however have  started replacing their sqs scripts with sqf scripts as the syntax and grammar are similar to third generation languages like c++
Title: Re: COPS: Sahrani
Post by: szero on January 08, 2008, 11:12:48 pm
try a small script which use:

deletevehicle bankflag_1; deletevehicle bankflag_2 ... ;)


thats what we do, just delete all the damn banks!!

capatalism will die!!
Title: Re: COPS: Sahrani
Post by: IllAssembly on January 09, 2008, 01:07:15 am
dont be an idiot
(http://img.photobucket.com/albums/v125/DAMNWHATNAMECANIUSE/newnicepic.jpg)

(http://img.photobucket.com/albums/v125/DAMNWHATNAMECANIUSE/dbrm.jpg)

(http://img.photobucket.com/albums/v125/DAMNWHATNAMECANIUSE/lostbros.jpg)

(http://img.photobucket.com/albums/v125/DAMNWHATNAMECANIUSE/001godzilla.jpg)
Title: Re: COPS: Sahrani
Post by: [TKC]Wesker on January 09, 2008, 02:00:15 am
thats what we do, just delete all the damn banks!!

capatalism will die!!
Lmao!
Title: Re: COPS: Sahrani
Post by: M. O. on January 09, 2008, 02:43:05 am
Or cause some hyperinflation by spawning some money print object ;)
Title: Re: COPS: Sahrani
Post by: ZOldDude on January 09, 2008, 03:31:42 am
Or cause some hyperinflation by spawning some money print object ;)
Can you put moeny in an ammo create?
Title: Re: COPS: Sahrani
Post by: szero on January 09, 2008, 03:50:24 pm
well or search the var for the standart money and change it for everyone.. so all get 999999999 at every minute =)

i think its STARTKAPITAL = 8500 for startmoney and the var: add_civmoney = 200 or if you play as cop add_copmoney 2500

change this var to:

Code: [Select]
STARTKAPITAL=9999999999;
publicvariable "STARTKAPITAL";
add_civmoney=9999999999;
add_copmoney=9999999999;
publicvariable "add_civmoney";
publicvariable "add_copmoney";

so you can play sahrani war instead sahrani life.. xD



Title: Re: COPS: Sahrani
Post by: Easy_tiger on January 09, 2008, 04:51:11 pm
its amazing how touchy ppl get when you give them loads of money  :icon_shifty


Title: Re: COPS: Sahrani
Post by: [TKC]Wesker on January 09, 2008, 05:12:42 pm
its amazing how touchy ppl get when you give them loads of money  :icon_shifty
Yea, it's just like when you give everyone a high rank in Evo
Some people like it and some people are total kill joys that want the map restarted.
I bet them guys collect stamps and wear slippers.
Title: Re: COPS: Sahrani
Post by: Easy_tiger on January 09, 2008, 07:50:19 pm
yea you just cant win can ya!

Well those killJoys have spurred me to make a start on my next SL scripts, appropriately named mugThem.sqs  & mugEveryone.sqs


I wonder if they'll moan more after they've been mugged  :icon_laugh
Title: Re: COPS: Sahrani
Post by: IllAssembly on January 11, 2008, 02:08:57 am
ok, dumb question{off topic also but i dont care} and i really want an answer i dont have time to find out on my own.right now at least.               in arma, are the bmps actually amphibious? are any vehicles acutally amphibious?
Title: Re: COPS: Sahrani
Post by: raapi on January 11, 2008, 02:19:04 am
ok, dumb question{off topic also but i dont care} and i really want an answer i dont have time to find out on my own.right now at least.               in arma, are the bmps actually amphibious? are any vehicles acutally amphibious?

an off-topic answer: yes, the BMP, BMP-2 and M113 can swim (also in Arma): http://en.wikipedia.org/wiki/BMP-1
Title: Re: COPS: Sahrani
Post by: Frank P. on January 11, 2008, 02:53:42 am
its amazing how touchy ppl get when you give them loads of money  :icon_shifty
Yea, it's just like when you give everyone a high rank in Evo
Some people like it and some people are total kill joys that want the map restarted.
I bet them guys collect stamps and wear slippers.
Hey! I collect stamps and wear.... On second thought, Nevermind
Title: Re: COPS: Sahrani
Post by: IllAssembly on January 11, 2008, 03:51:16 am
lol i so never even thought about the fact that they are amphibious vehicles until last night and i think thats pretty sweet that they are in arma also, even though i expected it