<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>https://npc-for-vcmp.sourceforge.io/wikiw/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=Habi</id>
	<title>NPC for VCMP 0.4 Servers - User contributions [en]</title>
	<link rel="self" type="application/atom+xml" href="https://npc-for-vcmp.sourceforge.io/wikiw/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=Habi"/>
	<link rel="alternate" type="text/html" href="https://npc-for-vcmp.sourceforge.io/wikiw/index.php/Special:Contributions/Habi"/>
	<updated>2026-05-18T21:38:14Z</updated>
	<subtitle>User contributions</subtitle>
	<generator>MediaWiki 1.38.5</generator>
	<entry>
		<id>https://npc-for-vcmp.sourceforge.io/wikiw/index.php?title=Main_Page&amp;diff=957447</id>
		<title>Main Page</title>
		<link rel="alternate" type="text/html" href="https://npc-for-vcmp.sourceforge.io/wikiw/index.php?title=Main_Page&amp;diff=957447"/>
		<updated>2025-01-13T09:10:35Z</updated>

		<summary type="html">&lt;p&gt;Habi: Undo revision 12479 by FelicaJarman363 (talk)&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;__NOEDITSECTION__ __NOTOC__&lt;br /&gt;
&amp;lt;big&amp;gt;&lt;br /&gt;
== Introduction ==&lt;br /&gt;
NPCs (Non Player Characters) or bots can be created in vcmp server. They can be created at ammunition stores, toolshop or mall. They can chat with players, send command to server. They can be used to play a previous recording like driving a car around an area repeatedly. Like normal players, they use server slot.&lt;br /&gt;
Their intelligence can be scripted in separate squirrel scripts. These scripts with &#039;artificial intelligence&#039; of NPC reside in &#039;&#039;&#039;npcscripts&#039;&#039;&#039; directory. &lt;br /&gt;
&lt;br /&gt;
Each NPC run in its own process. The NPC scripts have functions as well as callbacks. &lt;br /&gt;
&lt;br /&gt;
Since v1.5, adding an npc is simple as a call to [[ConnectNPC]] and if you do not want to give npc any artificial intelligence, the script parameter can be omitted. &lt;br /&gt;
{| style=height:1em&lt;br /&gt;
|scope=&amp;quot;col&amp;quot; style=&amp;quot;width: 300px; text-align:left; vertical-align: top;&amp;quot;| &lt;br /&gt;
== NPC script callbacks ==&lt;br /&gt;
|scope=&amp;quot;col&amp;quot; style=&amp;quot;width: 630px;vertical-align: top;&amp;quot; |  &lt;br /&gt;
== NPC script functions == &lt;br /&gt;
|scope=&amp;quot;col&amp;quot; style=&amp;quot;width: 300px;vertical-align: top;&amp;quot; | &lt;br /&gt;
==ServerData ==&lt;br /&gt;
|-style=&amp;quot;vertical-align: top;&amp;quot;&lt;br /&gt;
| &lt;br /&gt;
* [[OnNPCScriptLoad]]&lt;br /&gt;
* [[OnNPCScriptUnload]]&lt;br /&gt;
* [[OnNPCConnect]]&lt;br /&gt;
* [[OnNPCDisconnect]]&lt;br /&gt;
* [[OnNPCSpawn]]&lt;br /&gt;
* [[OnNPCEnterVehicle]]&lt;br /&gt;
* [[OnNPCExitVehicle]]&lt;br /&gt;
* [[OnClientMessage]]&lt;br /&gt;
* [[OnPlayerDeath]]&lt;br /&gt;
* [[OnPlayerText]]&lt;br /&gt;
* [[OnPlayerStreamIn]]&lt;br /&gt;
* [[OnPlayerStreamOut]]&lt;br /&gt;
* [[OnVehicleStreamIn]]&lt;br /&gt;
* [[OnVehicleStreamOut]]&lt;br /&gt;
* [[OnRecordingPlaybackEnd]]        &lt;br /&gt;
* [[OnPlayerUpdate]]&lt;br /&gt;
* [[OnSniperRifleFired]]&lt;br /&gt;
* [[OnConsoleInput]]&lt;br /&gt;
* [[OnServerData]]&lt;br /&gt;
* [[OnExplosion]]&lt;br /&gt;
* [[OnProjectileFired]]&lt;br /&gt;
* [[OnNPCClassSelect]] &lt;br /&gt;
* [[OnServerShareTick]]&lt;br /&gt;
*[[OnTimeWeatherSync]]&lt;br /&gt;
==Constants==&lt;br /&gt;
* [[Bodypart| BodyParts]]&lt;br /&gt;
* [[field| LocalValue fields]]&lt;br /&gt;
* [[Keys|Game Keys]]&lt;br /&gt;
* [[Player_States|Player States]]&lt;br /&gt;
* [[Play_Flags|Play Flags]]&lt;br /&gt;
== Classes ==&lt;br /&gt;
*[[Vector]]&lt;br /&gt;
*[[Quaternion]]&lt;br /&gt;
== Player functions ==&lt;br /&gt;
*[[GetPlayerState]]&lt;br /&gt;
*[[GetPlayerPos]]&lt;br /&gt;
*[[GetPlayerVehicleID]]&lt;br /&gt;
*[[GetPlayerArmedWeapon]]&lt;br /&gt;
*[[GetPlayerHealth]]&lt;br /&gt;
*[[GetPlayerArmour]]&lt;br /&gt;
*[[GetPlayerKeys]]&lt;br /&gt;
*[[GetPlayerFacingAngle]]&lt;br /&gt;
*[[IsPlayerInRangeOfPoint]]&lt;br /&gt;
*[[GetPlayerName]]&lt;br /&gt;
*[[IsPlayerConnected]] &lt;br /&gt;
* [[GetPlayerSkin]] &lt;br /&gt;
* [[GetPlayerTeam]] &lt;br /&gt;
* [[GetPlayerSlotWeapon]] &lt;br /&gt;
* [[GetPlayerSlotAmmo]] &lt;br /&gt;
*[[GetPlayerSpeed]]&lt;br /&gt;
*[[GetPlayerAction]] &lt;br /&gt;
* [[WhereIsPlayer]] &lt;br /&gt;
== Modules ==&lt;br /&gt;
* [[LibRPC]]&lt;br /&gt;
* [[LibAction]]&lt;br /&gt;
* [[npcmodule]] (to be renamed)&lt;br /&gt;
* [[z-finder]] &lt;br /&gt;
== v1.8 ==&lt;br /&gt;
* [[Suicide]]&lt;br /&gt;
* [[SetMyHealth]]&lt;br /&gt;
* [[GetMyHealth]]&lt;br /&gt;
* [[LookAtPos]]&lt;br /&gt;
* [[LookAtPlayer]]&lt;br /&gt;
* [[GetMyClass]]&lt;br /&gt;
* [[RequestClassAbs]]&lt;br /&gt;
* [[AmISpawned]]&lt;br /&gt;
* [[GetMySkin]]&lt;br /&gt;
* [[GetMyTeam]]&lt;br /&gt;
* [[GetMyArmour]]&lt;br /&gt;
* [[SendPrivMsg]]&lt;br /&gt;
* [[SetConfig]]&lt;br /&gt;
* [[GetPlayerColor]]&lt;br /&gt;
* [[GetMyColor]]&lt;br /&gt;
* [[IsPlaybackRunning]]&lt;br /&gt;
* [[IsPlaybackPaused]]&lt;br /&gt;
* [[InPoly]]&lt;br /&gt;
 || &lt;br /&gt;
* [[StartRecordingPlayback]]&lt;br /&gt;
* [[StopRecordingPlayback]]&lt;br /&gt;
* [[PauseRecordingPlayback]]&lt;br /&gt;
* [[ResumeRecordingPlayback]]&lt;br /&gt;
* [[SendChat]]&lt;br /&gt;
* [[SendCommand]]&lt;br /&gt;
* [[GetMyPos]]&lt;br /&gt;
* [[SetMyPos]]&lt;br /&gt;
* [[GetMyFacingAngle]]&lt;br /&gt;
* [[SetMyFacingAngle]]&lt;br /&gt;
* [[GetDistanceFromMeToPoint]]&lt;br /&gt;
* [[IsVehicleStreamedIn]]&lt;br /&gt;
* [[IsPlayerStreamedIn]]&lt;br /&gt;
* [[SelectWeapon]] (v1.6 b4p2)&lt;br /&gt;
* [[GetAvailableWeapons]]&lt;br /&gt;
* [[GetAmmoOfMyWeapon]]&lt;br /&gt;
* [[SetTimer]]&lt;br /&gt;
* [[SetTimerEx]] &lt;br /&gt;
* [[KillTimer]]&lt;br /&gt;
* [[GetMyName]] &lt;br /&gt;
* [[GetMyID]] &lt;br /&gt;
* [[QuitServer]]&lt;br /&gt;
* [[RequestClass]]&lt;br /&gt;
* [[ReqeustClassAbs]]&lt;br /&gt;
* [[RequestSpawn]]&lt;br /&gt;
* [[GetTickCount]]&lt;br /&gt;
* [[GetClosestPlayer]]&lt;br /&gt;
* [[GetSlotFromWeaponId]] &lt;br /&gt;
* [[FaceNPCToPlayer]]&lt;br /&gt;
==Advanced functions==&lt;br /&gt;
* [[SendOnFootSyncData]]&lt;br /&gt;
* [[SendOnFootSyncDataEx]]&lt;br /&gt;
* [[SendOnFootSyncDataLV]]&lt;br /&gt;
* [[SendInCarSyncData]]&lt;br /&gt;
* [[SendInCarSyncDataEx]]&lt;br /&gt;
* [[SendInCarSyncDataLV]]&lt;br /&gt;
* [[SendPassengerSyncData]]&lt;br /&gt;
* [[FireSniperRifle]]&lt;br /&gt;
* [[FireSniperRifleEx]]&lt;br /&gt;
* [[FireProjectile]]&lt;br /&gt;
* [[SendShotInfo]]&lt;br /&gt;
* [[SendDeathInfo]]&lt;br /&gt;
* [[GetLocalValue]]&lt;br /&gt;
* [[SetLocalValue]]&lt;br /&gt;
== Functions used only in server scripts==&lt;br /&gt;
* [[ConnectNPC]]&lt;br /&gt;
* [[ConnectNPCEx]]&lt;br /&gt;
* [[IsPlayerNPC]]&lt;br /&gt;
* [[ShowNPCConsole]]&lt;br /&gt;
* [[StartRecordingPlayerData]]&lt;br /&gt;
* [[StopRecordingPlayerData]]&lt;br /&gt;
* [[RFC]]&lt;br /&gt;
* [[F]]&lt;br /&gt;
* [[Examples]] (Remote calls)&lt;br /&gt;
* [[StartRecordingAllPlayerData]] (v1.8)&lt;br /&gt;
* [[StopRecordingAllPlayerData]]&lt;br /&gt;
* [[PutServerInRecordingMode]]&lt;br /&gt;
* [[StopServerInRecordingMode]]&lt;br /&gt;
* [[IsPlayerRecording]]&lt;br /&gt;
* [[IsServerInRecordingMode]]&lt;br /&gt;
* [[ConnectMultipleNpcs]]&lt;br /&gt;
* [[StopConnectingMultipleNpcs]]&lt;br /&gt;
* [[Server.cfg|server.cfg values]]&lt;br /&gt;
==Tools==&lt;br /&gt;
* [[recupdate]]&lt;br /&gt;
* [[recEdit]]&lt;br /&gt;
==0.4.7.1==&lt;br /&gt;
* [[FireBullet]]&lt;br /&gt;
* [[OnBulletFired]]&lt;br /&gt;
==Store==&lt;br /&gt;
* [[GetStoreLocation]]&lt;br /&gt;
* [[IsStoreDownloading]]&lt;br /&gt;
* [[OnStoreDownloadComplete]]&lt;br /&gt;
* [[GetStoreURL]]&lt;br /&gt;
||&lt;br /&gt;
* [[SendServerData]]&lt;br /&gt;
* [[ReadInt]]&lt;br /&gt;
* [[ReadByte]]&lt;br /&gt;
* [[ReadFloat]]&lt;br /&gt;
* [[ReadString]]&lt;br /&gt;
* [[WriteInt]]&lt;br /&gt;
*[[WriteByte]]&lt;br /&gt;
*[[WriteFloat]]&lt;br /&gt;
*[[WriteString]]&lt;br /&gt;
==Pickup==&lt;br /&gt;
*[[ClaimPickup]]&lt;br /&gt;
*[[IsPickupStreamedIn]]&lt;br /&gt;
*[[GetPickupModel]]&lt;br /&gt;
*[[GetPickupAlpha]]&lt;br /&gt;
*[[GetPickupQuantity]]&lt;br /&gt;
*[[GetPickupPos]]&lt;br /&gt;
*[[GetPickupCount]]&lt;br /&gt;
*[[OnPickupStreamIn]]&lt;br /&gt;
*[[OnPickupDestroyed]]&lt;br /&gt;
*[[OnPickupUpdate]]&lt;br /&gt;
==Checkpoint==&lt;br /&gt;
*[[OnCheckpointStreamIn]]&lt;br /&gt;
*[[OnCheckpointDestroyed]]&lt;br /&gt;
*[[OnCheckpointUpdate]]&lt;br /&gt;
*[[IsCheckpointStreamedIn]]&lt;br /&gt;
*[[GetCheckpointRadius]]&lt;br /&gt;
*[[GetCheckpointPos]]&lt;br /&gt;
*[[GetCheckpointColor]]&lt;br /&gt;
*[[IsCheckpointSphere]]&lt;br /&gt;
*[[ClaimEnterCheckpoint]]&lt;br /&gt;
*[[ClaimExitCheckpoint]]&lt;br /&gt;
*[[GetCheckpointCount]]&lt;br /&gt;
==Vehicle==&lt;br /&gt;
*[[EnterVehicle]]&lt;br /&gt;
*[[GetVehicleDriver]]&lt;br /&gt;
*[[GetVehicleModel]]&lt;br /&gt;
*[[GetVehicleTurretRot]]&lt;br /&gt;
*[[GetVehicleRotation]]&lt;br /&gt;
*[[GetVehiclePos]]&lt;br /&gt;
*[[GetVehicleSpeed]]&lt;br /&gt;
*[[GetVehicleHealth]]&lt;br /&gt;
*[[GetVehicleDamage]]&lt;br /&gt;
*[[ExitVehicle]] &lt;br /&gt;
*[[ExitVehicleEx]] &lt;br /&gt;
==Objects==&lt;br /&gt;
*[[OnObjectStreamIn]]&lt;br /&gt;
*[[OnObjectDestroyed]]&lt;br /&gt;
*[[OnObjectUpdate]]&lt;br /&gt;
*[[IsObjectStreamedIn]]&lt;br /&gt;
*[[GetObjectModel]]&lt;br /&gt;
*[[GetObjectPos]]&lt;br /&gt;
*[[GetObjectRotation]]&lt;br /&gt;
*[[GetObjectAlpha]]&lt;br /&gt;
*[[IsObjectTouchReportEnabled]]&lt;br /&gt;
*[[IsObjectShotReportEnabled]]&lt;br /&gt;
*[[ClaimObjectTouch]]&lt;br /&gt;
*[[ClaimObjectShot]]&lt;br /&gt;
*[[GetObjectCount]]&lt;br /&gt;
== More ==&lt;br /&gt;
*[[NPC Installation]]&lt;br /&gt;
* [[Squirrel Standard Library Functions]]&lt;br /&gt;
* [[NPCHide]]&lt;br /&gt;
* [[Command-line usage]]&lt;br /&gt;
* [[Attack Script]] (v1.5)&lt;br /&gt;
* [[walking_man|Walking cop script]]&lt;br /&gt;
==Coming Soon==&lt;br /&gt;
*[[GetScoreBoard]]&lt;br /&gt;
|}&lt;br /&gt;
&amp;lt;/big&amp;gt;&lt;br /&gt;
&amp;lt;poem style=&amp;quot;border: 2px solid #d6d2c5; background-color: #19f4e6; &amp;quot;&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;04 February 2023: Hiding/Changing name of NPC In-Game New Plugin. [[NPCHide|see]]&lt;br /&gt;
&amp;lt;/poem&amp;gt;&lt;br /&gt;
&amp;lt;Poem style=&amp;quot;border: 2px solid #4682B4; background-color: #FFE4B5; &amp;quot;&amp;gt;&lt;br /&gt;
03 October 2024: NPC v1.8 Beta 3 is released. [[V1_8_beta3_release_notes|click here]]&lt;br /&gt;
&amp;lt;/poem&amp;gt;&lt;br /&gt;
&amp;lt;Poem style=&amp;quot;border: 2px solid #4682B4; background-color: #FFE4B5; &amp;quot;&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;25 October 2024: NPC v1.8 Beta 4&#039;&#039;&#039;. (&#039;&#039;&#039;new&#039;&#039;&#039;) [[V1_8_beta4_release_notes|&#039;&#039;&#039;click here&#039;&#039;&#039;]]&lt;br /&gt;
&amp;lt;/poem&amp;gt;&lt;/div&gt;</summary>
		<author><name>Habi</name></author>
	</entry>
	<entry>
		<id>https://npc-for-vcmp.sourceforge.io/wikiw/index.php?title=Main_Page&amp;diff=957446</id>
		<title>Main Page</title>
		<link rel="alternate" type="text/html" href="https://npc-for-vcmp.sourceforge.io/wikiw/index.php?title=Main_Page&amp;diff=957446"/>
		<updated>2025-01-13T09:10:10Z</updated>

		<summary type="html">&lt;p&gt;Habi: Undo revision 166140 by RustyWaylen4 (talk)&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Zuri - An African Grey Parrot Baby For Sale&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;African greys reside in families in the wild. They&#039;re extremely social birds, and require plenty of interaction with their human companions.&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;Although they&#039;re not as expensive as dogs, parrots can be huge financial commitments. Insurance for pets is recommended as they&#039;re also susceptible to illnesses. You may also want to create a savings account for your bird&#039;s expenses.&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;Health&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;Zuri is a gorgeous [https://intern.ee.aeust.edu.tw/home.php?mod=space&amp;amp;uid=1222778 baby African grey parrot] available for sale that is waiting to be adopted by his new family. He is a very social bird and has been taught to be a comfortable companion for humans. He&#039;ll make a wonderful companion for life. He is fully vaccinated and has an excellent health report.&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;African Grey Parrots are one of the most sought-after parrots that are available. They are renowned for their intelligence and their ability to mimic speech. They build strong bonds and love spending time with their owners. [https://valetinowiki.racing/wiki/16_MustFollow_Facebook_Pages_To_Parrots_African_Grey_For_Sale_Marketers african grey parrot adoption] Greys do not make ideal pets for children because they require plenty of playtime, interaction and a variety of games and toys to keep them entertained. They also require a huge cage, plenty of space to fly, and regular visits to avian veterinarians for veterinary checks and specialized care.&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;Parrots can last up to 50 years in captivity. Therefore, it is crucial for potential owners to consider whether they are prepared to commit to the long-term commitment of having an avian friend. Parrots shed a lot down, which can be problematic for people who suffer from asthma or allergies. Additionally, parrots have naturally large beaks that will grow into sharp points if not regularly trimmed.&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;Due to their high level of intelligence, African Grey parrots need regular stimulation and interaction to stay healthy and happy. They need a lot of physical activity, as well as a variety of toys and games to keep their minds active and a diet high in vegetables, fruits, and nuts. They also need to have regular checkups with a vet, especially an avian vet, since they are more susceptible to certain health issues, such as the fatty liver disease and diabetes.&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;If you&#039;re interested in a african grey parrot available for auction, seek recommendations from other bird owners and the avian veterinarians in your region. They&#039;ll give you an idea of a breeder&#039;s reputation and help you locate a reliable seller. It is an excellent idea for you to visit the place where the parrots were kept in. This will give you an chance to see how the birds are kept, and also avoid buying from a place that appears unclean or dirty.&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;Training&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;African grey parrots are incredibly intelligent, and they love to discover new things. They can mimic sounds and can speak simple words. As they grow older their communication skills will continue to improve. They are social animals and need to be handled often. It is crucial to take them out of their cages and interact with them. They should get sufficient exercise and mental stimulation to prevent boredom, which can result in aggressive behavior.&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;You should be prepared to pay one-time charges when you purchase a new parrot. You will have to pay for a large cage, toys, and food bowls. Also, you should think about pet insurance, which is recommended for all exotic pets. These prices don&#039;t stop with the initial purchase. You&#039;ll also need to pay for regular vet care and other expenses that are unexpected. Owning an [https://valetinowiki.racing/wiki/Stephensdidriksen2545 african grey parrot adoption] Grey Parrot can be expensive. However you can cut down on your monthly costs.&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;A parrot requires plenty of attention and interaction, but too much can result in aggression. It is essential to locate a veterinary clinic that can provide top-quality treatment. It is also crucial to know when your bird is about to getting rid of. This will allow you to avoid accidents.&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;Parrots are extremely connected to their owners. However, they can become aggressive and territorial when they believe their owner is in danger. It is essential that all family members interact with the parrot on a regular basis. They can provide treats and give the parrot affection and can even teach it tricks.&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;In the wild, nearly all parrots form long-term bonds. This is known as pair bonding and it&#039;s very common. Pair bonds can last for an entire lifetime, and parrots are extremely loyal to their loved ones. It is also possible for parrots be bonded to more than one person, however it&#039;s important to understand that this can be dangerous.&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;Care&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;African grey parrots are intelligent, social birds that thrive on interactions with other animals and humans. They are among the most popular parrot species that are kept as pets in Europe, America, and the Middle East because of their longevity, intelligence and ability to imitate human speech. In the wild, african grey parrots live in savanna and forest woodlands and eat trees that have been planted and the remnants of trees around villages. Their numbers in the wild are dwindling due to the destruction of forests and trapping for the pet trade.&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;They are faithful companions that bond with their human hosts however, they can be playful and playful. Due to their energy levels, these parrots need plenty of exercise and enrichment activities. They must spend at least an hour or two every day playing and engaging in intellectual stimulation with their owners.&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;In captivity in captivity, a grey african parrot that doesn&#039;t receive enough attention may become stressed and agitated. The birds might scream to express their discontent and can cause disruption. A depressed bird may also use self-harming behavior like tearing out its own feathers It is therefore important to ensure that your pet is happy and healthy.&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;[http://bbs.zhizhuyx.com/home.php?mod=space&amp;amp;uid=11944248 african grey parrot eggs for sale] greys require a healthy diet and regular veterinary care. The best diet is mostly pellets with a smaller portion of a variety of fruits and vegetables, as well as grains. To keep their beaks occupied, these parrots will chew on toys and puzzles.&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;Bathing is also essential to get rid of dust and dirt on the bird&#039;s feathers. It is recommended that you bathe your african gray parrot at least once a week. Vaccinations and routine fecal examinations are also important to ensure your pet&#039;s health. Our Greeley veterinarians are certified avian and exotic animal specialists, which means they can assist you in taking great care of your african grey.&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;If you are not prepared to care for the bird until its final days, then avoid buying unweaned african grey baby birds for sale. Birds who aren&#039;t fully weaned could develop fungal infections or bacterial infections that eventually kill them.&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;Feeding&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;African greys are intelligent animals. They have the same level of intelligence as toddlers. Their ability to mimic human speech is also amazing. They are wonderful companions to those who have the time and motivation to train them.&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;They thrive on routine, and may become depressed if they&#039;re not included in their owners&#039; lives. If they are stressed or bored they might be able to pluck their feathers and chew. It is essential to keep your dog entertained by offering toys and training sessions.&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;In the wild, African gray parrots have complex social lives. They are monogamous. They show altruistic behavior, such as grooming each other and eating their food to feed their young. They can also travel for up to 10km a day and are great flyers.&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;It is not uncommon for young African greys to be fed a formula for hand-rearing until they are ready fly at about 12 weeks old. However, it is important to keep in mind that the process of weaning does not end at that point. After that, they will need to be fed at least once a day for [https://www.hulkshare.com/matchcheek48/ buy a grey parrot] long time. Many breeders won&#039;t tell new owners this because they want to sell their babies fast to make a profit, and to ensure that the birds are healthy and well-behaved.&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;A feed supplement isn&#039;t expensive and can be bought online from many reputable pet stores. Once the bird is weaned, a mix of fresh fruits and veggies like broccoli and Kale, will be required to meet its nutritional requirements. It is not recommended to use pellets containing a lot lactose as this can cause diarrhea that is a bit sloppy.&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;Whether a parrot is a baby or an adult, it will need to be entertained and trained to keep it entertained and healthy. A parrot who is well-trained will be an absolute delight to own and can be a great companion for life. It is advised to stay clear of any coercive training methods, as it can lead to a fear-based relationship with the bird. Positive reinforcement is preferred as a method to influence the behavior of a bird.&lt;/div&gt;</summary>
		<author><name>Habi</name></author>
	</entry>
	<entry>
		<id>https://npc-for-vcmp.sourceforge.io/wikiw/index.php?title=Main_Page&amp;diff=957445</id>
		<title>Main Page</title>
		<link rel="alternate" type="text/html" href="https://npc-for-vcmp.sourceforge.io/wikiw/index.php?title=Main_Page&amp;diff=957445"/>
		<updated>2025-01-13T09:09:51Z</updated>

		<summary type="html">&lt;p&gt;Habi: Undo revision 651285 by KitM6912810 (talk)&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Where to Buy a Vibrating Panty&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;If you&#039;re looking for a way to spice up your date night with your partner or are looking to add the excitement of the solo game, vibrating panties provide a unique and discreet way to enjoy pleasure.&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;There are many styles to choose from, so make sure that you study their features and designs before purchasing. This will assist you in choosing the right product for your needs and preferences.&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;Quality Design And Construction&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;In the world of sex toys and toys, high-quality design and construction is the norm. This is evident in the vibrating panties Public; [http://rvolchansk.ru/user/jasonnickel97/ Rvolchansk.ru], panties made to fit snugly against the sexual organs. They should be made from top-quality materials and have a long lifespan.&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;As with any gizmo you&#039;ll be using in your collection, it&#039;s essential to do your research and ask the right questions. This will ensure that you get the best value for your buck.&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;For starters, you&#039;ll want to look for the best quality genitals that you can get. The best sexies are typically crafted from body-safe materials such as medical-grade silicone and ABS plastic, but they can also be found in non-gmo and all-natural varieties. A good sextoy must not be made of only high-quality material , but also include the most effective components and functions.&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;A well-constructed sextoy must be easy to clean, consume less power than the batteries, and be safe to wear. It&#039;s not always safe to be sure of a hand-me-down so it must be sturdy. The best sex toy must include a comprehensive user&#039;s guide and come with a substantial warranty. The most important part of the process is to ensure that the sex item you select is a good fit for your preferences and your lifestyle. There are many products available and it can be difficult to locate the best one. The key to having a pleasant and enjoyable experience is knowing what you&#039;re looking to find, and a little patience can be a big help.&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;The Design is Discreet&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;The [https://loaftrain6.werite.net/your-family-will-thank-you-for-getting-this-panty-vibrator vibrating panties for men] panty is a high-tech device, adds excitement and sensations to both couples and solo&#039; play. Stewart says they are used to stimulate the vulva region but they can also be used to stimulate other parts of the body.&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;Depending on the product, they can be controlled via remotes with limited ranges or using an app. If controlled by an app, they are able to be operated in a discrete manner in public places, and it is possible to use them remotely with the help of a companion.&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;If you&#039;re looking for a more discreet style try to find one that has a crotchless design. This makes it easier to wear them, and also ensures that the vibrations are undetectable to anyone who might be watching you.&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;It is important to research to find a discreet model. Think about the customer support as well as the materials used and whether they have an assurance.&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;You should also inquire about the sizing and fit. You must ensure that the [http://srv29897.ht-test.ru/index.php?subaction=userinfo&amp;amp;user=weaponsea6 panty vibrating] you select fits your body in an comfortable manner. It must also be washed easily in the washing machine or by hand.&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;The vibrating panty must be made of safe materials that can be washed and waterproofed. This will stop bacteria from getting trapped and will keep the item clean and fresh.&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;It is also an ideal idea to choose an option that doesn&#039;t require batteries. This will save you money over the long term and will also lower your impact on the environment.&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;Some models can be recharged, allowing you to use them wherever you are. This is especially beneficial for people who are constantly on the move and don&#039;t have the time or energy to recharge their devices.&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;Another factor to consider is the dimensions and shape of the toy. A comfortable and snug fitting panty will ensure that the toy isn&#039;t swaying during play.&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;Long-Distance Connection&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;A long-distance relationship is an intimate relationship between two people who live far from each other. The primary reason for this kind of relationship is an emotional connection that can be maintained through various actions like texting, emails, and video calls.&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;Studies have shown that couples who engage in &amp;quot;relationship maintenance behavior,&amp;quot; such as texting or calling, are happier with their relationships than those who don&#039;t. This includes sexual intimacy, which can be a crucial component of an enlightened LDR.&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;Technology has made it possible to keep your partner connected and involved in a sexual encounter even although you are thousands of miles away. These gadgets let you connect and play in new ways, ranging from Bluetooth-enabled sex toys, to app-controlled gizmos.&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;There are many products on the market, including bullet vibrators, cockrings, and butt plugs. A lot of them are made with long-distance couples in mind. For example the We-Vibe Moxie underwear vibes have a magnet that goes inside your underwear and a small magnet on the outside, which assists in securing the toy to your sensitive bits.&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;The latest options for remote-controlled panties include wireless controllers that can be used with an [http://www.annunciogratis.net/author/dryerbeef18 app controlled vibrating panties] to control a broad range of functions. Some of these apps allow you to send photos or videos to your friend so that they can be aware of what&#039;s happening when playing together over the phone.&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;This makes it easier for your partner and you to share what&#039;s happening. They can see your vibration power on the screen as well as see the patterns you&#039;ve created. The Lovense Ferri app is a great illustration of this.&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;Some devices also offer additional benefits like audiobook connectivity or Bluetooth speaker capabilities and are capable of controlling remotely a panty. This is especially beneficial for couples who live far away and wish to have a fun self-pity session without disrupting their partners, who can easily hear the conversation.&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;Simple to Use&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;If you&#039;re in the market for a vibrating panty, it&#039;s important to find one that&#039;s user-friendly. This will guarantee you receive the most effective sex toy.&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;You must first make sure it is positioned correctly on your clit. To verify if it is fitting properly, refer to the directions or try it yourself to verify that it is comfortable.&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;It&#039;s also recommended to search for a toy that is made of silicone, since it&#039;[https://designbrandy30.werite.net/15-up-and-coming-vibrating-panties-online-bloggers-you-need-to-follow women s vibrators] less likely to break down over time. You can still find PVC and plastic panties that vibrate.&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;You&#039;ll also need to think about the type of controller. Some vibrating panties use a remote control, while others utilize an app on a smartphone to control vibrations. The latter is a more modern approach that typically offers more power and flexibility to the user.&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;Some vibrating panties include rechargeable batteries while others require an USB charging cable. You can also find a few that have wireless technology.&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;It is important to select a vibrating panty that has been developed and manufactured in accordance with high quality standards. This includes the materials used,  [https://coketanker07.werite.net/do-not-make-this-blunder-youre-using-your-buy-panty-vibrators vibrator in panties] design features and manufacturing procedures.&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;This will ensure that the toy will have longevity and is safe for every day play. It should also be lubricated using a water-based lubricant in order to prevent any damage or break down.&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;It&#039;s also a great idea to determine the battery&#039;s runtime and how often you&#039;ll have to recharge it. This is a crucial aspect to take into consideration, as it can help you plan your schedule.&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;A vibrating panty that is equipped with a strap or pocket that allows you to place it against the clit is another way for it to be more convenient to use. This is especially important if your vibrating panty will be worn in public.&lt;/div&gt;</summary>
		<author><name>Habi</name></author>
	</entry>
	<entry>
		<id>https://npc-for-vcmp.sourceforge.io/wikiw/index.php?title=Main_Page&amp;diff=957444</id>
		<title>Main Page</title>
		<link rel="alternate" type="text/html" href="https://npc-for-vcmp.sourceforge.io/wikiw/index.php?title=Main_Page&amp;diff=957444"/>
		<updated>2025-01-13T09:09:07Z</updated>

		<summary type="html">&lt;p&gt;Habi: Undo revision 659755 by AthenaFrisby (talk)&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;The Daughter of a [https://postheaven.net/linecause3/9-signs-that-youre-an-expert-african-grey-parrot-expert Female African Grey Parrot]&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;The daughter wanted to help her father&#039;s parrot adapt to his new surroundings. She tried for months to convince him to try new foods and come out of his cage. But he seemed visibly unhappy with his surroundings.&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;The best method of determining the distinction between a male and female african grey parrot is to perform DNA testing. This method is non-invasive and precise.&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;They are very intelligent&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;The African grey parrot is able to mimic human speech with astonishing precision. The species is found in rainforests throughout central Africa all the way from Cote d&#039;Ivoire to western Kenya. It is an animal with a social aspect that nests in large groups, and manages complex relationships in the wilderness. It is also renowned for its altruistic behavior like grooming other members of the same species, or regurgitating their food.&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;Despite their abilities, African grey parrots are not the easiest pets to care for. They require regular interactions with their human companions and a variety of games and toys to be successful. Positive reinforcement is the best method to encourage desired behaviors. They can be taught a variety of tricks and commands. This method involves rewarding desired actions with treats, praise, or even petting. Be patient and consistent when you train your pet, and make sure that your sessions are short and fun.&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;Four decades ago, Harvard professor Irene Pepperberg worked with the parrot Alex and her research revolutionized the study of linguistics and animal cognition. Her findings, which proved that parrots could perform cognitive tasks at a rate that is higher than what we normally see in 5-year-old humans, are still widely accepted today.&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;They are very talkative&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;[https://mcneil-thiesen-3.hubstack.net/african-grey-parrot-adoption-a-simple-definition-1733823046/ african grey parrot birds for sale] grey parrots have a unique ability to imitate human speech. They also comprehend the meaning behind words. They can even discern the difference between colors and shapes. In the wild, they are monogamous birds, which nest in tree cavities, high above the ground. They are snatched up by snakes and large cats and defend themselves by fluttering up or biting. They play a vital part in their environment, dispersing undigested seeds.&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;In captivity, these intelligent animals become very talkative because they are social creatures. It can be difficult to introduce new family members as they are prone to becoming accustomed to one person. They can be vocalized loudly, which could be a nuisance to other family members. You can prevent these issues by training your pet with treats.&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;Some trainers have observed that taking away the bird&#039;s food habit can reduce undesirable behaviors, such as loud vocalizations. This will make him less likely to eat the food he normally eats, but instead seek out other reward options. This method takes time and consistency but should reduce the amount of unwanted behavior in the bird&#039;s life.&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;Many African greys mimic voices and pick up sounds from the radio or from home. They can be great conversation starters and can even learn to recognize the names of their owners.&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;They are extremely loved by their owners.&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;African greys are very affectionate and enjoy bonding with owners. They are very sensitive to changes in their environment or mood. They can mimic sounds that they hear such as the sound of doors and windows squeaking and doorbells for vehicles, backup chimes, microwave oven alerts and ringtones for phones. It is important to monitor the sounds they hear around them, because when a sound becomes part of their vocabulary, it may be difficult or impossible to remove it.&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;African grey parrots require a lot stimulation due to their nature of being social in the wild. If a bird is bored or uninterested, it will quickly scream to express its discontent. To prevent this from happening it is vital to regularly take your African grey out of its cage and engage with it.&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;To ensure your [https://lovewiki.faith/wiki/10_Things_Everybody_Has_To_Say_About_Caring_For_An_Grey_Parrot_Caring_For_An_Grey_Parrot baby african grey parrot for sale] gray&#039;s happiness and health, you should provide the best care. Make sure you feed it a high-quality diet specifically designed for parrots. Also, offer fresh fruits and vegetables that are rich in vitamins and minerals. Give your pet the opportunity to take a bath on a regular basis. It could be as easy as a shower in the bathroom or a bowl of water to play in. It is also important to keep the bath water warm.&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;They are extremely active&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;African greys are extremely active birds that thrive upon interactions. They require stimulation frequently, or they will become bored and start screeching. Engaging with your pet throughout the day is the best method to prevent this. You can do this by talking to your pet softly, offering treats and playing with them. This will aid in building trust with the bird and help them feel more comfortable with other people.&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;In the wild, African grays forage in the canopy and on the ground. They eat diverse fruits, vegetables, seeds, tree bark and snails. They also consume mud and grasses. Some parrots have been observed feeding on food to aid other species members. They are also known for their vocalizations, and mimic other birds, bats, and mammals.&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;When a threat appears, parrots are known to scare predators by chasing it or launching at it. This is a natural way to protect their young and other parrots. In certain situations, parrots will even attack humans if they feel threatened.&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;These birds are among the most intelligent of all avian pets. They are able to mimic many human sounds and are the most adept at mimicking human voices. They can be taught to recognize a variety of objects and sounds. They can be taught, for example, to detect the backup sound of a car alarm or home security system. They can respond to microwave alerts and telephone ringtones.&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;They are very social&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;African grey parrots are highly social birds, flying in large groups and roosting together in the treetops. They form bonds of a specific pair, and exhibit altruistic behaviors like grooming each other or eating food to feed their young. If their need for social interaction is not met they could be stressed and engage in self-harming behaviors like taking off their own hair.&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;It is widely believed that African greys can comprehend human speech due to their natural curiosity and ability for mimicry. It is important to keep in mind that African greys don&#039;t have an inherent ability to talk. Their ability to mimic human speech is due to being confined as captive birds. They are also often caught in the wings, which further isolates them.&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;If you&#039;re thinking of adopting an [https://git.fuwafuwa.moe/pondadult9 congo african grey parrot] grey, consider bringing her out of her cage regularly to socialize with family members. This will lessen aggression and feeding behaviors. It is recommended to take your pet out for at least two hours each day.&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;Positive reinforcement training is the most effective way to teach your parrot to listen and obey commands. Start with simple commands, and then increase their complexity gradually. You should also train your pet in short sessions to keep them from becoming bored. Make sure you use clear constant commands and offer treats during training sessions. This will make it more enjoyable for both of you.&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;It is easy to train them.&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;Young African Greys who have been handled by hand can easily adapt to changes in handling and environment. Adult parrots, however, are less receptive and may begin to feather pick or be aggressive. Discipline, patience, and hooding (covering the head) are effective methods to change this behavior.&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;Training your African Grey is [http://italianculture.net/redir.php?url=https://clashofcryptos.trade/wiki/20_Great_Tweets_From_All_Time_Concerning_African_Grey_Parrot_Birds_For_Sale buying an african grey parrot] ongoing process. It is essential to train your bird at least twice in five minutes each day. This keeps the bird entertained and allows for positive reinforcement. This is also the time to play with your pet, give him treats and show a little affection. Do not reward aggressive behavior.&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;Parrots are among the most intelligent animals. [https://lovewiki.faith/wiki/10_Things_Everybody_Has_To_Say_About_Caring_For_An_Grey_Parrot_Caring_For_An_Grey_Parrot african grey parrots for adoption] greys can be compared to toddlers in terms of their intelligence. They can categorize, quantify, and identify more than 80 objects. They can also solve puzzles and have an amazing ability to solve problems. This is a skill they employ to extract food from difficult-to-reach areas.&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;In their natural habitats African greys live in various lowland forest habitats that include woodlands, rainforests, and wooded savannah. They are monogamous, and typically pair-bond for the rest of their lives. They often roost together at night, sometimes in groups of more than 100 birds. These parrots are known to exhibit altruistic behavior in the wild. They will groom and regurgitate food for their families and even strangers. They also have a long lifespan and some live up to 60 years old.&lt;/div&gt;</summary>
		<author><name>Habi</name></author>
	</entry>
	<entry>
		<id>https://npc-for-vcmp.sourceforge.io/wikiw/index.php?title=GetScoreBoard&amp;diff=1918</id>
		<title>GetScoreBoard</title>
		<link rel="alternate" type="text/html" href="https://npc-for-vcmp.sourceforge.io/wikiw/index.php?title=GetScoreBoard&amp;diff=1918"/>
		<updated>2024-12-30T15:13:03Z</updated>

		<summary type="html">&lt;p&gt;Habi: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;poem style=&amp;quot;border: 2px solid #d6d2c5; background-color: #f9f4e6; padding: 1em;&amp;quot;&amp;gt;&lt;br /&gt;
This function was added in v1.8 beta 5(not released as of 30.Dec.2024)  and will not work on previous versions.&lt;br /&gt;
&amp;lt;/poem&amp;gt;&lt;br /&gt;
{{Welcome|desc=Gets the scoreboard along with ping of players.|&lt;br /&gt;
params=&amp;lt;source&amp;gt;process_scoreboard&amp;lt;/source&amp;gt;&lt;br /&gt;
::process_scoreboard : A one parameter function like &amp;lt;source inline&amp;gt;function(data)&amp;lt;/source&amp;gt; which will be called when scoreboard table arrives from server. On successful arrival, data will be an array of tables containing keys: &amp;lt;source inline&amp;gt;ID&amp;lt;/source&amp;gt;,&amp;lt;source inline&amp;gt;Score&amp;lt;/source&amp;gt; and &amp;lt;source inline&amp;gt;Ping&amp;lt;/source&amp;gt;|&lt;br /&gt;
example=&amp;lt;source&amp;gt;&lt;br /&gt;
GetScoreBoard(function(data){ &lt;br /&gt;
foreach(val in data)print(&amp;quot;ID:&amp;quot;+val.ID+&amp;quot;, Score: &amp;quot;+val.Score+&amp;quot;, Ping: &amp;quot;+val.Ping+&amp;quot;\n&amp;quot;);&lt;br /&gt;
});&amp;lt;/source&amp;gt;&lt;br /&gt;
Output:&lt;br /&gt;
&amp;lt;source inline&amp;gt;ID:0, Score: 200, Ping: 1&amp;lt;/source&amp;gt;|&lt;br /&gt;
retvals=true on success, false if scoreboard was already requested but it&#039;s not yet arrived.|}}&lt;/div&gt;</summary>
		<author><name>Habi</name></author>
	</entry>
	<entry>
		<id>https://npc-for-vcmp.sourceforge.io/wikiw/index.php?title=GetScoreBoard&amp;diff=1917</id>
		<title>GetScoreBoard</title>
		<link rel="alternate" type="text/html" href="https://npc-for-vcmp.sourceforge.io/wikiw/index.php?title=GetScoreBoard&amp;diff=1917"/>
		<updated>2024-12-30T15:12:18Z</updated>

		<summary type="html">&lt;p&gt;Habi: Created page with &amp;quot;&amp;lt;poem style=&amp;quot;border: 2px solid #d6d2c5; background-color: #f9f4e6; padding: 1em;&amp;quot;&amp;gt; This function was added in v1.8 beta 5(not released as of 30.Dec.2024)  and will not work on previous versions. &amp;lt;/poem&amp;gt; {{Welcome|desc=Gets the scoreboard along with ping of players.| params=&amp;lt;source&amp;gt;process_scoreboard&amp;lt;/source&amp;gt; ::process_scoreboard : A one parameter function like &amp;lt;source inline&amp;gt;function(data)&amp;lt;/source&amp;gt; which will be called when scoreboard table arrives from server. On succes...&amp;quot;&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;poem style=&amp;quot;border: 2px solid #d6d2c5; background-color: #f9f4e6; padding: 1em;&amp;quot;&amp;gt;&lt;br /&gt;
This function was added in v1.8 beta 5(not released as of 30.Dec.2024)  and will not work on previous versions.&lt;br /&gt;
&amp;lt;/poem&amp;gt;&lt;br /&gt;
{{Welcome|desc=Gets the scoreboard along with ping of players.|&lt;br /&gt;
params=&amp;lt;source&amp;gt;process_scoreboard&amp;lt;/source&amp;gt;&lt;br /&gt;
::process_scoreboard : A one parameter function like &amp;lt;source inline&amp;gt;function(data)&amp;lt;/source&amp;gt; which will be called when scoreboard table arrives from server. On successful arrival, data will be an array of tables containing keys: &amp;lt;source inline&amp;gt;ID&amp;lt;/source&amp;gt;,&amp;lt;source inline&amp;gt;Score&amp;lt;/source&amp;gt; and &amp;lt;source inline&amp;gt;Ping&amp;lt;/source&amp;gt;|&lt;br /&gt;
example=&amp;lt;source&amp;gt;&lt;br /&gt;
GetScoreBoard(function(data){ &lt;br /&gt;
foreach(val in data)print(&amp;quot;ID:&amp;quot;+val.ID+&amp;quot;, Score: &amp;quot;+val.Score+&amp;quot;, Ping: &amp;quot;+val.Ping+&amp;quot;\n&amp;quot;);&lt;br /&gt;
}&amp;lt;/source&amp;gt;&lt;br /&gt;
Output:&lt;br /&gt;
&amp;lt;source inline&amp;gt;ID:0, Score: 200, Ping: 1&amp;lt;/source&amp;gt;|&lt;br /&gt;
retvals=true on success, false if scoreboard was already requested but it&#039;s not yet arrived.|}}&lt;/div&gt;</summary>
		<author><name>Habi</name></author>
	</entry>
	<entry>
		<id>https://npc-for-vcmp.sourceforge.io/wikiw/index.php?title=Main_Page&amp;diff=1916</id>
		<title>Main Page</title>
		<link rel="alternate" type="text/html" href="https://npc-for-vcmp.sourceforge.io/wikiw/index.php?title=Main_Page&amp;diff=1916"/>
		<updated>2024-12-30T15:05:22Z</updated>

		<summary type="html">&lt;p&gt;Habi: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;__NOEDITSECTION__ __NOTOC__&lt;br /&gt;
&amp;lt;big&amp;gt;&lt;br /&gt;
== Introduction ==&lt;br /&gt;
NPCs (Non Player Characters) or bots can be created in vcmp server. They can be created at ammunition stores, toolshop or mall. They can chat with players, send command to server. They can be used to play a previous recording like driving a car around an area repeatedly. Like normal players, they use server slot.&lt;br /&gt;
Their intelligence can be scripted in separate squirrel scripts. These scripts with &#039;artificial intelligence&#039; of NPC reside in &#039;&#039;&#039;npcscripts&#039;&#039;&#039; directory. &lt;br /&gt;
&lt;br /&gt;
Each NPC run in its own process. The NPC scripts have functions as well as callbacks. &lt;br /&gt;
&lt;br /&gt;
Since v1.5, adding an npc is simple as a call to [[ConnectNPC]] and if you do not want to give npc any artificial intelligence, the script parameter can be omitted. &lt;br /&gt;
{| style=height:1em&lt;br /&gt;
|scope=&amp;quot;col&amp;quot; style=&amp;quot;width: 300px; text-align:left; vertical-align: top;&amp;quot;| &lt;br /&gt;
== NPC script callbacks ==&lt;br /&gt;
|scope=&amp;quot;col&amp;quot; style=&amp;quot;width: 630px;vertical-align: top;&amp;quot; |  &lt;br /&gt;
== NPC script functions == &lt;br /&gt;
|scope=&amp;quot;col&amp;quot; style=&amp;quot;width: 300px;vertical-align: top;&amp;quot; | &lt;br /&gt;
==ServerData ==&lt;br /&gt;
|-style=&amp;quot;vertical-align: top;&amp;quot;&lt;br /&gt;
| &lt;br /&gt;
* [[OnNPCScriptLoad]]&lt;br /&gt;
* [[OnNPCScriptUnload]]&lt;br /&gt;
* [[OnNPCConnect]]&lt;br /&gt;
* [[OnNPCDisconnect]]&lt;br /&gt;
* [[OnNPCSpawn]]&lt;br /&gt;
* [[OnNPCEnterVehicle]]&lt;br /&gt;
* [[OnNPCExitVehicle]]&lt;br /&gt;
* [[OnClientMessage]]&lt;br /&gt;
* [[OnPlayerDeath]]&lt;br /&gt;
* [[OnPlayerText]]&lt;br /&gt;
* [[OnPlayerStreamIn]]&lt;br /&gt;
* [[OnPlayerStreamOut]]&lt;br /&gt;
* [[OnVehicleStreamIn]]&lt;br /&gt;
* [[OnVehicleStreamOut]]&lt;br /&gt;
* [[OnRecordingPlaybackEnd]]        &lt;br /&gt;
* [[OnPlayerUpdate]]&lt;br /&gt;
* [[OnSniperRifleFired]]&lt;br /&gt;
* [[OnConsoleInput]]&lt;br /&gt;
* [[OnServerData]]&lt;br /&gt;
* [[OnExplosion]]&lt;br /&gt;
* [[OnProjectileFired]]&lt;br /&gt;
* [[OnNPCClassSelect]] &lt;br /&gt;
* [[OnServerShareTick]]&lt;br /&gt;
*[[OnTimeWeatherSync]]&lt;br /&gt;
==Constants==&lt;br /&gt;
* [[Bodypart| BodyParts]]&lt;br /&gt;
* [[field| LocalValue fields]]&lt;br /&gt;
* [[Keys|Game Keys]]&lt;br /&gt;
* [[Player_States|Player States]]&lt;br /&gt;
* [[Play_Flags|Play Flags]]&lt;br /&gt;
== Classes ==&lt;br /&gt;
*[[Vector]]&lt;br /&gt;
*[[Quaternion]]&lt;br /&gt;
== Player functions ==&lt;br /&gt;
*[[GetPlayerState]]&lt;br /&gt;
*[[GetPlayerPos]]&lt;br /&gt;
*[[GetPlayerVehicleID]]&lt;br /&gt;
*[[GetPlayerArmedWeapon]]&lt;br /&gt;
*[[GetPlayerHealth]]&lt;br /&gt;
*[[GetPlayerArmour]]&lt;br /&gt;
*[[GetPlayerKeys]]&lt;br /&gt;
*[[GetPlayerFacingAngle]]&lt;br /&gt;
*[[IsPlayerInRangeOfPoint]]&lt;br /&gt;
*[[GetPlayerName]]&lt;br /&gt;
*[[IsPlayerConnected]] &lt;br /&gt;
* [[GetPlayerSkin]] &lt;br /&gt;
* [[GetPlayerTeam]] &lt;br /&gt;
* [[GetPlayerSlotWeapon]] &lt;br /&gt;
* [[GetPlayerSlotAmmo]] &lt;br /&gt;
*[[GetPlayerSpeed]]&lt;br /&gt;
*[[GetPlayerAction]] &lt;br /&gt;
* [[WhereIsPlayer]] &lt;br /&gt;
== Modules ==&lt;br /&gt;
* [[LibRPC]]&lt;br /&gt;
* [[LibAction]]&lt;br /&gt;
* [[npcmodule]] (to be renamed)&lt;br /&gt;
* [[z-finder]] &lt;br /&gt;
== v1.8 ==&lt;br /&gt;
* [[Suicide]]&lt;br /&gt;
* [[SetMyHealth]]&lt;br /&gt;
* [[GetMyHealth]]&lt;br /&gt;
* [[LookAtPos]]&lt;br /&gt;
* [[LookAtPlayer]]&lt;br /&gt;
* [[GetMyClass]]&lt;br /&gt;
* [[RequestClassAbs]]&lt;br /&gt;
* [[AmISpawned]]&lt;br /&gt;
* [[GetMySkin]]&lt;br /&gt;
* [[GetMyTeam]]&lt;br /&gt;
* [[GetMyArmour]]&lt;br /&gt;
* [[SendPrivMsg]]&lt;br /&gt;
* [[SetConfig]]&lt;br /&gt;
* [[GetPlayerColor]]&lt;br /&gt;
* [[GetMyColor]]&lt;br /&gt;
* [[IsPlaybackRunning]]&lt;br /&gt;
* [[IsPlaybackPaused]]&lt;br /&gt;
* [[InPoly]]&lt;br /&gt;
 || &lt;br /&gt;
* [[StartRecordingPlayback]]&lt;br /&gt;
* [[StopRecordingPlayback]]&lt;br /&gt;
* [[PauseRecordingPlayback]]&lt;br /&gt;
* [[ResumeRecordingPlayback]]&lt;br /&gt;
* [[SendChat]]&lt;br /&gt;
* [[SendCommand]]&lt;br /&gt;
* [[GetMyPos]]&lt;br /&gt;
* [[SetMyPos]]&lt;br /&gt;
* [[GetMyFacingAngle]]&lt;br /&gt;
* [[SetMyFacingAngle]]&lt;br /&gt;
* [[GetDistanceFromMeToPoint]]&lt;br /&gt;
* [[IsVehicleStreamedIn]]&lt;br /&gt;
* [[IsPlayerStreamedIn]]&lt;br /&gt;
* [[SelectWeapon]] (v1.6 b4p2)&lt;br /&gt;
* [[GetAvailableWeapons]]&lt;br /&gt;
* [[GetAmmoOfMyWeapon]]&lt;br /&gt;
* [[SetTimer]]&lt;br /&gt;
* [[SetTimerEx]] &lt;br /&gt;
* [[KillTimer]]&lt;br /&gt;
* [[GetMyName]] &lt;br /&gt;
* [[GetMyID]] &lt;br /&gt;
* [[QuitServer]]&lt;br /&gt;
* [[RequestClass]]&lt;br /&gt;
* [[ReqeustClassAbs]]&lt;br /&gt;
* [[RequestSpawn]]&lt;br /&gt;
* [[GetTickCount]]&lt;br /&gt;
* [[GetClosestPlayer]]&lt;br /&gt;
* [[GetSlotFromWeaponId]] &lt;br /&gt;
* [[FaceNPCToPlayer]]&lt;br /&gt;
==Advanced functions==&lt;br /&gt;
* [[SendOnFootSyncData]]&lt;br /&gt;
* [[SendOnFootSyncDataEx]]&lt;br /&gt;
* [[SendOnFootSyncDataLV]]&lt;br /&gt;
* [[SendInCarSyncData]]&lt;br /&gt;
* [[SendInCarSyncDataEx]]&lt;br /&gt;
* [[SendInCarSyncDataLV]]&lt;br /&gt;
* [[SendPassengerSyncData]]&lt;br /&gt;
* [[FireSniperRifle]]&lt;br /&gt;
* [[FireSniperRifleEx]]&lt;br /&gt;
* [[FireProjectile]]&lt;br /&gt;
* [[SendShotInfo]]&lt;br /&gt;
* [[SendDeathInfo]]&lt;br /&gt;
* [[GetLocalValue]]&lt;br /&gt;
* [[SetLocalValue]]&lt;br /&gt;
== Functions used only in server scripts==&lt;br /&gt;
* [[ConnectNPC]]&lt;br /&gt;
* [[ConnectNPCEx]]&lt;br /&gt;
* [[IsPlayerNPC]]&lt;br /&gt;
* [[ShowNPCConsole]]&lt;br /&gt;
* [[StartRecordingPlayerData]]&lt;br /&gt;
* [[StopRecordingPlayerData]]&lt;br /&gt;
* [[RFC]]&lt;br /&gt;
* [[F]]&lt;br /&gt;
* [[Examples]] (Remote calls)&lt;br /&gt;
* [[StartRecordingAllPlayerData]] (v1.8)&lt;br /&gt;
* [[StopRecordingAllPlayerData]]&lt;br /&gt;
* [[PutServerInRecordingMode]]&lt;br /&gt;
* [[StopServerInRecordingMode]]&lt;br /&gt;
* [[IsPlayerRecording]]&lt;br /&gt;
* [[IsServerInRecordingMode]]&lt;br /&gt;
* [[ConnectMultipleNpcs]]&lt;br /&gt;
* [[StopConnectingMultipleNpcs]]&lt;br /&gt;
* [[Server.cfg|server.cfg values]]&lt;br /&gt;
==Tools==&lt;br /&gt;
* [[recupdate]]&lt;br /&gt;
* [[recEdit]]&lt;br /&gt;
==0.4.7.1==&lt;br /&gt;
* [[FireBullet]]&lt;br /&gt;
* [[OnBulletFired]]&lt;br /&gt;
==Store==&lt;br /&gt;
* [[GetStoreLocation]]&lt;br /&gt;
* [[IsStoreDownloading]]&lt;br /&gt;
* [[OnStoreDownloadComplete]]&lt;br /&gt;
* [[GetStoreURL]]&lt;br /&gt;
||&lt;br /&gt;
* [[SendServerData]]&lt;br /&gt;
* [[ReadInt]]&lt;br /&gt;
* [[ReadByte]]&lt;br /&gt;
* [[ReadFloat]]&lt;br /&gt;
* [[ReadString]]&lt;br /&gt;
* [[WriteInt]]&lt;br /&gt;
*[[WriteByte]]&lt;br /&gt;
*[[WriteFloat]]&lt;br /&gt;
*[[WriteString]]&lt;br /&gt;
==Pickup==&lt;br /&gt;
*[[ClaimPickup]]&lt;br /&gt;
*[[IsPickupStreamedIn]]&lt;br /&gt;
*[[GetPickupModel]]&lt;br /&gt;
*[[GetPickupAlpha]]&lt;br /&gt;
*[[GetPickupQuantity]]&lt;br /&gt;
*[[GetPickupPos]]&lt;br /&gt;
*[[GetPickupCount]]&lt;br /&gt;
*[[OnPickupStreamIn]]&lt;br /&gt;
*[[OnPickupDestroyed]]&lt;br /&gt;
*[[OnPickupUpdate]]&lt;br /&gt;
==Checkpoint==&lt;br /&gt;
*[[OnCheckpointStreamIn]]&lt;br /&gt;
*[[OnCheckpointDestroyed]]&lt;br /&gt;
*[[OnCheckpointUpdate]]&lt;br /&gt;
*[[IsCheckpointStreamedIn]]&lt;br /&gt;
*[[GetCheckpointRadius]]&lt;br /&gt;
*[[GetCheckpointPos]]&lt;br /&gt;
*[[GetCheckpointColor]]&lt;br /&gt;
*[[IsCheckpointSphere]]&lt;br /&gt;
*[[ClaimEnterCheckpoint]]&lt;br /&gt;
*[[ClaimExitCheckpoint]]&lt;br /&gt;
*[[GetCheckpointCount]]&lt;br /&gt;
==Vehicle==&lt;br /&gt;
*[[EnterVehicle]]&lt;br /&gt;
*[[GetVehicleDriver]]&lt;br /&gt;
*[[GetVehicleModel]]&lt;br /&gt;
*[[GetVehicleTurretRot]]&lt;br /&gt;
*[[GetVehicleRotation]]&lt;br /&gt;
*[[GetVehiclePos]]&lt;br /&gt;
*[[GetVehicleSpeed]]&lt;br /&gt;
*[[GetVehicleHealth]]&lt;br /&gt;
*[[GetVehicleDamage]]&lt;br /&gt;
*[[ExitVehicle]] &lt;br /&gt;
*[[ExitVehicleEx]] &lt;br /&gt;
==Objects==&lt;br /&gt;
*[[OnObjectStreamIn]]&lt;br /&gt;
*[[OnObjectDestroyed]]&lt;br /&gt;
*[[OnObjectUpdate]]&lt;br /&gt;
*[[IsObjectStreamedIn]]&lt;br /&gt;
*[[GetObjectModel]]&lt;br /&gt;
*[[GetObjectPos]]&lt;br /&gt;
*[[GetObjectRotation]]&lt;br /&gt;
*[[GetObjectAlpha]]&lt;br /&gt;
*[[IsObjectTouchReportEnabled]]&lt;br /&gt;
*[[IsObjectShotReportEnabled]]&lt;br /&gt;
*[[ClaimObjectTouch]]&lt;br /&gt;
*[[ClaimObjectShot]]&lt;br /&gt;
*[[GetObjectCount]]&lt;br /&gt;
== More ==&lt;br /&gt;
*[[NPC Installation]]&lt;br /&gt;
* [[Squirrel Standard Library Functions]]&lt;br /&gt;
* [[NPCHide]]&lt;br /&gt;
* [[Command-line usage]]&lt;br /&gt;
* [[Attack Script]] (v1.5)&lt;br /&gt;
* [[walking_man|Walking cop script]]&lt;br /&gt;
==Coming Soon==&lt;br /&gt;
*[[GetScoreBoard]]&lt;br /&gt;
|}&lt;br /&gt;
&amp;lt;/big&amp;gt;&lt;br /&gt;
&amp;lt;poem style=&amp;quot;border: 2px solid #d6d2c5; background-color: #19f4e6; &amp;quot;&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;04 February 2023: Hiding/Changing name of NPC In-Game New Plugin. [[NPCHide|see]]&lt;br /&gt;
&amp;lt;/poem&amp;gt;&lt;br /&gt;
&amp;lt;Poem style=&amp;quot;border: 2px solid #4682B4; background-color: #FFE4B5; &amp;quot;&amp;gt;&lt;br /&gt;
03 October 2024: NPC v1.8 Beta 3 is released. [[V1_8_beta3_release_notes|click here]]&lt;br /&gt;
&amp;lt;/poem&amp;gt;&lt;br /&gt;
&amp;lt;Poem style=&amp;quot;border: 2px solid #4682B4; background-color: #FFE4B5; &amp;quot;&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;25 October 2024: NPC v1.8 Beta 4&#039;&#039;&#039;. (&#039;&#039;&#039;new&#039;&#039;&#039;) [[V1_8_beta4_release_notes|&#039;&#039;&#039;click here&#039;&#039;&#039;]]&lt;br /&gt;
&amp;lt;/poem&amp;gt;&lt;/div&gt;</summary>
		<author><name>Habi</name></author>
	</entry>
	<entry>
		<id>https://npc-for-vcmp.sourceforge.io/wikiw/index.php?title=Walking_man&amp;diff=1915</id>
		<title>Walking man</title>
		<link rel="alternate" type="text/html" href="https://npc-for-vcmp.sourceforge.io/wikiw/index.php?title=Walking_man&amp;diff=1915"/>
		<updated>2024-11-04T17:00:38Z</updated>

		<summary type="html">&lt;p&gt;Habi: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;poem style=&amp;quot;border: 2px solid #d6d2c5; background-color: #f9f4e6; padding: 1em;&amp;quot;&amp;gt;&lt;br /&gt;
This script uses SetAnim every 100 ms. &lt;br /&gt;
&amp;lt;/poem&amp;gt;&lt;br /&gt;
&amp;lt;poem style=&amp;quot;border: 2px solid #d6d2c5; background-color: #f9f4e6; padding: 1em;&amp;quot;&amp;gt;&lt;br /&gt;
This script requires modules: [[LibRPC]] and [[z-finder]]. &lt;br /&gt;
&amp;lt;/poem&amp;gt;&lt;br /&gt;
&amp;lt;poem style=&amp;quot;border: 2px solid #d6d2c5; background-color: #f9f4e6; padding: 1em;&amp;quot;&amp;gt;&lt;br /&gt;
This script is made as of npcclient version 1.6 beta 4 patch 1. &lt;br /&gt;
&amp;lt;/poem&amp;gt;&lt;br /&gt;
==Introduction==&lt;br /&gt;
This is a npcscript which remotely execute server functions. With the help of npc04 plugin, it dynamically creates as well as delete functions in the roottable of server. One of the function it creates on server is a timer which calls &amp;lt;source inline&amp;gt;player.SetAnim(0,0)&amp;lt;/source&amp;gt; where player is the npc, at regular intervals. At the same time it updates position from npcscript. This creates the effect that the npc is walking. &lt;br /&gt;
The npc04 plugin currently allow function calls through clientscriptdata only if the client is admin.  Hence it is required to make the walking npc an admin (&amp;lt;source inline&amp;gt;player.Admin=true&amp;lt;/source&amp;gt;) in the server.&lt;br /&gt;
&amp;lt;source lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
function onPlayerJoin( player )&lt;br /&gt;
{&lt;br /&gt;
	if(player.IsNPC &amp;amp;&amp;amp; player.IP==&amp;quot;127.0.0.1&amp;quot;) //automatically make npc admin to execute commands. ip check is important.&lt;br /&gt;
		player.IsAdmin=true;&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/source&amp;gt;&lt;br /&gt;
==Server Side==&lt;br /&gt;
1. In scripts/main.nut, connect our npc using &lt;br /&gt;
&amp;lt;source &amp;gt;ConnectNPC(&amp;quot;[npc]captain&amp;quot;, &amp;quot;walking_man.nut&amp;quot;, false, &amp;quot;&amp;quot;, &amp;quot;rpclib z-finder&amp;quot;)&amp;lt;/source&amp;gt;&lt;br /&gt;
&amp;lt;poem&amp;gt;&lt;br /&gt;
false - console off, put true - console on&lt;br /&gt;
&amp;quot;&amp;quot; - host IP, default to 127.0.0.1&lt;br /&gt;
rpclib - npc module (to be placed in npcscripts/plugins) &amp;lt;/poem&amp;gt;&lt;br /&gt;
z-finder - another module to get z co-ordinates&lt;br /&gt;
==Map File==&lt;br /&gt;
2. You need to place [https://www.mediafire.com/file/gz3cwzhrkrk4v1w/default.map/file default.map] in server directory. This map-file was previously referred as vicecity.map in this wiki&lt;br /&gt;
&lt;br /&gt;
==NPC side==&lt;br /&gt;
3. Create npcscripts/walking_man.nut&lt;br /&gt;
The following script expects &amp;quot;default.map&amp;quot; mapfile on server directory.&lt;br /&gt;
&amp;lt;source&amp;gt;&lt;br /&gt;
target&amp;lt;-null;timerid&amp;lt;-null;&lt;br /&gt;
WALK_START &amp;lt;- Vector(-872.146, -431.502, 11.5288);&lt;br /&gt;
WALK_END &amp;lt;- Vector( -870.825, -296.79, 11.173);&lt;br /&gt;
function WalkToPoint(point)&lt;br /&gt;
{&lt;br /&gt;
	target=point;&lt;br /&gt;
	if(timerid==null)&lt;br /&gt;
	{&lt;br /&gt;
		timerid=SetTimerEx(&amp;quot;step_forward&amp;quot;,100,0);&lt;br /&gt;
        //Remotely calling functions &#039;compilestring&#039; of server.&lt;br /&gt;
		RFC(F(&amp;quot;compilestring&amp;quot;)(&amp;quot;function SetWalkingAnimation(id){ local p=FindPlayer(id); if(p &amp;amp;&amp;amp; IsPlayerNPC(id))p.SetAnim(0,0);else WalkTimer&amp;quot;+GetMyID()+&amp;quot;.Delete()}&amp;quot;))();&lt;br /&gt;
		RFC(F(&amp;quot;compilestring&amp;quot;)(&amp;quot;WalkTimer&amp;quot;+GetMyID()+&amp;quot;&amp;lt;-NewTimer(\&amp;quot;SetWalkingAnimation\&amp;quot;,100,0,&amp;quot;+GetMyID()+&amp;quot;)&amp;quot;))();&lt;br /&gt;
	}&lt;br /&gt;
}&lt;br /&gt;
function onDestinationReached()&lt;br /&gt;
{&lt;br /&gt;
	if( GetDistanceFromMeToPoint( WALK_START ) &amp;lt; 2 )&lt;br /&gt;
		WalkToPoint( WALK_END );&lt;br /&gt;
	else if( GetDistanceFromMeToPoint( WALK_END ) &amp;lt; 2 )&lt;br /&gt;
	{&lt;br /&gt;
		WalkToPoint( WALK_START );&lt;br /&gt;
        //print something on server console.&lt;br /&gt;
		RFC(&amp;quot;print&amp;quot;)(&amp;quot;npc: i completed one round of patrol&amp;quot;);&lt;br /&gt;
	}&lt;br /&gt;
}&lt;br /&gt;
function step_forward()&lt;br /&gt;
{&lt;br /&gt;
	local newpos=GetMyPos()+(target-GetMyPos()).Normalised()*0.14;&lt;br /&gt;
	newpos.z=FindZFor2DCoord(newpos.x, newpos.y)+1.0425;&lt;br /&gt;
	SetLocalValue(V_POS, newpos);&lt;br /&gt;
	SetLocalValue(F_ANGLE, atan2(-(target.x-GetMyPosX()),target.y-GetMyPosY()));&lt;br /&gt;
	if((target-GetMyPos()).Length()&amp;lt;0.8)//reached destination&lt;br /&gt;
	{&lt;br /&gt;
		if(timerid!=null)&lt;br /&gt;
			KillTimer(timerid);&lt;br /&gt;
		timerid=null;&lt;br /&gt;
		//stop timer of server&lt;br /&gt;
		RFC(F(&amp;quot;compilestring&amp;quot;)(&amp;quot;WalkTimer&amp;quot;+GetMyName()+&amp;quot;.Delete()&amp;quot;))();&lt;br /&gt;
	}&lt;br /&gt;
	else SendOnFootSyncDataLV();&lt;br /&gt;
	if(timerid==null)&lt;br /&gt;
		onDestinationReached();&lt;br /&gt;
}&lt;br /&gt;
function OnNPCSpawn() &lt;br /&gt;
{ &lt;br /&gt;
	SetTimerEx(&amp;quot;SetMyPos&amp;quot;,700, 1, WALK_START );&lt;br /&gt;
//	SetMyPos(WALK_START);&lt;br /&gt;
	//print(GetMyPos());&lt;br /&gt;
	SetTimerEx(&amp;quot;WalkToPoint&amp;quot;, 1000, 1, WALK_END );&lt;br /&gt;
	//WalkToPoint( WALK_END );&lt;br /&gt;
	//Acquire weapon and skin&lt;br /&gt;
	RFC(F(&amp;quot;compilestring&amp;quot;)(&amp;quot;FindPlayer(&amp;quot;+GetMyID()+&amp;quot;).SetWeapon(4,1);&amp;quot;))();&lt;br /&gt;
	RFC(F(&amp;quot;compilestring&amp;quot;)(&amp;quot;FindPlayer(&amp;quot;+GetMyID()+&amp;quot;).Skin=1&amp;quot;))();&lt;br /&gt;
	SetTimerEx(&amp;quot;SetLocalValue&amp;quot;, 1000,1, I_CURWEP, 4);&lt;br /&gt;
}&lt;br /&gt;
function OnNPCScriptLoad(params)&lt;br /&gt;
{&lt;br /&gt;
	if(!MiamiScale_Init(&amp;quot;default.map&amp;quot;))&lt;br /&gt;
	{&lt;br /&gt;
		SendChat(&amp;quot;My map is not loaded. Bye&amp;quot;);&lt;br /&gt;
		QuitServer();&lt;br /&gt;
	}&lt;br /&gt;
}&lt;br /&gt;
function OnNPCScriptUnload()&lt;br /&gt;
{&lt;br /&gt;
	MiamiScale_Unload();&lt;br /&gt;
}&amp;lt;/source&amp;gt;&lt;br /&gt;
==Download==&lt;br /&gt;
You can download walking-man complete server [https://www.mediafire.com/file/u7s1im22pp9dce1/walking_man.zip/file here] (mediafire ~10 MB)&lt;/div&gt;</summary>
		<author><name>Habi</name></author>
	</entry>
	<entry>
		<id>https://npc-for-vcmp.sourceforge.io/wikiw/index.php?title=Walking_man&amp;diff=1914</id>
		<title>Walking man</title>
		<link rel="alternate" type="text/html" href="https://npc-for-vcmp.sourceforge.io/wikiw/index.php?title=Walking_man&amp;diff=1914"/>
		<updated>2024-11-04T16:26:11Z</updated>

		<summary type="html">&lt;p&gt;Habi: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;poem style=&amp;quot;border: 2px solid #d6d2c5; background-color: #f9f4e6; padding: 1em;&amp;quot;&amp;gt;&lt;br /&gt;
This script uses SetAnim every 100 ms. &lt;br /&gt;
&amp;lt;/poem&amp;gt;&lt;br /&gt;
&amp;lt;poem style=&amp;quot;border: 2px solid #d6d2c5; background-color: #f9f4e6; padding: 1em;&amp;quot;&amp;gt;&lt;br /&gt;
This script requires modules: [[LibRPC]] and [[z-finder]]. &lt;br /&gt;
&amp;lt;/poem&amp;gt;&lt;br /&gt;
&amp;lt;poem style=&amp;quot;border: 2px solid #d6d2c5; background-color: #f9f4e6; padding: 1em;&amp;quot;&amp;gt;&lt;br /&gt;
This script is made as of npcclient version 1.6 beta 4 patch 1. &lt;br /&gt;
&amp;lt;/poem&amp;gt;&lt;br /&gt;
==Introduction==&lt;br /&gt;
This is a npcscript which remotely execute server functions. With the help of npc04 plugin, it dynamically creates as well as delete functions in the roottable of server. One of the function it creates on server is a timer which calls &amp;lt;source inline&amp;gt;player.SetAnim(0,0)&amp;lt;/source&amp;gt; where player is the npc, at regular intervals. At the same time it updates position from npcscript. This creates the effect that the npc is walking. &lt;br /&gt;
The npc04 plugin currently allow function calls through clientscriptdata only if the client is admin.  Hence it is required to make the walking npc an admin (&amp;lt;source inline&amp;gt;player.Admin=true&amp;lt;/source&amp;gt;) in the server.&lt;br /&gt;
&amp;lt;source lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
function onPlayerJoin( player )&lt;br /&gt;
{&lt;br /&gt;
	if(player.IsNPC &amp;amp;&amp;amp; player.IP==&amp;quot;127.0.0.1&amp;quot;) //automatically make npc admin to execute commands. ip check is important.&lt;br /&gt;
		player.IsAdmin=true;&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/source&amp;gt;&lt;br /&gt;
==Server Side==&lt;br /&gt;
1. In scripts/main.nut, connect our npc using &lt;br /&gt;
&amp;lt;source &amp;gt;ConnectNPC(&amp;quot;[npc]captain&amp;quot;, &amp;quot;walking_man.nut&amp;quot;, false, &amp;quot;&amp;quot;, &amp;quot;rpclib z-finder&amp;quot;)&amp;lt;/source&amp;gt;&lt;br /&gt;
&amp;lt;poem&amp;gt;&lt;br /&gt;
false - console off, put true - console on&lt;br /&gt;
&amp;quot;&amp;quot; - host IP, default to 127.0.0.1&lt;br /&gt;
rpclib - npc module (to be placed in npcscripts/plugins) &amp;lt;/poem&amp;gt;&lt;br /&gt;
z-finder - another module to get z co-ordinates&lt;br /&gt;
==Map File==&lt;br /&gt;
2. You need to place [https://www.mediafire.com/file/gz3cwzhrkrk4v1w/default.map/file default.map] in server directory. This map-file was previously referred as vicecity.map in this wiki&lt;br /&gt;
&lt;br /&gt;
==NPC side==&lt;br /&gt;
3. Create npcscripts/walking_man.nut&lt;br /&gt;
The following script expects &amp;quot;default.map&amp;quot; mapfile on server directory.&lt;br /&gt;
&amp;lt;source&amp;gt;&lt;br /&gt;
target&amp;lt;-null;timerid&amp;lt;-null;&lt;br /&gt;
WALK_START &amp;lt;- Vector(-872.146, -431.502, 11.5288);&lt;br /&gt;
WALK_END &amp;lt;- Vector( -870.825, -296.79, 11.173);&lt;br /&gt;
function WalkToPoint(point)&lt;br /&gt;
{&lt;br /&gt;
	target=point;&lt;br /&gt;
	if(timerid==null)&lt;br /&gt;
	{&lt;br /&gt;
		timerid=SetTimerEx(&amp;quot;step_forward&amp;quot;,100,0);&lt;br /&gt;
        //Remotely calling functions &#039;compilestring&#039; of server.&lt;br /&gt;
		RFC(F(&amp;quot;compilestring&amp;quot;)(&amp;quot;function SetWalkingAnimation(id){ local p=FindPlayer(id); if(p &amp;amp;&amp;amp; IsPlayerNPC(id))p.SetAnim(0,0);else WalkTimer&amp;quot;+GetMyID()+&amp;quot;.Delete()}&amp;quot;))();&lt;br /&gt;
		RFC(F(&amp;quot;compilestring&amp;quot;)(&amp;quot;WalkTimer&amp;quot;+GetMyID()+&amp;quot;&amp;lt;-NewTimer(\&amp;quot;SetWalkingAnimation\&amp;quot;,100,0,&amp;quot;+GetMyID()+&amp;quot;)&amp;quot;))();&lt;br /&gt;
	}&lt;br /&gt;
}&lt;br /&gt;
function onDestinationReached()&lt;br /&gt;
{&lt;br /&gt;
	if( GetDistanceFromMeToPoint( WALK_START ) &amp;lt; 2 )&lt;br /&gt;
		WalkToPoint( WALK_END );&lt;br /&gt;
	else if( GetDistanceFromMeToPoint( WALK_END ) &amp;lt; 2 )&lt;br /&gt;
	{&lt;br /&gt;
		WalkToPoint( WALK_START );&lt;br /&gt;
        //print something on server console.&lt;br /&gt;
		RFC(&amp;quot;print&amp;quot;)(&amp;quot;npc: i completed one round of patrol&amp;quot;);&lt;br /&gt;
	}&lt;br /&gt;
}&lt;br /&gt;
function step_forward()&lt;br /&gt;
{&lt;br /&gt;
	local newpos=GetMyPos()+(target-GetMyPos()).Normalised()*0.14;&lt;br /&gt;
	newpos.z=FindZFor2DCoord(newpos.x, newpos.y)+1.0425;&lt;br /&gt;
	SetLocalValue(V_POS, newpos);&lt;br /&gt;
	SetLocalValue(F_ANGLE, atan2(-(target.x-GetMyPosX()),target.y-GetMyPosY()));&lt;br /&gt;
	if((target-GetMyPos()).Length()&amp;lt;0.8)//reached destination&lt;br /&gt;
	{&lt;br /&gt;
		if(timerid!=null)&lt;br /&gt;
			KillTimer(timerid);&lt;br /&gt;
		timerid=null;&lt;br /&gt;
		//stop timer of server&lt;br /&gt;
		RFC(F(&amp;quot;compilestring&amp;quot;)(&amp;quot;WalkTimer&amp;quot;+GetMyName()+&amp;quot;.Delete()&amp;quot;))();&lt;br /&gt;
	}&lt;br /&gt;
	else SendOnFootSyncDataLV();&lt;br /&gt;
	if(timerid==null)&lt;br /&gt;
		onDestinationReached();&lt;br /&gt;
}&lt;br /&gt;
function OnNPCSpawn() &lt;br /&gt;
{ &lt;br /&gt;
	SetTimerEx(&amp;quot;SetMyPos&amp;quot;,700, 1, WALK_START );&lt;br /&gt;
//	SetMyPos(WALK_START);&lt;br /&gt;
	//print(GetMyPos());&lt;br /&gt;
	SetTimerEx(&amp;quot;WalkToPoint&amp;quot;, 1000, 1, WALK_END );&lt;br /&gt;
	//WalkToPoint( WALK_END );&lt;br /&gt;
	//Acquire weapon and skin&lt;br /&gt;
	RFC(F(&amp;quot;compilestring&amp;quot;)(&amp;quot;FindPlayer(&amp;quot;+GetMyID()+&amp;quot;).SetWeapon(4,1);&amp;quot;))();&lt;br /&gt;
	RFC(F(&amp;quot;compilestring&amp;quot;)(&amp;quot;FindPlayer(&amp;quot;+GetMyID()+&amp;quot;).Skin=1&amp;quot;))();&lt;br /&gt;
	SetTimerEx(&amp;quot;SetLocalValue&amp;quot;, 1000,1, I_CURWEP, 4);&lt;br /&gt;
}&lt;br /&gt;
function OnNPCScriptLoad(params)&lt;br /&gt;
{&lt;br /&gt;
	if(!MiamiScale_Init(&amp;quot;default.map&amp;quot;))&lt;br /&gt;
	{&lt;br /&gt;
		SendChat(&amp;quot;My map is not loaded. Bye&amp;quot;);&lt;br /&gt;
		QuitServer();&lt;br /&gt;
	}&lt;br /&gt;
}&lt;br /&gt;
function OnNPCScriptUnload()&lt;br /&gt;
{&lt;br /&gt;
	MiamiScale_Unload();&lt;br /&gt;
}&amp;lt;/source&amp;gt;&lt;/div&gt;</summary>
		<author><name>Habi</name></author>
	</entry>
	<entry>
		<id>https://npc-for-vcmp.sourceforge.io/wikiw/index.php?title=Main_Page&amp;diff=1913</id>
		<title>Main Page</title>
		<link rel="alternate" type="text/html" href="https://npc-for-vcmp.sourceforge.io/wikiw/index.php?title=Main_Page&amp;diff=1913"/>
		<updated>2024-11-04T12:44:10Z</updated>

		<summary type="html">&lt;p&gt;Habi: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;__NOEDITSECTION__ __NOTOC__&lt;br /&gt;
&amp;lt;big&amp;gt;&lt;br /&gt;
== Introduction ==&lt;br /&gt;
NPCs (Non Player Characters) or bots can be created in vcmp server. They can be created at ammunition stores, toolshop or mall. They can chat with players, send command to server. They can be used to play a previous recording like driving a car around an area repeatedly. Like normal players, they use server slot.&lt;br /&gt;
Their intelligence can be scripted in separate squirrel scripts. These scripts with &#039;artificial intelligence&#039; of NPC reside in &#039;&#039;&#039;npcscripts&#039;&#039;&#039; directory. &lt;br /&gt;
&lt;br /&gt;
Each NPC run in its own process. The NPC scripts have functions as well as callbacks. &lt;br /&gt;
&lt;br /&gt;
Since v1.5, adding an npc is simple as a call to [[ConnectNPC]] and if you do not want to give npc any artificial intelligence, the script parameter can be omitted. &lt;br /&gt;
{| style=height:1em&lt;br /&gt;
|scope=&amp;quot;col&amp;quot; style=&amp;quot;width: 300px; text-align:left; vertical-align: top;&amp;quot;| &lt;br /&gt;
== NPC script callbacks ==&lt;br /&gt;
|scope=&amp;quot;col&amp;quot; style=&amp;quot;width: 630px;vertical-align: top;&amp;quot; |  &lt;br /&gt;
== NPC script functions == &lt;br /&gt;
|scope=&amp;quot;col&amp;quot; style=&amp;quot;width: 300px;vertical-align: top;&amp;quot; | &lt;br /&gt;
==ServerData ==&lt;br /&gt;
|-style=&amp;quot;vertical-align: top;&amp;quot;&lt;br /&gt;
| &lt;br /&gt;
* [[OnNPCScriptLoad]]&lt;br /&gt;
* [[OnNPCScriptUnload]]&lt;br /&gt;
* [[OnNPCConnect]]&lt;br /&gt;
* [[OnNPCDisconnect]]&lt;br /&gt;
* [[OnNPCSpawn]]&lt;br /&gt;
* [[OnNPCEnterVehicle]]&lt;br /&gt;
* [[OnNPCExitVehicle]]&lt;br /&gt;
* [[OnClientMessage]]&lt;br /&gt;
* [[OnPlayerDeath]]&lt;br /&gt;
* [[OnPlayerText]]&lt;br /&gt;
* [[OnPlayerStreamIn]]&lt;br /&gt;
* [[OnPlayerStreamOut]]&lt;br /&gt;
* [[OnVehicleStreamIn]]&lt;br /&gt;
* [[OnVehicleStreamOut]]&lt;br /&gt;
* [[OnRecordingPlaybackEnd]]        &lt;br /&gt;
* [[OnPlayerUpdate]]&lt;br /&gt;
* [[OnSniperRifleFired]]&lt;br /&gt;
* [[OnConsoleInput]]&lt;br /&gt;
* [[OnServerData]]&lt;br /&gt;
* [[OnExplosion]]&lt;br /&gt;
* [[OnProjectileFired]]&lt;br /&gt;
* [[OnNPCClassSelect]] &lt;br /&gt;
* [[OnServerShareTick]]&lt;br /&gt;
*[[OnTimeWeatherSync]]&lt;br /&gt;
==Constants==&lt;br /&gt;
* [[Bodypart| BodyParts]]&lt;br /&gt;
* [[field| LocalValue fields]]&lt;br /&gt;
* [[Keys|Game Keys]]&lt;br /&gt;
* [[Player_States|Player States]]&lt;br /&gt;
* [[Play_Flags|Play Flags]]&lt;br /&gt;
== Classes ==&lt;br /&gt;
*[[Vector]]&lt;br /&gt;
*[[Quaternion]]&lt;br /&gt;
== Player functions ==&lt;br /&gt;
*[[GetPlayerState]]&lt;br /&gt;
*[[GetPlayerPos]]&lt;br /&gt;
*[[GetPlayerVehicleID]]&lt;br /&gt;
*[[GetPlayerArmedWeapon]]&lt;br /&gt;
*[[GetPlayerHealth]]&lt;br /&gt;
*[[GetPlayerArmour]]&lt;br /&gt;
*[[GetPlayerKeys]]&lt;br /&gt;
*[[GetPlayerFacingAngle]]&lt;br /&gt;
*[[IsPlayerInRangeOfPoint]]&lt;br /&gt;
*[[GetPlayerName]]&lt;br /&gt;
*[[IsPlayerConnected]] &lt;br /&gt;
* [[GetPlayerSkin]] &lt;br /&gt;
* [[GetPlayerTeam]] &lt;br /&gt;
* [[GetPlayerSlotWeapon]] &lt;br /&gt;
* [[GetPlayerSlotAmmo]] &lt;br /&gt;
*[[GetPlayerSpeed]]&lt;br /&gt;
*[[GetPlayerAction]] &lt;br /&gt;
* [[WhereIsPlayer]] &lt;br /&gt;
== Modules ==&lt;br /&gt;
* [[LibRPC]]&lt;br /&gt;
* [[LibAction]]&lt;br /&gt;
* [[npcmodule]] (to be renamed)&lt;br /&gt;
* [[z-finder]] &lt;br /&gt;
== v1.8 ==&lt;br /&gt;
* [[Suicide]]&lt;br /&gt;
* [[SetMyHealth]]&lt;br /&gt;
* [[GetMyHealth]]&lt;br /&gt;
* [[LookAtPos]]&lt;br /&gt;
* [[LookAtPlayer]]&lt;br /&gt;
* [[GetMyClass]]&lt;br /&gt;
* [[RequestClassAbs]]&lt;br /&gt;
* [[AmISpawned]]&lt;br /&gt;
* [[GetMySkin]]&lt;br /&gt;
* [[GetMyTeam]]&lt;br /&gt;
* [[GetMyArmour]]&lt;br /&gt;
* [[SendPrivMsg]]&lt;br /&gt;
* [[SetConfig]]&lt;br /&gt;
* [[GetPlayerColor]]&lt;br /&gt;
* [[GetMyColor]]&lt;br /&gt;
* [[IsPlaybackRunning]]&lt;br /&gt;
* [[IsPlaybackPaused]]&lt;br /&gt;
* [[InPoly]]&lt;br /&gt;
 || &lt;br /&gt;
* [[StartRecordingPlayback]]&lt;br /&gt;
* [[StopRecordingPlayback]]&lt;br /&gt;
* [[PauseRecordingPlayback]]&lt;br /&gt;
* [[ResumeRecordingPlayback]]&lt;br /&gt;
* [[SendChat]]&lt;br /&gt;
* [[SendCommand]]&lt;br /&gt;
* [[GetMyPos]]&lt;br /&gt;
* [[SetMyPos]]&lt;br /&gt;
* [[GetMyFacingAngle]]&lt;br /&gt;
* [[SetMyFacingAngle]]&lt;br /&gt;
* [[GetDistanceFromMeToPoint]]&lt;br /&gt;
* [[IsVehicleStreamedIn]]&lt;br /&gt;
* [[IsPlayerStreamedIn]]&lt;br /&gt;
* [[SelectWeapon]] (v1.6 b4p2)&lt;br /&gt;
* [[GetAvailableWeapons]]&lt;br /&gt;
* [[GetAmmoOfMyWeapon]]&lt;br /&gt;
* [[SetTimer]]&lt;br /&gt;
* [[SetTimerEx]] &lt;br /&gt;
* [[KillTimer]]&lt;br /&gt;
* [[GetMyName]] &lt;br /&gt;
* [[GetMyID]] &lt;br /&gt;
* [[QuitServer]]&lt;br /&gt;
* [[RequestClass]]&lt;br /&gt;
* [[ReqeustClassAbs]]&lt;br /&gt;
* [[RequestSpawn]]&lt;br /&gt;
* [[GetTickCount]]&lt;br /&gt;
* [[GetClosestPlayer]]&lt;br /&gt;
* [[GetSlotFromWeaponId]] &lt;br /&gt;
* [[FaceNPCToPlayer]]&lt;br /&gt;
==Advanced functions==&lt;br /&gt;
* [[SendOnFootSyncData]]&lt;br /&gt;
* [[SendOnFootSyncDataEx]]&lt;br /&gt;
* [[SendOnFootSyncDataLV]]&lt;br /&gt;
* [[SendInCarSyncData]]&lt;br /&gt;
* [[SendInCarSyncDataEx]]&lt;br /&gt;
* [[SendInCarSyncDataLV]]&lt;br /&gt;
* [[SendPassengerSyncData]]&lt;br /&gt;
* [[FireSniperRifle]]&lt;br /&gt;
* [[FireSniperRifleEx]]&lt;br /&gt;
* [[FireProjectile]]&lt;br /&gt;
* [[SendShotInfo]]&lt;br /&gt;
* [[SendDeathInfo]]&lt;br /&gt;
* [[GetLocalValue]]&lt;br /&gt;
* [[SetLocalValue]]&lt;br /&gt;
== Functions used only in server scripts==&lt;br /&gt;
* [[ConnectNPC]]&lt;br /&gt;
* [[ConnectNPCEx]]&lt;br /&gt;
* [[IsPlayerNPC]]&lt;br /&gt;
* [[ShowNPCConsole]]&lt;br /&gt;
* [[StartRecordingPlayerData]]&lt;br /&gt;
* [[StopRecordingPlayerData]]&lt;br /&gt;
* [[RFC]]&lt;br /&gt;
* [[F]]&lt;br /&gt;
* [[Examples]] (Remote calls)&lt;br /&gt;
* [[StartRecordingAllPlayerData]] (v1.8)&lt;br /&gt;
* [[StopRecordingAllPlayerData]]&lt;br /&gt;
* [[PutServerInRecordingMode]]&lt;br /&gt;
* [[StopServerInRecordingMode]]&lt;br /&gt;
* [[IsPlayerRecording]]&lt;br /&gt;
* [[IsServerInRecordingMode]]&lt;br /&gt;
* [[ConnectMultipleNpcs]]&lt;br /&gt;
* [[StopConnectingMultipleNpcs]]&lt;br /&gt;
* [[Server.cfg|server.cfg values]]&lt;br /&gt;
==Tools==&lt;br /&gt;
* [[recupdate]]&lt;br /&gt;
* [[recEdit]]&lt;br /&gt;
==0.4.7.1==&lt;br /&gt;
* [[FireBullet]]&lt;br /&gt;
* [[OnBulletFired]]&lt;br /&gt;
==Store==&lt;br /&gt;
* [[GetStoreLocation]]&lt;br /&gt;
* [[IsStoreDownloading]]&lt;br /&gt;
* [[OnStoreDownloadComplete]]&lt;br /&gt;
* [[GetStoreURL]]&lt;br /&gt;
||&lt;br /&gt;
* [[SendServerData]]&lt;br /&gt;
* [[ReadInt]]&lt;br /&gt;
* [[ReadByte]]&lt;br /&gt;
* [[ReadFloat]]&lt;br /&gt;
* [[ReadString]]&lt;br /&gt;
* [[WriteInt]]&lt;br /&gt;
*[[WriteByte]]&lt;br /&gt;
*[[WriteFloat]]&lt;br /&gt;
*[[WriteString]]&lt;br /&gt;
==Pickup==&lt;br /&gt;
*[[ClaimPickup]]&lt;br /&gt;
*[[IsPickupStreamedIn]]&lt;br /&gt;
*[[GetPickupModel]]&lt;br /&gt;
*[[GetPickupAlpha]]&lt;br /&gt;
*[[GetPickupQuantity]]&lt;br /&gt;
*[[GetPickupPos]]&lt;br /&gt;
*[[GetPickupCount]]&lt;br /&gt;
*[[OnPickupStreamIn]]&lt;br /&gt;
*[[OnPickupDestroyed]]&lt;br /&gt;
*[[OnPickupUpdate]]&lt;br /&gt;
==Checkpoint==&lt;br /&gt;
*[[OnCheckpointStreamIn]]&lt;br /&gt;
*[[OnCheckpointDestroyed]]&lt;br /&gt;
*[[OnCheckpointUpdate]]&lt;br /&gt;
*[[IsCheckpointStreamedIn]]&lt;br /&gt;
*[[GetCheckpointRadius]]&lt;br /&gt;
*[[GetCheckpointPos]]&lt;br /&gt;
*[[GetCheckpointColor]]&lt;br /&gt;
*[[IsCheckpointSphere]]&lt;br /&gt;
*[[ClaimEnterCheckpoint]]&lt;br /&gt;
*[[ClaimExitCheckpoint]]&lt;br /&gt;
*[[GetCheckpointCount]]&lt;br /&gt;
==Vehicle==&lt;br /&gt;
*[[EnterVehicle]]&lt;br /&gt;
*[[GetVehicleDriver]]&lt;br /&gt;
*[[GetVehicleModel]]&lt;br /&gt;
*[[GetVehicleTurretRot]]&lt;br /&gt;
*[[GetVehicleRotation]]&lt;br /&gt;
*[[GetVehiclePos]]&lt;br /&gt;
*[[GetVehicleSpeed]]&lt;br /&gt;
*[[GetVehicleHealth]]&lt;br /&gt;
*[[GetVehicleDamage]]&lt;br /&gt;
*[[ExitVehicle]] &lt;br /&gt;
*[[ExitVehicleEx]] &lt;br /&gt;
==Objects==&lt;br /&gt;
*[[OnObjectStreamIn]]&lt;br /&gt;
*[[OnObjectDestroyed]]&lt;br /&gt;
*[[OnObjectUpdate]]&lt;br /&gt;
*[[IsObjectStreamedIn]]&lt;br /&gt;
*[[GetObjectModel]]&lt;br /&gt;
*[[GetObjectPos]]&lt;br /&gt;
*[[GetObjectRotation]]&lt;br /&gt;
*[[GetObjectAlpha]]&lt;br /&gt;
*[[IsObjectTouchReportEnabled]]&lt;br /&gt;
*[[IsObjectShotReportEnabled]]&lt;br /&gt;
*[[ClaimObjectTouch]]&lt;br /&gt;
*[[ClaimObjectShot]]&lt;br /&gt;
*[[GetObjectCount]]&lt;br /&gt;
== More ==&lt;br /&gt;
*[[NPC Installation]]&lt;br /&gt;
* [[Squirrel Standard Library Functions]]&lt;br /&gt;
* [[NPCHide]]&lt;br /&gt;
* [[Command-line usage]]&lt;br /&gt;
* [[Attack Script]] (v1.5)&lt;br /&gt;
* [[walking_man|Walking cop script]]&lt;br /&gt;
|}&lt;br /&gt;
&amp;lt;/big&amp;gt;&lt;br /&gt;
&amp;lt;poem style=&amp;quot;border: 2px solid #d6d2c5; background-color: #19f4e6; &amp;quot;&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;04 February 2023: Hiding/Changing name of NPC In-Game New Plugin. [[NPCHide|see]]&lt;br /&gt;
&amp;lt;/poem&amp;gt;&lt;br /&gt;
&amp;lt;Poem style=&amp;quot;border: 2px solid #4682B4; background-color: #FFE4B5; &amp;quot;&amp;gt;&lt;br /&gt;
03 October 2024: NPC v1.8 Beta 3 is released. [[V1_8_beta3_release_notes|click here]]&lt;br /&gt;
&amp;lt;/poem&amp;gt;&lt;br /&gt;
&amp;lt;Poem style=&amp;quot;border: 2px solid #4682B4; background-color: #FFE4B5; &amp;quot;&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;25 October 2024: NPC v1.8 Beta 4&#039;&#039;&#039;. (&#039;&#039;&#039;new&#039;&#039;&#039;) [[V1_8_beta4_release_notes|&#039;&#039;&#039;click here&#039;&#039;&#039;]]&lt;br /&gt;
&amp;lt;/poem&amp;gt;&lt;/div&gt;</summary>
		<author><name>Habi</name></author>
	</entry>
	<entry>
		<id>https://npc-for-vcmp.sourceforge.io/wikiw/index.php?title=Main_Page&amp;diff=1912</id>
		<title>Main Page</title>
		<link rel="alternate" type="text/html" href="https://npc-for-vcmp.sourceforge.io/wikiw/index.php?title=Main_Page&amp;diff=1912"/>
		<updated>2024-11-04T12:42:53Z</updated>

		<summary type="html">&lt;p&gt;Habi: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;__NOEDITSECTION__ __NOTOC__&lt;br /&gt;
&amp;lt;big&amp;gt;&lt;br /&gt;
== Introduction ==&lt;br /&gt;
NPCs (Non Player Characters) or bots can be created in vcmp server. They can be created at ammunition stores, toolshop or mall. They can chat with players, send command to server. They can be used to play a previous recording like driving a car around an area repeatedly. Like normal players, they use server slot.&lt;br /&gt;
Their intelligence can be scripted in separate squirrel scripts. These scripts with &#039;artificial intelligence&#039; of NPC reside in &#039;&#039;&#039;npcscripts&#039;&#039;&#039; directory. &lt;br /&gt;
&lt;br /&gt;
Each NPC run in its own process. The NPC scripts have functions as well as callbacks. &lt;br /&gt;
&lt;br /&gt;
Since v1.5, adding an npc is simple as a call to [[ConnectNPC]] and if you do not want to give npc any artificial intelligence, the script parameter can be omitted. &lt;br /&gt;
{| style=height:1em&lt;br /&gt;
|scope=&amp;quot;col&amp;quot; style=&amp;quot;width: 300px; text-align:left; vertical-align: top;&amp;quot;| &lt;br /&gt;
== NPC script callbacks ==&lt;br /&gt;
|scope=&amp;quot;col&amp;quot; style=&amp;quot;width: 630px;vertical-align: top;&amp;quot; |  &lt;br /&gt;
== NPC script functions == &lt;br /&gt;
|scope=&amp;quot;col&amp;quot; style=&amp;quot;width: 300px;vertical-align: top;&amp;quot; | &lt;br /&gt;
==ServerData ==&lt;br /&gt;
|-style=&amp;quot;vertical-align: top;&amp;quot;&lt;br /&gt;
| &lt;br /&gt;
* [[OnNPCScriptLoad]]&lt;br /&gt;
* [[OnNPCScriptUnload]]&lt;br /&gt;
* [[OnNPCConnect]]&lt;br /&gt;
* [[OnNPCDisconnect]]&lt;br /&gt;
* [[OnNPCSpawn]]&lt;br /&gt;
* [[OnNPCEnterVehicle]]&lt;br /&gt;
* [[OnNPCExitVehicle]]&lt;br /&gt;
* [[OnClientMessage]]&lt;br /&gt;
* [[OnPlayerDeath]]&lt;br /&gt;
* [[OnPlayerText]]&lt;br /&gt;
* [[OnPlayerStreamIn]]&lt;br /&gt;
* [[OnPlayerStreamOut]]&lt;br /&gt;
* [[OnVehicleStreamIn]]&lt;br /&gt;
* [[OnVehicleStreamOut]]&lt;br /&gt;
* [[OnRecordingPlaybackEnd]]        &lt;br /&gt;
* [[OnPlayerUpdate]]&lt;br /&gt;
* [[OnSniperRifleFired]]&lt;br /&gt;
* [[OnConsoleInput]]&lt;br /&gt;
* [[OnServerData]]&lt;br /&gt;
* [[OnExplosion]]&lt;br /&gt;
* [[OnProjectileFired]]&lt;br /&gt;
* [[OnNPCClassSelect]] &lt;br /&gt;
* [[OnServerShareTick]]&lt;br /&gt;
*[[OnTimeWeatherSync]]&lt;br /&gt;
==Constants==&lt;br /&gt;
* [[Bodypart| BodyParts]]&lt;br /&gt;
* [[field| LocalValue fields]]&lt;br /&gt;
* [[Keys|Game Keys]]&lt;br /&gt;
* [[Player_States|Player States]]&lt;br /&gt;
* [[Play_Flags|Play Flags]]&lt;br /&gt;
== Classes ==&lt;br /&gt;
*[[Vector]]&lt;br /&gt;
*[[Quaternion]]&lt;br /&gt;
== Player functions ==&lt;br /&gt;
*[[GetPlayerState]]&lt;br /&gt;
*[[GetPlayerPos]]&lt;br /&gt;
*[[GetPlayerVehicleID]]&lt;br /&gt;
*[[GetPlayerArmedWeapon]]&lt;br /&gt;
*[[GetPlayerHealth]]&lt;br /&gt;
*[[GetPlayerArmour]]&lt;br /&gt;
*[[GetPlayerKeys]]&lt;br /&gt;
*[[GetPlayerFacingAngle]]&lt;br /&gt;
*[[IsPlayerInRangeOfPoint]]&lt;br /&gt;
*[[GetPlayerName]]&lt;br /&gt;
*[[IsPlayerConnected]] &lt;br /&gt;
* [[GetPlayerSkin]] &lt;br /&gt;
* [[GetPlayerTeam]] &lt;br /&gt;
* [[GetPlayerSlotWeapon]] &lt;br /&gt;
* [[GetPlayerSlotAmmo]] &lt;br /&gt;
*[[GetPlayerSpeed]]&lt;br /&gt;
*[[GetPlayerAction]] &lt;br /&gt;
* [[WhereIsPlayer]] &lt;br /&gt;
== Modules ==&lt;br /&gt;
* [[LibRPC]]&lt;br /&gt;
* [[LibAction]]&lt;br /&gt;
* [[npcmodule]] (to be renamed)&lt;br /&gt;
* [[z-finder]] &lt;br /&gt;
== v1.8 ==&lt;br /&gt;
* [[Suicide]]&lt;br /&gt;
* [[SetMyHealth]]&lt;br /&gt;
* [[GetMyHealth]]&lt;br /&gt;
* [[LookAtPos]]&lt;br /&gt;
* [[LookAtPlayer]]&lt;br /&gt;
* [[GetMyClass]]&lt;br /&gt;
* [[RequestClassAbs]]&lt;br /&gt;
* [[AmISpawned]]&lt;br /&gt;
* [[GetMySkin]]&lt;br /&gt;
* [[GetMyTeam]]&lt;br /&gt;
* [[GetMyArmour]]&lt;br /&gt;
* [[SendPrivMsg]]&lt;br /&gt;
* [[SetConfig]]&lt;br /&gt;
* [[GetPlayerColor]]&lt;br /&gt;
* [[GetMyColor]]&lt;br /&gt;
* [[IsPlaybackRunning]]&lt;br /&gt;
* [[IsPlaybackPaused]]&lt;br /&gt;
* [[InPoly]]&lt;br /&gt;
 || &lt;br /&gt;
* [[StartRecordingPlayback]]&lt;br /&gt;
* [[StopRecordingPlayback]]&lt;br /&gt;
* [[PauseRecordingPlayback]]&lt;br /&gt;
* [[ResumeRecordingPlayback]]&lt;br /&gt;
* [[SendChat]]&lt;br /&gt;
* [[SendCommand]]&lt;br /&gt;
* [[GetMyPos]]&lt;br /&gt;
* [[SetMyPos]]&lt;br /&gt;
* [[GetMyFacingAngle]]&lt;br /&gt;
* [[SetMyFacingAngle]]&lt;br /&gt;
* [[GetDistanceFromMeToPoint]]&lt;br /&gt;
* [[IsVehicleStreamedIn]]&lt;br /&gt;
* [[IsPlayerStreamedIn]]&lt;br /&gt;
* [[SelectWeapon]] (v1.6 b4p2)&lt;br /&gt;
* [[GetAvailableWeapons]]&lt;br /&gt;
* [[GetAmmoOfMyWeapon]]&lt;br /&gt;
* [[SetTimer]]&lt;br /&gt;
* [[SetTimerEx]] &lt;br /&gt;
* [[KillTimer]]&lt;br /&gt;
* [[GetMyName]] &lt;br /&gt;
* [[GetMyID]] &lt;br /&gt;
* [[QuitServer]]&lt;br /&gt;
* [[RequestClass]]&lt;br /&gt;
* [[ReqeustClassAbs]]&lt;br /&gt;
* [[RequestSpawn]]&lt;br /&gt;
* [[GetTickCount]]&lt;br /&gt;
* [[GetClosestPlayer]]&lt;br /&gt;
* [[GetSlotFromWeaponId]] &lt;br /&gt;
* [[FaceNPCToPlayer]]&lt;br /&gt;
==Advanced functions==&lt;br /&gt;
* [[SendOnFootSyncData]]&lt;br /&gt;
* [[SendOnFootSyncDataEx]]&lt;br /&gt;
* [[SendOnFootSyncDataLV]]&lt;br /&gt;
* [[SendInCarSyncData]]&lt;br /&gt;
* [[SendInCarSyncDataEx]]&lt;br /&gt;
* [[SendInCarSyncDataLV]]&lt;br /&gt;
* [[SendPassengerSyncData]]&lt;br /&gt;
* [[FireSniperRifle]]&lt;br /&gt;
* [[FireSniperRifleEx]]&lt;br /&gt;
* [[FireProjectile]]&lt;br /&gt;
* [[SendShotInfo]]&lt;br /&gt;
* [[SendDeathInfo]]&lt;br /&gt;
* [[GetLocalValue]]&lt;br /&gt;
* [[SetLocalValue]]&lt;br /&gt;
== Functions used only in server scripts==&lt;br /&gt;
* [[ConnectNPC]]&lt;br /&gt;
* [[ConnectNPCEx]]&lt;br /&gt;
* [[IsPlayerNPC]]&lt;br /&gt;
* [[ShowNPCConsole]]&lt;br /&gt;
* [[StartRecordingPlayerData]]&lt;br /&gt;
* [[StopRecordingPlayerData]]&lt;br /&gt;
* [[RFC]]&lt;br /&gt;
* [[F]]&lt;br /&gt;
* [[Examples]] (Remote calls)&lt;br /&gt;
* [[StartRecordingAllPlayerData]] (v1.8)&lt;br /&gt;
* [[StopRecordingAllPlayerData]]&lt;br /&gt;
* [[PutServerInRecordingMode]]&lt;br /&gt;
* [[StopServerInRecordingMode]]&lt;br /&gt;
* [[IsPlayerRecording]]&lt;br /&gt;
* [[IsServerInRecordingMode]]&lt;br /&gt;
* [[ConnectMultipleNpcs]]&lt;br /&gt;
* [[StopConnectingMultipleNpcs]]&lt;br /&gt;
* [[Server.cfg|server.cfg values]]&lt;br /&gt;
==Tools==&lt;br /&gt;
* [[recupdate]]&lt;br /&gt;
* [[recEdit]]&lt;br /&gt;
==0.4.7.1==&lt;br /&gt;
* [[FireBullet]]&lt;br /&gt;
* [[OnBulletFired]]&lt;br /&gt;
==Store==&lt;br /&gt;
* [[GetStoreLocation]]&lt;br /&gt;
* [[IsStoreDownloading]]&lt;br /&gt;
* [[OnStoreDownloadComplete]]&lt;br /&gt;
* [[GetStoreURL]]&lt;br /&gt;
||&lt;br /&gt;
* [[SendServerData]]&lt;br /&gt;
* [[ReadInt]]&lt;br /&gt;
* [[ReadByte]]&lt;br /&gt;
* [[ReadFloat]]&lt;br /&gt;
* [[ReadString]]&lt;br /&gt;
* [[WriteInt]]&lt;br /&gt;
*[[WriteByte]]&lt;br /&gt;
*[[WriteFloat]]&lt;br /&gt;
*[[WriteString]]&lt;br /&gt;
==Pickup==&lt;br /&gt;
*[[ClaimPickup]]&lt;br /&gt;
*[[IsPickupStreamedIn]]&lt;br /&gt;
*[[GetPickupModel]]&lt;br /&gt;
*[[GetPickupAlpha]]&lt;br /&gt;
*[[GetPickupQuantity]]&lt;br /&gt;
*[[GetPickupPos]]&lt;br /&gt;
*[[GetPickupCount]]&lt;br /&gt;
*[[OnPickupStreamIn]]&lt;br /&gt;
*[[OnPickupDestroyed]]&lt;br /&gt;
*[[OnPickupUpdate]]&lt;br /&gt;
==Checkpoint==&lt;br /&gt;
*[[OnCheckpointStreamIn]]&lt;br /&gt;
*[[OnCheckpointDestroyed]]&lt;br /&gt;
*[[OnCheckpointUpdate]]&lt;br /&gt;
*[[IsCheckpointStreamedIn]]&lt;br /&gt;
*[[GetCheckpointRadius]]&lt;br /&gt;
*[[GetCheckpointPos]]&lt;br /&gt;
*[[GetCheckpointColor]]&lt;br /&gt;
*[[IsCheckpointSphere]]&lt;br /&gt;
*[[ClaimEnterCheckpoint]]&lt;br /&gt;
*[[ClaimExitCheckpoint]]&lt;br /&gt;
*[[GetCheckpointCount]]&lt;br /&gt;
==Vehicle==&lt;br /&gt;
*[[EnterVehicle]]&lt;br /&gt;
*[[GetVehicleDriver]]&lt;br /&gt;
*[[GetVehicleModel]]&lt;br /&gt;
*[[GetVehicleTurretRot]]&lt;br /&gt;
*[[GetVehicleRotation]]&lt;br /&gt;
*[[GetVehiclePos]]&lt;br /&gt;
*[[GetVehicleSpeed]]&lt;br /&gt;
*[[GetVehicleHealth]]&lt;br /&gt;
*[[GetVehicleDamage]]&lt;br /&gt;
*[[ExitVehicle]] &lt;br /&gt;
*[[ExitVehicleEx]] &lt;br /&gt;
==Objects==&lt;br /&gt;
*[[OnObjectStreamIn]]&lt;br /&gt;
*[[OnObjectDestroyed]]&lt;br /&gt;
*[[OnObjectUpdate]]&lt;br /&gt;
*[[IsObjectStreamedIn]]&lt;br /&gt;
*[[GetObjectModel]]&lt;br /&gt;
*[[GetObjectPos]]&lt;br /&gt;
*[[GetObjectRotation]]&lt;br /&gt;
*[[GetObjectAlpha]]&lt;br /&gt;
*[[IsObjectTouchReportEnabled]]&lt;br /&gt;
*[[IsObjectShotReportEnabled]]&lt;br /&gt;
*[[ClaimObjectTouch]]&lt;br /&gt;
*[[ClaimObjectShot]]&lt;br /&gt;
*[[GetObjectCount]]&lt;br /&gt;
== More ==&lt;br /&gt;
*[[NPC Installation]]&lt;br /&gt;
* [[Squirrel Standard Library Functions]]&lt;br /&gt;
* [[NPCHide]]&lt;br /&gt;
* [[Command-line usage]]&lt;br /&gt;
* [[Attack Script]] (v1.5)&lt;br /&gt;
* [[walking_man|Walking cop script]]&lt;br /&gt;
|}&lt;br /&gt;
&amp;lt;/big&amp;gt;&lt;br /&gt;
&amp;lt;poem style=&amp;quot;border: 2px solid #d6d2c5; background-color: #19f4e6; &amp;quot;&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;04 February 2023: Hiding/Changing name of NPC In-Game New Plugin. [[NPCHide|see]]&lt;br /&gt;
&amp;lt;/poem&amp;gt;&lt;br /&gt;
&amp;lt;Poem style=&amp;quot;border: 2px solid #4682B4; background-color: #FFE4B5; &amp;quot;&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;03 October 2024: NPC v1.8 Beta 3 is released&#039;&#039;&#039;. [[V1_8_beta3_release_notes|&#039;&#039;&#039;click here&#039;&#039;&#039;]]&lt;br /&gt;
&amp;lt;/poem&amp;gt;&lt;br /&gt;
&amp;lt;Poem style=&amp;quot;border: 2px solid #4682B4; background-color: #FFE4B5; &amp;quot;&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;25 October 2024: NPC v1.8 Beta 4&#039;&#039;&#039;. (new) [[V1_8_beta4_release_notes|&#039;&#039;&#039;click here&#039;&#039;&#039;]]&lt;br /&gt;
&amp;lt;/poem&amp;gt;&lt;/div&gt;</summary>
		<author><name>Habi</name></author>
	</entry>
	<entry>
		<id>https://npc-for-vcmp.sourceforge.io/wikiw/index.php?title=Walking_man&amp;diff=1911</id>
		<title>Walking man</title>
		<link rel="alternate" type="text/html" href="https://npc-for-vcmp.sourceforge.io/wikiw/index.php?title=Walking_man&amp;diff=1911"/>
		<updated>2024-11-03T17:40:34Z</updated>

		<summary type="html">&lt;p&gt;Habi: /* NPC side */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;poem style=&amp;quot;border: 2px solid #d6d2c5; background-color: #f9f4e6; padding: 1em;&amp;quot;&amp;gt;&lt;br /&gt;
This script uses SetAnim every 100 ms.&lt;br /&gt;
&amp;lt;/poem&amp;gt;&lt;br /&gt;
&amp;lt;poem style=&amp;quot;border: 2px solid #d6d2c5; background-color: #f9f4e6; padding: 1em;&amp;quot;&amp;gt;&lt;br /&gt;
This script requires modules: [[LibRPC]] and [[z-finder]]. &lt;br /&gt;
&amp;lt;/poem&amp;gt;&lt;br /&gt;
&amp;lt;poem style=&amp;quot;border: 2px solid #d6d2c5; background-color: #f9f4e6; padding: 1em;&amp;quot;&amp;gt;&lt;br /&gt;
This script is made as of npcclient version 1.6 beta 4 patch 1. &lt;br /&gt;
&amp;lt;/poem&amp;gt;&lt;br /&gt;
==Server Side==&lt;br /&gt;
1. In scripts/main.nut, connect our npc using &lt;br /&gt;
&amp;lt;source &amp;gt;ConnectNPC(&amp;quot;[npc]captain&amp;quot;, &amp;quot;walking_man.nut&amp;quot;, false, &amp;quot;&amp;quot;, &amp;quot;rpclib z-finder&amp;quot;)&amp;lt;/source&amp;gt;&lt;br /&gt;
&amp;lt;poem&amp;gt;&lt;br /&gt;
false - console off, put true - console on&lt;br /&gt;
&amp;quot;&amp;quot; - host IP, default to 127.0.0.1&lt;br /&gt;
rpclib - npc module (to be placed in npcscripts/plugins) &amp;lt;/poem&amp;gt;&lt;br /&gt;
z-finder - another module to get z co-ordinates&lt;br /&gt;
==Map File==&lt;br /&gt;
2. You need to place [https://www.mediafire.com/file/gz3cwzhrkrk4v1w/default.map/file default.map] in server directory. This map-file was previously referred as vicecity.map in this wiki&lt;br /&gt;
&lt;br /&gt;
==NPC side==&lt;br /&gt;
3. Create npcscripts/walking_man.nut&lt;br /&gt;
The following script expects &amp;quot;default.map&amp;quot; mapfile on server directory.&lt;br /&gt;
&amp;lt;source&amp;gt;&lt;br /&gt;
target&amp;lt;-null;timerid&amp;lt;-null;&lt;br /&gt;
WALK_START &amp;lt;- Vector(-872.146, -431.502, 11.5288);&lt;br /&gt;
WALK_END &amp;lt;- Vector( -870.825, -296.79, 11.173);&lt;br /&gt;
function WalkToPoint(point)&lt;br /&gt;
{&lt;br /&gt;
	target=point;&lt;br /&gt;
	if(timerid==null)&lt;br /&gt;
	{&lt;br /&gt;
		timerid=SetTimerEx(&amp;quot;step_forward&amp;quot;,100,0);&lt;br /&gt;
        //Remotely calling functions &#039;compilestring&#039; of server.&lt;br /&gt;
		RFC(F(&amp;quot;compilestring&amp;quot;)(&amp;quot;function SetWalkingAnimation(id){ local p=FindPlayer(id); if(p &amp;amp;&amp;amp; IsPlayerNPC(id))p.SetAnim(0,0);else WalkTimer&amp;quot;+GetMyID()+&amp;quot;.Delete()}&amp;quot;))();&lt;br /&gt;
		RFC(F(&amp;quot;compilestring&amp;quot;)(&amp;quot;WalkTimer&amp;quot;+GetMyID()+&amp;quot;&amp;lt;-NewTimer(\&amp;quot;SetWalkingAnimation\&amp;quot;,100,0,&amp;quot;+GetMyID()+&amp;quot;)&amp;quot;))();&lt;br /&gt;
	}&lt;br /&gt;
}&lt;br /&gt;
function onDestinationReached()&lt;br /&gt;
{&lt;br /&gt;
	if( GetDistanceFromMeToPoint( WALK_START ) &amp;lt; 2 )&lt;br /&gt;
		WalkToPoint( WALK_END );&lt;br /&gt;
	else if( GetDistanceFromMeToPoint( WALK_END ) &amp;lt; 2 )&lt;br /&gt;
	{&lt;br /&gt;
		WalkToPoint( WALK_START );&lt;br /&gt;
        //print something on server console.&lt;br /&gt;
		RFC(&amp;quot;print&amp;quot;)(&amp;quot;npc: i completed one round of patrol&amp;quot;);&lt;br /&gt;
	}&lt;br /&gt;
}&lt;br /&gt;
function step_forward()&lt;br /&gt;
{&lt;br /&gt;
	local newpos=GetMyPos()+(target-GetMyPos()).Normalised()*0.14;&lt;br /&gt;
	newpos.z=FindZFor2DCoord(newpos.x, newpos.y)+1.0425;&lt;br /&gt;
	SetLocalValue(V_POS, newpos);&lt;br /&gt;
	SetLocalValue(F_ANGLE, atan2(-(target.x-GetMyPosX()),target.y-GetMyPosY()));&lt;br /&gt;
	if((target-GetMyPos()).Length()&amp;lt;0.8)//reached destination&lt;br /&gt;
	{&lt;br /&gt;
		if(timerid!=null)&lt;br /&gt;
			KillTimer(timerid);&lt;br /&gt;
		timerid=null;&lt;br /&gt;
		//stop timer of server&lt;br /&gt;
		RFC(F(&amp;quot;compilestring&amp;quot;)(&amp;quot;WalkTimer&amp;quot;+GetMyName()+&amp;quot;.Delete()&amp;quot;))();&lt;br /&gt;
	}&lt;br /&gt;
	else SendOnFootSyncDataLV();&lt;br /&gt;
	if(timerid==null)&lt;br /&gt;
		onDestinationReached();&lt;br /&gt;
}&lt;br /&gt;
function OnNPCSpawn() &lt;br /&gt;
{ &lt;br /&gt;
	SetTimerEx(&amp;quot;SetMyPos&amp;quot;,700, 1, WALK_START );&lt;br /&gt;
//	SetMyPos(WALK_START);&lt;br /&gt;
	//print(GetMyPos());&lt;br /&gt;
	SetTimerEx(&amp;quot;WalkToPoint&amp;quot;, 1000, 1, WALK_END );&lt;br /&gt;
	//WalkToPoint( WALK_END );&lt;br /&gt;
	//Acquire weapon and skin&lt;br /&gt;
	RFC(F(&amp;quot;compilestring&amp;quot;)(&amp;quot;FindPlayer(&amp;quot;+GetMyID()+&amp;quot;).SetWeapon(4,1);&amp;quot;))();&lt;br /&gt;
	RFC(F(&amp;quot;compilestring&amp;quot;)(&amp;quot;FindPlayer(&amp;quot;+GetMyID()+&amp;quot;).Skin=1&amp;quot;))();&lt;br /&gt;
	SetTimerEx(&amp;quot;SetLocalValue&amp;quot;, 1000,1, I_CURWEP, 4);&lt;br /&gt;
}&lt;br /&gt;
function OnNPCScriptLoad(params)&lt;br /&gt;
{&lt;br /&gt;
	if(!MiamiScale_Init(&amp;quot;default.map&amp;quot;))&lt;br /&gt;
	{&lt;br /&gt;
		SendChat(&amp;quot;My map is not loaded. Bye&amp;quot;);&lt;br /&gt;
		QuitServer();&lt;br /&gt;
	}&lt;br /&gt;
}&lt;br /&gt;
function OnNPCScriptUnload()&lt;br /&gt;
{&lt;br /&gt;
	MiamiScale_Unload();&lt;br /&gt;
}&amp;lt;/source&amp;gt;&lt;/div&gt;</summary>
		<author><name>Habi</name></author>
	</entry>
	<entry>
		<id>https://npc-for-vcmp.sourceforge.io/wikiw/index.php?title=Walking_man&amp;diff=1910</id>
		<title>Walking man</title>
		<link rel="alternate" type="text/html" href="https://npc-for-vcmp.sourceforge.io/wikiw/index.php?title=Walking_man&amp;diff=1910"/>
		<updated>2024-11-03T17:37:34Z</updated>

		<summary type="html">&lt;p&gt;Habi: /* Map File */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;poem style=&amp;quot;border: 2px solid #d6d2c5; background-color: #f9f4e6; padding: 1em;&amp;quot;&amp;gt;&lt;br /&gt;
This script uses SetAnim every 100 ms.&lt;br /&gt;
&amp;lt;/poem&amp;gt;&lt;br /&gt;
&amp;lt;poem style=&amp;quot;border: 2px solid #d6d2c5; background-color: #f9f4e6; padding: 1em;&amp;quot;&amp;gt;&lt;br /&gt;
This script requires modules: [[LibRPC]] and [[z-finder]]. &lt;br /&gt;
&amp;lt;/poem&amp;gt;&lt;br /&gt;
&amp;lt;poem style=&amp;quot;border: 2px solid #d6d2c5; background-color: #f9f4e6; padding: 1em;&amp;quot;&amp;gt;&lt;br /&gt;
This script is made as of npcclient version 1.6 beta 4 patch 1. &lt;br /&gt;
&amp;lt;/poem&amp;gt;&lt;br /&gt;
==Server Side==&lt;br /&gt;
1. In scripts/main.nut, connect our npc using &lt;br /&gt;
&amp;lt;source &amp;gt;ConnectNPC(&amp;quot;[npc]captain&amp;quot;, &amp;quot;walking_man.nut&amp;quot;, false, &amp;quot;&amp;quot;, &amp;quot;rpclib z-finder&amp;quot;)&amp;lt;/source&amp;gt;&lt;br /&gt;
&amp;lt;poem&amp;gt;&lt;br /&gt;
false - console off, put true - console on&lt;br /&gt;
&amp;quot;&amp;quot; - host IP, default to 127.0.0.1&lt;br /&gt;
rpclib - npc module (to be placed in npcscripts/plugins) &amp;lt;/poem&amp;gt;&lt;br /&gt;
z-finder - another module to get z co-ordinates&lt;br /&gt;
==Map File==&lt;br /&gt;
2. You need to place [https://www.mediafire.com/file/gz3cwzhrkrk4v1w/default.map/file default.map] in server directory. This map-file was previously referred as vicecity.map in this wiki&lt;br /&gt;
&lt;br /&gt;
==NPC side==&lt;br /&gt;
3. Create npcscripts/walking_man.nut&lt;br /&gt;
The following script expects &amp;quot;default.map&amp;quot; mapfile on server directory.&lt;br /&gt;
&amp;lt;source&amp;gt;&lt;br /&gt;
target&amp;lt;-null;timerid&amp;lt;-null;&lt;br /&gt;
WALK_START &amp;lt;- Vector(-872.146, -431.502, 11.5288);&lt;br /&gt;
WALK_END &amp;lt;- Vector( -870.825, -296.79, 11.173);&lt;br /&gt;
function WalkToPoint(point)&lt;br /&gt;
{&lt;br /&gt;
	target=point;&lt;br /&gt;
	if(timerid==null)&lt;br /&gt;
	{&lt;br /&gt;
		timerid=SetTimerEx(&amp;quot;step_forward&amp;quot;,100,0);&lt;br /&gt;
        //Remotely calling functions &#039;compilestring&#039; of server.&lt;br /&gt;
		RFC(F(&amp;quot;compilestring&amp;quot;)(&amp;quot;function SetWalkingAnimation(id){ local p=FindPlayer(id); if(p &amp;amp;&amp;amp; IsPlayerNPC(id))p.SetAnim(0,0);else WalkTimer&amp;quot;+GetMyID()+&amp;quot;.Delete()}&amp;quot;))();&lt;br /&gt;
		RFC(F(&amp;quot;compilestring&amp;quot;)(&amp;quot;WalkTimer&amp;quot;+GetMyID()+&amp;quot;&amp;lt;-NewTimer(\&amp;quot;SetWalkingAnimation\&amp;quot;,100,0,&amp;quot;+GetMyID()+&amp;quot;)&amp;quot;))();&lt;br /&gt;
	}&lt;br /&gt;
}&lt;br /&gt;
function onDestinationReached()&lt;br /&gt;
{&lt;br /&gt;
	if( GetDistanceFromMeToPoint( WALK_START ) &amp;lt; 2 )&lt;br /&gt;
		WalkToPoint( WALK_END );&lt;br /&gt;
	else if( GetDistanceFromMeToPoint( WALK_END ) &amp;lt; 2 )&lt;br /&gt;
	{&lt;br /&gt;
		WalkToPoint( WALK_START );&lt;br /&gt;
        //print something on server console.&lt;br /&gt;
		RFC(&amp;quot;print&amp;quot;)(&amp;quot;npc: i completed one round of patrol&amp;quot;);&lt;br /&gt;
	}&lt;br /&gt;
}&lt;br /&gt;
function step_forward()&lt;br /&gt;
{&lt;br /&gt;
	local newpos=GetMyPos()+(target-GetMyPos()).Normalised()*0.14;&lt;br /&gt;
	newpos.z=FindZFor2DCoord(newpos.x, newpos.y)+1.0425;&lt;br /&gt;
	SetLocalValue(V_POS, newpos);&lt;br /&gt;
	SetLocalValue(F_ANGLE, atan2(-(target.x-GetMyPosX()),target.y-GetMyPosY()));&lt;br /&gt;
	if((target-GetMyPos()).Length()&amp;lt;0.8)//reached destination&lt;br /&gt;
	{&lt;br /&gt;
		if(timerid!=null)&lt;br /&gt;
			KillTimer(timerid);&lt;br /&gt;
		timerid=null;&lt;br /&gt;
		//stop timer of server&lt;br /&gt;
		RFC(F(&amp;quot;compilestring&amp;quot;)(&amp;quot;WalkTimer&amp;quot;+GetMyName()+&amp;quot;.Delete()&amp;quot;))();&lt;br /&gt;
	}&lt;br /&gt;
	else SendOnFootSyncDataLV();&lt;br /&gt;
	if(timerid==null)&lt;br /&gt;
		onDestinationReached();&lt;br /&gt;
}&lt;br /&gt;
function OnNPCSpawn() &lt;br /&gt;
{ &lt;br /&gt;
	SetTimerEx(&amp;quot;SetMyPos&amp;quot;,700, 1, WALK_START );&lt;br /&gt;
//	SetMyPos(WALK_START);&lt;br /&gt;
	print(GetMyPos());&lt;br /&gt;
	SetTimerEx(&amp;quot;WalkToPoint&amp;quot;, 1000, 1, WALK_END );&lt;br /&gt;
	//WalkToPoint( WALK_END );&lt;br /&gt;
	//Acquire weapon and skin&lt;br /&gt;
	RFC(F(&amp;quot;compilestring&amp;quot;)(&amp;quot;FindPlayer(&amp;quot;+GetMyID()+&amp;quot;).SetWeapon(4,1);&amp;quot;))();&lt;br /&gt;
	RFC(F(&amp;quot;compilestring&amp;quot;)(&amp;quot;FindPlayer(&amp;quot;+GetMyID()+&amp;quot;).Skin=1&amp;quot;))();&lt;br /&gt;
	SetTimerEx(&amp;quot;SetLocalValue&amp;quot;, 1000,1, I_CURWEP, 4);&lt;br /&gt;
}&lt;br /&gt;
function OnNPCScriptLoad(params)&lt;br /&gt;
{&lt;br /&gt;
	if(!MiamiScale_Init(&amp;quot;default.map&amp;quot;))&lt;br /&gt;
	{&lt;br /&gt;
		SendChat(&amp;quot;My map is not loaded. Bye&amp;quot;);&lt;br /&gt;
		QuitServer();&lt;br /&gt;
	}&lt;br /&gt;
}&lt;br /&gt;
function OnNPCScriptUnload()&lt;br /&gt;
{&lt;br /&gt;
	MiamiScale_Unload();&lt;br /&gt;
}&amp;lt;/source&amp;gt;&lt;/div&gt;</summary>
		<author><name>Habi</name></author>
	</entry>
	<entry>
		<id>https://npc-for-vcmp.sourceforge.io/wikiw/index.php?title=Walking_man&amp;diff=1909</id>
		<title>Walking man</title>
		<link rel="alternate" type="text/html" href="https://npc-for-vcmp.sourceforge.io/wikiw/index.php?title=Walking_man&amp;diff=1909"/>
		<updated>2024-11-03T17:36:50Z</updated>

		<summary type="html">&lt;p&gt;Habi: /* Map File */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;poem style=&amp;quot;border: 2px solid #d6d2c5; background-color: #f9f4e6; padding: 1em;&amp;quot;&amp;gt;&lt;br /&gt;
This script uses SetAnim every 100 ms.&lt;br /&gt;
&amp;lt;/poem&amp;gt;&lt;br /&gt;
&amp;lt;poem style=&amp;quot;border: 2px solid #d6d2c5; background-color: #f9f4e6; padding: 1em;&amp;quot;&amp;gt;&lt;br /&gt;
This script requires modules: [[LibRPC]] and [[z-finder]]. &lt;br /&gt;
&amp;lt;/poem&amp;gt;&lt;br /&gt;
&amp;lt;poem style=&amp;quot;border: 2px solid #d6d2c5; background-color: #f9f4e6; padding: 1em;&amp;quot;&amp;gt;&lt;br /&gt;
This script is made as of npcclient version 1.6 beta 4 patch 1. &lt;br /&gt;
&amp;lt;/poem&amp;gt;&lt;br /&gt;
==Server Side==&lt;br /&gt;
1. In scripts/main.nut, connect our npc using &lt;br /&gt;
&amp;lt;source &amp;gt;ConnectNPC(&amp;quot;[npc]captain&amp;quot;, &amp;quot;walking_man.nut&amp;quot;, false, &amp;quot;&amp;quot;, &amp;quot;rpclib z-finder&amp;quot;)&amp;lt;/source&amp;gt;&lt;br /&gt;
&amp;lt;poem&amp;gt;&lt;br /&gt;
false - console off, put true - console on&lt;br /&gt;
&amp;quot;&amp;quot; - host IP, default to 127.0.0.1&lt;br /&gt;
rpclib - npc module (to be placed in npcscripts/plugins) &amp;lt;/poem&amp;gt;&lt;br /&gt;
z-finder - another module to get z co-ordinates&lt;br /&gt;
==Map File==&lt;br /&gt;
2. You need to place [https://www.mediafire.com/file/gz3cwzhrkrk4v1w/default.map/file default.map] in server directory. default.map was previously called vicecity.map&lt;br /&gt;
&lt;br /&gt;
==NPC side==&lt;br /&gt;
3. Create npcscripts/walking_man.nut&lt;br /&gt;
The following script expects &amp;quot;default.map&amp;quot; mapfile on server directory.&lt;br /&gt;
&amp;lt;source&amp;gt;&lt;br /&gt;
target&amp;lt;-null;timerid&amp;lt;-null;&lt;br /&gt;
WALK_START &amp;lt;- Vector(-872.146, -431.502, 11.5288);&lt;br /&gt;
WALK_END &amp;lt;- Vector( -870.825, -296.79, 11.173);&lt;br /&gt;
function WalkToPoint(point)&lt;br /&gt;
{&lt;br /&gt;
	target=point;&lt;br /&gt;
	if(timerid==null)&lt;br /&gt;
	{&lt;br /&gt;
		timerid=SetTimerEx(&amp;quot;step_forward&amp;quot;,100,0);&lt;br /&gt;
        //Remotely calling functions &#039;compilestring&#039; of server.&lt;br /&gt;
		RFC(F(&amp;quot;compilestring&amp;quot;)(&amp;quot;function SetWalkingAnimation(id){ local p=FindPlayer(id); if(p &amp;amp;&amp;amp; IsPlayerNPC(id))p.SetAnim(0,0);else WalkTimer&amp;quot;+GetMyID()+&amp;quot;.Delete()}&amp;quot;))();&lt;br /&gt;
		RFC(F(&amp;quot;compilestring&amp;quot;)(&amp;quot;WalkTimer&amp;quot;+GetMyID()+&amp;quot;&amp;lt;-NewTimer(\&amp;quot;SetWalkingAnimation\&amp;quot;,100,0,&amp;quot;+GetMyID()+&amp;quot;)&amp;quot;))();&lt;br /&gt;
	}&lt;br /&gt;
}&lt;br /&gt;
function onDestinationReached()&lt;br /&gt;
{&lt;br /&gt;
	if( GetDistanceFromMeToPoint( WALK_START ) &amp;lt; 2 )&lt;br /&gt;
		WalkToPoint( WALK_END );&lt;br /&gt;
	else if( GetDistanceFromMeToPoint( WALK_END ) &amp;lt; 2 )&lt;br /&gt;
	{&lt;br /&gt;
		WalkToPoint( WALK_START );&lt;br /&gt;
        //print something on server console.&lt;br /&gt;
		RFC(&amp;quot;print&amp;quot;)(&amp;quot;npc: i completed one round of patrol&amp;quot;);&lt;br /&gt;
	}&lt;br /&gt;
}&lt;br /&gt;
function step_forward()&lt;br /&gt;
{&lt;br /&gt;
	local newpos=GetMyPos()+(target-GetMyPos()).Normalised()*0.14;&lt;br /&gt;
	newpos.z=FindZFor2DCoord(newpos.x, newpos.y)+1.0425;&lt;br /&gt;
	SetLocalValue(V_POS, newpos);&lt;br /&gt;
	SetLocalValue(F_ANGLE, atan2(-(target.x-GetMyPosX()),target.y-GetMyPosY()));&lt;br /&gt;
	if((target-GetMyPos()).Length()&amp;lt;0.8)//reached destination&lt;br /&gt;
	{&lt;br /&gt;
		if(timerid!=null)&lt;br /&gt;
			KillTimer(timerid);&lt;br /&gt;
		timerid=null;&lt;br /&gt;
		//stop timer of server&lt;br /&gt;
		RFC(F(&amp;quot;compilestring&amp;quot;)(&amp;quot;WalkTimer&amp;quot;+GetMyName()+&amp;quot;.Delete()&amp;quot;))();&lt;br /&gt;
	}&lt;br /&gt;
	else SendOnFootSyncDataLV();&lt;br /&gt;
	if(timerid==null)&lt;br /&gt;
		onDestinationReached();&lt;br /&gt;
}&lt;br /&gt;
function OnNPCSpawn() &lt;br /&gt;
{ &lt;br /&gt;
	SetTimerEx(&amp;quot;SetMyPos&amp;quot;,700, 1, WALK_START );&lt;br /&gt;
//	SetMyPos(WALK_START);&lt;br /&gt;
	print(GetMyPos());&lt;br /&gt;
	SetTimerEx(&amp;quot;WalkToPoint&amp;quot;, 1000, 1, WALK_END );&lt;br /&gt;
	//WalkToPoint( WALK_END );&lt;br /&gt;
	//Acquire weapon and skin&lt;br /&gt;
	RFC(F(&amp;quot;compilestring&amp;quot;)(&amp;quot;FindPlayer(&amp;quot;+GetMyID()+&amp;quot;).SetWeapon(4,1);&amp;quot;))();&lt;br /&gt;
	RFC(F(&amp;quot;compilestring&amp;quot;)(&amp;quot;FindPlayer(&amp;quot;+GetMyID()+&amp;quot;).Skin=1&amp;quot;))();&lt;br /&gt;
	SetTimerEx(&amp;quot;SetLocalValue&amp;quot;, 1000,1, I_CURWEP, 4);&lt;br /&gt;
}&lt;br /&gt;
function OnNPCScriptLoad(params)&lt;br /&gt;
{&lt;br /&gt;
	if(!MiamiScale_Init(&amp;quot;default.map&amp;quot;))&lt;br /&gt;
	{&lt;br /&gt;
		SendChat(&amp;quot;My map is not loaded. Bye&amp;quot;);&lt;br /&gt;
		QuitServer();&lt;br /&gt;
	}&lt;br /&gt;
}&lt;br /&gt;
function OnNPCScriptUnload()&lt;br /&gt;
{&lt;br /&gt;
	MiamiScale_Unload();&lt;br /&gt;
}&amp;lt;/source&amp;gt;&lt;/div&gt;</summary>
		<author><name>Habi</name></author>
	</entry>
	<entry>
		<id>https://npc-for-vcmp.sourceforge.io/wikiw/index.php?title=Walking_man&amp;diff=1908</id>
		<title>Walking man</title>
		<link rel="alternate" type="text/html" href="https://npc-for-vcmp.sourceforge.io/wikiw/index.php?title=Walking_man&amp;diff=1908"/>
		<updated>2024-11-03T17:35:21Z</updated>

		<summary type="html">&lt;p&gt;Habi: /* NPC side */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;poem style=&amp;quot;border: 2px solid #d6d2c5; background-color: #f9f4e6; padding: 1em;&amp;quot;&amp;gt;&lt;br /&gt;
This script uses SetAnim every 100 ms.&lt;br /&gt;
&amp;lt;/poem&amp;gt;&lt;br /&gt;
&amp;lt;poem style=&amp;quot;border: 2px solid #d6d2c5; background-color: #f9f4e6; padding: 1em;&amp;quot;&amp;gt;&lt;br /&gt;
This script requires modules: [[LibRPC]] and [[z-finder]]. &lt;br /&gt;
&amp;lt;/poem&amp;gt;&lt;br /&gt;
&amp;lt;poem style=&amp;quot;border: 2px solid #d6d2c5; background-color: #f9f4e6; padding: 1em;&amp;quot;&amp;gt;&lt;br /&gt;
This script is made as of npcclient version 1.6 beta 4 patch 1. &lt;br /&gt;
&amp;lt;/poem&amp;gt;&lt;br /&gt;
==Server Side==&lt;br /&gt;
1. In scripts/main.nut, connect our npc using &lt;br /&gt;
&amp;lt;source &amp;gt;ConnectNPC(&amp;quot;[npc]captain&amp;quot;, &amp;quot;walking_man.nut&amp;quot;, false, &amp;quot;&amp;quot;, &amp;quot;rpclib z-finder&amp;quot;)&amp;lt;/source&amp;gt;&lt;br /&gt;
&amp;lt;poem&amp;gt;&lt;br /&gt;
false - console off, put true - console on&lt;br /&gt;
&amp;quot;&amp;quot; - host IP, default to 127.0.0.1&lt;br /&gt;
rpclib - npc module (to be placed in npcscripts/plugins) &amp;lt;/poem&amp;gt;&lt;br /&gt;
z-finder - another module to get z co-ordinates&lt;br /&gt;
==Map File==&lt;br /&gt;
2. You need to place [https://www.mediafire.com/file/gz3cwzhrkrk4v1w/default.map/file default.map] in server directory.&lt;br /&gt;
&lt;br /&gt;
==NPC side==&lt;br /&gt;
3. Create npcscripts/walking_man.nut&lt;br /&gt;
The following script expects &amp;quot;default.map&amp;quot; mapfile on server directory.&lt;br /&gt;
&amp;lt;source&amp;gt;&lt;br /&gt;
target&amp;lt;-null;timerid&amp;lt;-null;&lt;br /&gt;
WALK_START &amp;lt;- Vector(-872.146, -431.502, 11.5288);&lt;br /&gt;
WALK_END &amp;lt;- Vector( -870.825, -296.79, 11.173);&lt;br /&gt;
function WalkToPoint(point)&lt;br /&gt;
{&lt;br /&gt;
	target=point;&lt;br /&gt;
	if(timerid==null)&lt;br /&gt;
	{&lt;br /&gt;
		timerid=SetTimerEx(&amp;quot;step_forward&amp;quot;,100,0);&lt;br /&gt;
        //Remotely calling functions &#039;compilestring&#039; of server.&lt;br /&gt;
		RFC(F(&amp;quot;compilestring&amp;quot;)(&amp;quot;function SetWalkingAnimation(id){ local p=FindPlayer(id); if(p &amp;amp;&amp;amp; IsPlayerNPC(id))p.SetAnim(0,0);else WalkTimer&amp;quot;+GetMyID()+&amp;quot;.Delete()}&amp;quot;))();&lt;br /&gt;
		RFC(F(&amp;quot;compilestring&amp;quot;)(&amp;quot;WalkTimer&amp;quot;+GetMyID()+&amp;quot;&amp;lt;-NewTimer(\&amp;quot;SetWalkingAnimation\&amp;quot;,100,0,&amp;quot;+GetMyID()+&amp;quot;)&amp;quot;))();&lt;br /&gt;
	}&lt;br /&gt;
}&lt;br /&gt;
function onDestinationReached()&lt;br /&gt;
{&lt;br /&gt;
	if( GetDistanceFromMeToPoint( WALK_START ) &amp;lt; 2 )&lt;br /&gt;
		WalkToPoint( WALK_END );&lt;br /&gt;
	else if( GetDistanceFromMeToPoint( WALK_END ) &amp;lt; 2 )&lt;br /&gt;
	{&lt;br /&gt;
		WalkToPoint( WALK_START );&lt;br /&gt;
        //print something on server console.&lt;br /&gt;
		RFC(&amp;quot;print&amp;quot;)(&amp;quot;npc: i completed one round of patrol&amp;quot;);&lt;br /&gt;
	}&lt;br /&gt;
}&lt;br /&gt;
function step_forward()&lt;br /&gt;
{&lt;br /&gt;
	local newpos=GetMyPos()+(target-GetMyPos()).Normalised()*0.14;&lt;br /&gt;
	newpos.z=FindZFor2DCoord(newpos.x, newpos.y)+1.0425;&lt;br /&gt;
	SetLocalValue(V_POS, newpos);&lt;br /&gt;
	SetLocalValue(F_ANGLE, atan2(-(target.x-GetMyPosX()),target.y-GetMyPosY()));&lt;br /&gt;
	if((target-GetMyPos()).Length()&amp;lt;0.8)//reached destination&lt;br /&gt;
	{&lt;br /&gt;
		if(timerid!=null)&lt;br /&gt;
			KillTimer(timerid);&lt;br /&gt;
		timerid=null;&lt;br /&gt;
		//stop timer of server&lt;br /&gt;
		RFC(F(&amp;quot;compilestring&amp;quot;)(&amp;quot;WalkTimer&amp;quot;+GetMyName()+&amp;quot;.Delete()&amp;quot;))();&lt;br /&gt;
	}&lt;br /&gt;
	else SendOnFootSyncDataLV();&lt;br /&gt;
	if(timerid==null)&lt;br /&gt;
		onDestinationReached();&lt;br /&gt;
}&lt;br /&gt;
function OnNPCSpawn() &lt;br /&gt;
{ &lt;br /&gt;
	SetTimerEx(&amp;quot;SetMyPos&amp;quot;,700, 1, WALK_START );&lt;br /&gt;
//	SetMyPos(WALK_START);&lt;br /&gt;
	print(GetMyPos());&lt;br /&gt;
	SetTimerEx(&amp;quot;WalkToPoint&amp;quot;, 1000, 1, WALK_END );&lt;br /&gt;
	//WalkToPoint( WALK_END );&lt;br /&gt;
	//Acquire weapon and skin&lt;br /&gt;
	RFC(F(&amp;quot;compilestring&amp;quot;)(&amp;quot;FindPlayer(&amp;quot;+GetMyID()+&amp;quot;).SetWeapon(4,1);&amp;quot;))();&lt;br /&gt;
	RFC(F(&amp;quot;compilestring&amp;quot;)(&amp;quot;FindPlayer(&amp;quot;+GetMyID()+&amp;quot;).Skin=1&amp;quot;))();&lt;br /&gt;
	SetTimerEx(&amp;quot;SetLocalValue&amp;quot;, 1000,1, I_CURWEP, 4);&lt;br /&gt;
}&lt;br /&gt;
function OnNPCScriptLoad(params)&lt;br /&gt;
{&lt;br /&gt;
	if(!MiamiScale_Init(&amp;quot;default.map&amp;quot;))&lt;br /&gt;
	{&lt;br /&gt;
		SendChat(&amp;quot;My map is not loaded. Bye&amp;quot;);&lt;br /&gt;
		QuitServer();&lt;br /&gt;
	}&lt;br /&gt;
}&lt;br /&gt;
function OnNPCScriptUnload()&lt;br /&gt;
{&lt;br /&gt;
	MiamiScale_Unload();&lt;br /&gt;
}&amp;lt;/source&amp;gt;&lt;/div&gt;</summary>
		<author><name>Habi</name></author>
	</entry>
	<entry>
		<id>https://npc-for-vcmp.sourceforge.io/wikiw/index.php?title=Walking_man&amp;diff=1907</id>
		<title>Walking man</title>
		<link rel="alternate" type="text/html" href="https://npc-for-vcmp.sourceforge.io/wikiw/index.php?title=Walking_man&amp;diff=1907"/>
		<updated>2024-11-03T17:35:02Z</updated>

		<summary type="html">&lt;p&gt;Habi: /* Map File */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;poem style=&amp;quot;border: 2px solid #d6d2c5; background-color: #f9f4e6; padding: 1em;&amp;quot;&amp;gt;&lt;br /&gt;
This script uses SetAnim every 100 ms.&lt;br /&gt;
&amp;lt;/poem&amp;gt;&lt;br /&gt;
&amp;lt;poem style=&amp;quot;border: 2px solid #d6d2c5; background-color: #f9f4e6; padding: 1em;&amp;quot;&amp;gt;&lt;br /&gt;
This script requires modules: [[LibRPC]] and [[z-finder]]. &lt;br /&gt;
&amp;lt;/poem&amp;gt;&lt;br /&gt;
&amp;lt;poem style=&amp;quot;border: 2px solid #d6d2c5; background-color: #f9f4e6; padding: 1em;&amp;quot;&amp;gt;&lt;br /&gt;
This script is made as of npcclient version 1.6 beta 4 patch 1. &lt;br /&gt;
&amp;lt;/poem&amp;gt;&lt;br /&gt;
==Server Side==&lt;br /&gt;
1. In scripts/main.nut, connect our npc using &lt;br /&gt;
&amp;lt;source &amp;gt;ConnectNPC(&amp;quot;[npc]captain&amp;quot;, &amp;quot;walking_man.nut&amp;quot;, false, &amp;quot;&amp;quot;, &amp;quot;rpclib z-finder&amp;quot;)&amp;lt;/source&amp;gt;&lt;br /&gt;
&amp;lt;poem&amp;gt;&lt;br /&gt;
false - console off, put true - console on&lt;br /&gt;
&amp;quot;&amp;quot; - host IP, default to 127.0.0.1&lt;br /&gt;
rpclib - npc module (to be placed in npcscripts/plugins) &amp;lt;/poem&amp;gt;&lt;br /&gt;
z-finder - another module to get z co-ordinates&lt;br /&gt;
==Map File==&lt;br /&gt;
2. You need to place [https://www.mediafire.com/file/gz3cwzhrkrk4v1w/default.map/file default.map] in server directory.&lt;br /&gt;
&lt;br /&gt;
==NPC side==&lt;br /&gt;
2. Create npcscripts/walking_man.nut&lt;br /&gt;
The following script expects &amp;quot;vicecity.map&amp;quot; mapfile on server directory.&lt;br /&gt;
&amp;lt;source&amp;gt;&lt;br /&gt;
target&amp;lt;-null;timerid&amp;lt;-null;&lt;br /&gt;
WALK_START &amp;lt;- Vector(-872.146, -431.502, 11.5288);&lt;br /&gt;
WALK_END &amp;lt;- Vector( -870.825, -296.79, 11.173);&lt;br /&gt;
function WalkToPoint(point)&lt;br /&gt;
{&lt;br /&gt;
	target=point;&lt;br /&gt;
	if(timerid==null)&lt;br /&gt;
	{&lt;br /&gt;
		timerid=SetTimerEx(&amp;quot;step_forward&amp;quot;,100,0);&lt;br /&gt;
        //Remotely calling functions &#039;compilestring&#039; of server.&lt;br /&gt;
		RFC(F(&amp;quot;compilestring&amp;quot;)(&amp;quot;function SetWalkingAnimation(id){ local p=FindPlayer(id); if(p &amp;amp;&amp;amp; IsPlayerNPC(id))p.SetAnim(0,0);else WalkTimer&amp;quot;+GetMyID()+&amp;quot;.Delete()}&amp;quot;))();&lt;br /&gt;
		RFC(F(&amp;quot;compilestring&amp;quot;)(&amp;quot;WalkTimer&amp;quot;+GetMyID()+&amp;quot;&amp;lt;-NewTimer(\&amp;quot;SetWalkingAnimation\&amp;quot;,100,0,&amp;quot;+GetMyID()+&amp;quot;)&amp;quot;))();&lt;br /&gt;
	}&lt;br /&gt;
}&lt;br /&gt;
function onDestinationReached()&lt;br /&gt;
{&lt;br /&gt;
	if( GetDistanceFromMeToPoint( WALK_START ) &amp;lt; 2 )&lt;br /&gt;
		WalkToPoint( WALK_END );&lt;br /&gt;
	else if( GetDistanceFromMeToPoint( WALK_END ) &amp;lt; 2 )&lt;br /&gt;
	{&lt;br /&gt;
		WalkToPoint( WALK_START );&lt;br /&gt;
        //print something on server console.&lt;br /&gt;
		RFC(&amp;quot;print&amp;quot;)(&amp;quot;npc: i completed one round of patrol&amp;quot;);&lt;br /&gt;
	}&lt;br /&gt;
}&lt;br /&gt;
function step_forward()&lt;br /&gt;
{&lt;br /&gt;
	local newpos=GetMyPos()+(target-GetMyPos()).Normalised()*0.14;&lt;br /&gt;
	newpos.z=FindZFor2DCoord(newpos.x, newpos.y)+1.0425;&lt;br /&gt;
	SetLocalValue(V_POS, newpos);&lt;br /&gt;
	SetLocalValue(F_ANGLE, atan2(-(target.x-GetMyPosX()),target.y-GetMyPosY()));&lt;br /&gt;
	if((target-GetMyPos()).Length()&amp;lt;0.8)//reached destination&lt;br /&gt;
	{&lt;br /&gt;
		if(timerid!=null)&lt;br /&gt;
			KillTimer(timerid);&lt;br /&gt;
		timerid=null;&lt;br /&gt;
		//stop timer of server&lt;br /&gt;
		RFC(F(&amp;quot;compilestring&amp;quot;)(&amp;quot;WalkTimer&amp;quot;+GetMyName()+&amp;quot;.Delete()&amp;quot;))();&lt;br /&gt;
	}&lt;br /&gt;
	else SendOnFootSyncDataLV();&lt;br /&gt;
	if(timerid==null)&lt;br /&gt;
		onDestinationReached();&lt;br /&gt;
}&lt;br /&gt;
function OnNPCSpawn() &lt;br /&gt;
{ &lt;br /&gt;
	SetTimerEx(&amp;quot;SetMyPos&amp;quot;,700, 1, WALK_START );&lt;br /&gt;
//	SetMyPos(WALK_START);&lt;br /&gt;
	print(GetMyPos());&lt;br /&gt;
	SetTimerEx(&amp;quot;WalkToPoint&amp;quot;, 1000, 1, WALK_END );&lt;br /&gt;
	//WalkToPoint( WALK_END );&lt;br /&gt;
	//Acquire weapon and skin&lt;br /&gt;
	RFC(F(&amp;quot;compilestring&amp;quot;)(&amp;quot;FindPlayer(&amp;quot;+GetMyID()+&amp;quot;).SetWeapon(4,1);&amp;quot;))();&lt;br /&gt;
	RFC(F(&amp;quot;compilestring&amp;quot;)(&amp;quot;FindPlayer(&amp;quot;+GetMyID()+&amp;quot;).Skin=1&amp;quot;))();&lt;br /&gt;
	SetTimerEx(&amp;quot;SetLocalValue&amp;quot;, 1000,1, I_CURWEP, 4);&lt;br /&gt;
}&lt;br /&gt;
function OnNPCScriptLoad(params)&lt;br /&gt;
{&lt;br /&gt;
	if(!MiamiScale_Init(&amp;quot;default.map&amp;quot;))&lt;br /&gt;
	{&lt;br /&gt;
		SendChat(&amp;quot;My map is not loaded. Bye&amp;quot;);&lt;br /&gt;
		QuitServer();&lt;br /&gt;
	}&lt;br /&gt;
}&lt;br /&gt;
function OnNPCScriptUnload()&lt;br /&gt;
{&lt;br /&gt;
	MiamiScale_Unload();&lt;br /&gt;
}&amp;lt;/source&amp;gt;&lt;/div&gt;</summary>
		<author><name>Habi</name></author>
	</entry>
	<entry>
		<id>https://npc-for-vcmp.sourceforge.io/wikiw/index.php?title=Walking_man&amp;diff=1906</id>
		<title>Walking man</title>
		<link rel="alternate" type="text/html" href="https://npc-for-vcmp.sourceforge.io/wikiw/index.php?title=Walking_man&amp;diff=1906"/>
		<updated>2024-11-03T17:34:34Z</updated>

		<summary type="html">&lt;p&gt;Habi: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;poem style=&amp;quot;border: 2px solid #d6d2c5; background-color: #f9f4e6; padding: 1em;&amp;quot;&amp;gt;&lt;br /&gt;
This script uses SetAnim every 100 ms.&lt;br /&gt;
&amp;lt;/poem&amp;gt;&lt;br /&gt;
&amp;lt;poem style=&amp;quot;border: 2px solid #d6d2c5; background-color: #f9f4e6; padding: 1em;&amp;quot;&amp;gt;&lt;br /&gt;
This script requires modules: [[LibRPC]] and [[z-finder]]. &lt;br /&gt;
&amp;lt;/poem&amp;gt;&lt;br /&gt;
&amp;lt;poem style=&amp;quot;border: 2px solid #d6d2c5; background-color: #f9f4e6; padding: 1em;&amp;quot;&amp;gt;&lt;br /&gt;
This script is made as of npcclient version 1.6 beta 4 patch 1. &lt;br /&gt;
&amp;lt;/poem&amp;gt;&lt;br /&gt;
==Server Side==&lt;br /&gt;
1. In scripts/main.nut, connect our npc using &lt;br /&gt;
&amp;lt;source &amp;gt;ConnectNPC(&amp;quot;[npc]captain&amp;quot;, &amp;quot;walking_man.nut&amp;quot;, false, &amp;quot;&amp;quot;, &amp;quot;rpclib z-finder&amp;quot;)&amp;lt;/source&amp;gt;&lt;br /&gt;
&amp;lt;poem&amp;gt;&lt;br /&gt;
false - console off, put true - console on&lt;br /&gt;
&amp;quot;&amp;quot; - host IP, default to 127.0.0.1&lt;br /&gt;
rpclib - npc module (to be placed in npcscripts/plugins) &amp;lt;/poem&amp;gt;&lt;br /&gt;
z-finder - another module to get z co-ordinates&lt;br /&gt;
==Map File==&lt;br /&gt;
You need to place [https://www.mediafire.com/file/gz3cwzhrkrk4v1w/default.map/file default.map] in server directory.&lt;br /&gt;
==NPC side==&lt;br /&gt;
2. Create npcscripts/walking_man.nut&lt;br /&gt;
The following script expects &amp;quot;vicecity.map&amp;quot; mapfile on server directory.&lt;br /&gt;
&amp;lt;source&amp;gt;&lt;br /&gt;
target&amp;lt;-null;timerid&amp;lt;-null;&lt;br /&gt;
WALK_START &amp;lt;- Vector(-872.146, -431.502, 11.5288);&lt;br /&gt;
WALK_END &amp;lt;- Vector( -870.825, -296.79, 11.173);&lt;br /&gt;
function WalkToPoint(point)&lt;br /&gt;
{&lt;br /&gt;
	target=point;&lt;br /&gt;
	if(timerid==null)&lt;br /&gt;
	{&lt;br /&gt;
		timerid=SetTimerEx(&amp;quot;step_forward&amp;quot;,100,0);&lt;br /&gt;
        //Remotely calling functions &#039;compilestring&#039; of server.&lt;br /&gt;
		RFC(F(&amp;quot;compilestring&amp;quot;)(&amp;quot;function SetWalkingAnimation(id){ local p=FindPlayer(id); if(p &amp;amp;&amp;amp; IsPlayerNPC(id))p.SetAnim(0,0);else WalkTimer&amp;quot;+GetMyID()+&amp;quot;.Delete()}&amp;quot;))();&lt;br /&gt;
		RFC(F(&amp;quot;compilestring&amp;quot;)(&amp;quot;WalkTimer&amp;quot;+GetMyID()+&amp;quot;&amp;lt;-NewTimer(\&amp;quot;SetWalkingAnimation\&amp;quot;,100,0,&amp;quot;+GetMyID()+&amp;quot;)&amp;quot;))();&lt;br /&gt;
	}&lt;br /&gt;
}&lt;br /&gt;
function onDestinationReached()&lt;br /&gt;
{&lt;br /&gt;
	if( GetDistanceFromMeToPoint( WALK_START ) &amp;lt; 2 )&lt;br /&gt;
		WalkToPoint( WALK_END );&lt;br /&gt;
	else if( GetDistanceFromMeToPoint( WALK_END ) &amp;lt; 2 )&lt;br /&gt;
	{&lt;br /&gt;
		WalkToPoint( WALK_START );&lt;br /&gt;
        //print something on server console.&lt;br /&gt;
		RFC(&amp;quot;print&amp;quot;)(&amp;quot;npc: i completed one round of patrol&amp;quot;);&lt;br /&gt;
	}&lt;br /&gt;
}&lt;br /&gt;
function step_forward()&lt;br /&gt;
{&lt;br /&gt;
	local newpos=GetMyPos()+(target-GetMyPos()).Normalised()*0.14;&lt;br /&gt;
	newpos.z=FindZFor2DCoord(newpos.x, newpos.y)+1.0425;&lt;br /&gt;
	SetLocalValue(V_POS, newpos);&lt;br /&gt;
	SetLocalValue(F_ANGLE, atan2(-(target.x-GetMyPosX()),target.y-GetMyPosY()));&lt;br /&gt;
	if((target-GetMyPos()).Length()&amp;lt;0.8)//reached destination&lt;br /&gt;
	{&lt;br /&gt;
		if(timerid!=null)&lt;br /&gt;
			KillTimer(timerid);&lt;br /&gt;
		timerid=null;&lt;br /&gt;
		//stop timer of server&lt;br /&gt;
		RFC(F(&amp;quot;compilestring&amp;quot;)(&amp;quot;WalkTimer&amp;quot;+GetMyName()+&amp;quot;.Delete()&amp;quot;))();&lt;br /&gt;
	}&lt;br /&gt;
	else SendOnFootSyncDataLV();&lt;br /&gt;
	if(timerid==null)&lt;br /&gt;
		onDestinationReached();&lt;br /&gt;
}&lt;br /&gt;
function OnNPCSpawn() &lt;br /&gt;
{ &lt;br /&gt;
	SetTimerEx(&amp;quot;SetMyPos&amp;quot;,700, 1, WALK_START );&lt;br /&gt;
//	SetMyPos(WALK_START);&lt;br /&gt;
	print(GetMyPos());&lt;br /&gt;
	SetTimerEx(&amp;quot;WalkToPoint&amp;quot;, 1000, 1, WALK_END );&lt;br /&gt;
	//WalkToPoint( WALK_END );&lt;br /&gt;
	//Acquire weapon and skin&lt;br /&gt;
	RFC(F(&amp;quot;compilestring&amp;quot;)(&amp;quot;FindPlayer(&amp;quot;+GetMyID()+&amp;quot;).SetWeapon(4,1);&amp;quot;))();&lt;br /&gt;
	RFC(F(&amp;quot;compilestring&amp;quot;)(&amp;quot;FindPlayer(&amp;quot;+GetMyID()+&amp;quot;).Skin=1&amp;quot;))();&lt;br /&gt;
	SetTimerEx(&amp;quot;SetLocalValue&amp;quot;, 1000,1, I_CURWEP, 4);&lt;br /&gt;
}&lt;br /&gt;
function OnNPCScriptLoad(params)&lt;br /&gt;
{&lt;br /&gt;
	if(!MiamiScale_Init(&amp;quot;default.map&amp;quot;))&lt;br /&gt;
	{&lt;br /&gt;
		SendChat(&amp;quot;My map is not loaded. Bye&amp;quot;);&lt;br /&gt;
		QuitServer();&lt;br /&gt;
	}&lt;br /&gt;
}&lt;br /&gt;
function OnNPCScriptUnload()&lt;br /&gt;
{&lt;br /&gt;
	MiamiScale_Unload();&lt;br /&gt;
}&amp;lt;/source&amp;gt;&lt;/div&gt;</summary>
		<author><name>Habi</name></author>
	</entry>
	<entry>
		<id>https://npc-for-vcmp.sourceforge.io/wikiw/index.php?title=Walking_man&amp;diff=1905</id>
		<title>Walking man</title>
		<link rel="alternate" type="text/html" href="https://npc-for-vcmp.sourceforge.io/wikiw/index.php?title=Walking_man&amp;diff=1905"/>
		<updated>2024-11-03T17:33:35Z</updated>

		<summary type="html">&lt;p&gt;Habi: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;poem style=&amp;quot;border: 2px solid #d6d2c5; background-color: #f9f4e6; padding: 1em;&amp;quot;&amp;gt;&lt;br /&gt;
This script uses SetAnim every 100 ms.&lt;br /&gt;
&amp;lt;/poem&amp;gt;&lt;br /&gt;
&amp;lt;poem style=&amp;quot;border: 2px solid #d6d2c5; background-color: #f9f4e6; padding: 1em;&amp;quot;&amp;gt;&lt;br /&gt;
This script requires modules: [[LibRPC]] and [[z-finder]]. &lt;br /&gt;
&amp;lt;/poem&amp;gt;&lt;br /&gt;
&amp;lt;poem style=&amp;quot;border: 2px solid #d6d2c5; background-color: #f9f4e6; padding: 1em;&amp;quot;&amp;gt;&lt;br /&gt;
This script is made as of npcclient version 1.6 beta 4 patch 1. &lt;br /&gt;
&amp;lt;/poem&amp;gt;&lt;br /&gt;
==Server Side==&lt;br /&gt;
1. In scripts/main.nut, connect our npc using &lt;br /&gt;
&amp;lt;source &amp;gt;ConnectNPC(&amp;quot;[npc]captain&amp;quot;, &amp;quot;walking_man.nut&amp;quot;, false, &amp;quot;&amp;quot;, &amp;quot;rpclib z-finder&amp;quot;)&amp;lt;/source&amp;gt;&lt;br /&gt;
&amp;lt;poem&amp;gt;&lt;br /&gt;
false - console off, put true - console on&lt;br /&gt;
&amp;quot;&amp;quot; - host IP, default to 127.0.0.1&lt;br /&gt;
rpclib - npc module (to be placed in npcscripts/plugins) &amp;lt;/poem&amp;gt;&lt;br /&gt;
z-finder - another module to get z co-ordinates&lt;br /&gt;
==NPC side==&lt;br /&gt;
2. Create npcscripts/walking_man.nut&lt;br /&gt;
The following script expects &amp;quot;vicecity.map&amp;quot; mapfile on server directory.&lt;br /&gt;
&amp;lt;source&amp;gt;&lt;br /&gt;
target&amp;lt;-null;timerid&amp;lt;-null;&lt;br /&gt;
WALK_START &amp;lt;- Vector(-872.146, -431.502, 11.5288);&lt;br /&gt;
WALK_END &amp;lt;- Vector( -870.825, -296.79, 11.173);&lt;br /&gt;
function WalkToPoint(point)&lt;br /&gt;
{&lt;br /&gt;
	target=point;&lt;br /&gt;
	if(timerid==null)&lt;br /&gt;
	{&lt;br /&gt;
		timerid=SetTimerEx(&amp;quot;step_forward&amp;quot;,100,0);&lt;br /&gt;
        //Remotely calling functions &#039;compilestring&#039; of server.&lt;br /&gt;
		RFC(F(&amp;quot;compilestring&amp;quot;)(&amp;quot;function SetWalkingAnimation(id){ local p=FindPlayer(id); if(p &amp;amp;&amp;amp; IsPlayerNPC(id))p.SetAnim(0,0);else WalkTimer&amp;quot;+GetMyID()+&amp;quot;.Delete()}&amp;quot;))();&lt;br /&gt;
		RFC(F(&amp;quot;compilestring&amp;quot;)(&amp;quot;WalkTimer&amp;quot;+GetMyID()+&amp;quot;&amp;lt;-NewTimer(\&amp;quot;SetWalkingAnimation\&amp;quot;,100,0,&amp;quot;+GetMyID()+&amp;quot;)&amp;quot;))();&lt;br /&gt;
	}&lt;br /&gt;
}&lt;br /&gt;
function onDestinationReached()&lt;br /&gt;
{&lt;br /&gt;
	if( GetDistanceFromMeToPoint( WALK_START ) &amp;lt; 2 )&lt;br /&gt;
		WalkToPoint( WALK_END );&lt;br /&gt;
	else if( GetDistanceFromMeToPoint( WALK_END ) &amp;lt; 2 )&lt;br /&gt;
	{&lt;br /&gt;
		WalkToPoint( WALK_START );&lt;br /&gt;
        //print something on server console.&lt;br /&gt;
		RFC(&amp;quot;print&amp;quot;)(&amp;quot;npc: i completed one round of patrol&amp;quot;);&lt;br /&gt;
	}&lt;br /&gt;
}&lt;br /&gt;
function step_forward()&lt;br /&gt;
{&lt;br /&gt;
	local newpos=GetMyPos()+(target-GetMyPos()).Normalised()*0.14;&lt;br /&gt;
	newpos.z=FindZFor2DCoord(newpos.x, newpos.y)+1.0425;&lt;br /&gt;
	SetLocalValue(V_POS, newpos);&lt;br /&gt;
	SetLocalValue(F_ANGLE, atan2(-(target.x-GetMyPosX()),target.y-GetMyPosY()));&lt;br /&gt;
	if((target-GetMyPos()).Length()&amp;lt;0.8)//reached destination&lt;br /&gt;
	{&lt;br /&gt;
		if(timerid!=null)&lt;br /&gt;
			KillTimer(timerid);&lt;br /&gt;
		timerid=null;&lt;br /&gt;
		//stop timer of server&lt;br /&gt;
		RFC(F(&amp;quot;compilestring&amp;quot;)(&amp;quot;WalkTimer&amp;quot;+GetMyName()+&amp;quot;.Delete()&amp;quot;))();&lt;br /&gt;
	}&lt;br /&gt;
	else SendOnFootSyncDataLV();&lt;br /&gt;
	if(timerid==null)&lt;br /&gt;
		onDestinationReached();&lt;br /&gt;
}&lt;br /&gt;
function OnNPCSpawn() &lt;br /&gt;
{ &lt;br /&gt;
	SetTimerEx(&amp;quot;SetMyPos&amp;quot;,700, 1, WALK_START );&lt;br /&gt;
//	SetMyPos(WALK_START);&lt;br /&gt;
	print(GetMyPos());&lt;br /&gt;
	SetTimerEx(&amp;quot;WalkToPoint&amp;quot;, 1000, 1, WALK_END );&lt;br /&gt;
	//WalkToPoint( WALK_END );&lt;br /&gt;
	//Acquire weapon and skin&lt;br /&gt;
	RFC(F(&amp;quot;compilestring&amp;quot;)(&amp;quot;FindPlayer(&amp;quot;+GetMyID()+&amp;quot;).SetWeapon(4,1);&amp;quot;))();&lt;br /&gt;
	RFC(F(&amp;quot;compilestring&amp;quot;)(&amp;quot;FindPlayer(&amp;quot;+GetMyID()+&amp;quot;).Skin=1&amp;quot;))();&lt;br /&gt;
	SetTimerEx(&amp;quot;SetLocalValue&amp;quot;, 1000,1, I_CURWEP, 4);&lt;br /&gt;
}&lt;br /&gt;
function OnNPCScriptLoad(params)&lt;br /&gt;
{&lt;br /&gt;
	if(!MiamiScale_Init(&amp;quot;default.map&amp;quot;))&lt;br /&gt;
	{&lt;br /&gt;
		SendChat(&amp;quot;My map is not loaded. Bye&amp;quot;);&lt;br /&gt;
		QuitServer();&lt;br /&gt;
	}&lt;br /&gt;
}&lt;br /&gt;
function OnNPCScriptUnload()&lt;br /&gt;
{&lt;br /&gt;
	MiamiScale_Unload();&lt;br /&gt;
}&amp;lt;/source&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Map File==&lt;br /&gt;
You need to place [https://www.mediafire.com/file/gz3cwzhrkrk4v1w/default.map/file default.map] in server directory.&lt;/div&gt;</summary>
		<author><name>Habi</name></author>
	</entry>
	<entry>
		<id>https://npc-for-vcmp.sourceforge.io/wikiw/index.php?title=Walking_man&amp;diff=1904</id>
		<title>Walking man</title>
		<link rel="alternate" type="text/html" href="https://npc-for-vcmp.sourceforge.io/wikiw/index.php?title=Walking_man&amp;diff=1904"/>
		<updated>2024-11-03T17:31:16Z</updated>

		<summary type="html">&lt;p&gt;Habi: /* NPC side */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;poem style=&amp;quot;border: 2px solid #d6d2c5; background-color: #f9f4e6; padding: 1em;&amp;quot;&amp;gt;&lt;br /&gt;
This script uses SetAnim every 100 ms.&lt;br /&gt;
&amp;lt;/poem&amp;gt;&lt;br /&gt;
&amp;lt;poem style=&amp;quot;border: 2px solid #d6d2c5; background-color: #f9f4e6; padding: 1em;&amp;quot;&amp;gt;&lt;br /&gt;
This script requires modules: [[LibRPC]] and [[z-finder]]. &lt;br /&gt;
&amp;lt;/poem&amp;gt;&lt;br /&gt;
&amp;lt;poem style=&amp;quot;border: 2px solid #d6d2c5; background-color: #f9f4e6; padding: 1em;&amp;quot;&amp;gt;&lt;br /&gt;
This script is made as of npcclient version 1.6 beta 4 patch 1. &lt;br /&gt;
&amp;lt;/poem&amp;gt;&lt;br /&gt;
==Server Side==&lt;br /&gt;
1. In scripts/main.nut, connect our npc using &lt;br /&gt;
&amp;lt;source &amp;gt;ConnectNPC(&amp;quot;[npc]captain&amp;quot;, &amp;quot;walking_man.nut&amp;quot;, false, &amp;quot;&amp;quot;, &amp;quot;rpclib z-finder&amp;quot;)&amp;lt;/source&amp;gt;&lt;br /&gt;
&amp;lt;poem&amp;gt;&lt;br /&gt;
false - console off, put true - console on&lt;br /&gt;
&amp;quot;&amp;quot; - host IP, default to 127.0.0.1&lt;br /&gt;
rpclib - npc module (to be placed in npcscripts/plugins) &amp;lt;/poem&amp;gt;&lt;br /&gt;
z-finder - another module to get z co-ordinates&lt;br /&gt;
==NPC side==&lt;br /&gt;
2. Create npcscripts/walking_man.nut&lt;br /&gt;
The following script expects &amp;quot;vicecity.map&amp;quot; mapfile on server directory.&lt;br /&gt;
&amp;lt;source&amp;gt;&lt;br /&gt;
target&amp;lt;-null;timerid&amp;lt;-null;&lt;br /&gt;
WALK_START &amp;lt;- Vector(-872.146, -431.502, 11.5288);&lt;br /&gt;
WALK_END &amp;lt;- Vector( -870.825, -296.79, 11.173);&lt;br /&gt;
function WalkToPoint(point)&lt;br /&gt;
{&lt;br /&gt;
	target=point;&lt;br /&gt;
	if(timerid==null)&lt;br /&gt;
	{&lt;br /&gt;
		timerid=SetTimerEx(&amp;quot;step_forward&amp;quot;,100,0);&lt;br /&gt;
        //Remotely calling functions &#039;compilestring&#039; of server.&lt;br /&gt;
		RFC(F(&amp;quot;compilestring&amp;quot;)(&amp;quot;function SetWalkingAnimation(id){ local p=FindPlayer(id); if(p &amp;amp;&amp;amp; IsPlayerNPC(id))p.SetAnim(0,0);else WalkTimer&amp;quot;+GetMyID()+&amp;quot;.Delete()}&amp;quot;))();&lt;br /&gt;
		RFC(F(&amp;quot;compilestring&amp;quot;)(&amp;quot;WalkTimer&amp;quot;+GetMyID()+&amp;quot;&amp;lt;-NewTimer(\&amp;quot;SetWalkingAnimation\&amp;quot;,100,0,&amp;quot;+GetMyID()+&amp;quot;)&amp;quot;))();&lt;br /&gt;
	}&lt;br /&gt;
}&lt;br /&gt;
function onDestinationReached()&lt;br /&gt;
{&lt;br /&gt;
	if( GetDistanceFromMeToPoint( WALK_START ) &amp;lt; 2 )&lt;br /&gt;
		WalkToPoint( WALK_END );&lt;br /&gt;
	else if( GetDistanceFromMeToPoint( WALK_END ) &amp;lt; 2 )&lt;br /&gt;
	{&lt;br /&gt;
		WalkToPoint( WALK_START );&lt;br /&gt;
        //print something on server console.&lt;br /&gt;
		RFC(&amp;quot;print&amp;quot;)(&amp;quot;npc: i completed one round of patrol&amp;quot;);&lt;br /&gt;
	}&lt;br /&gt;
}&lt;br /&gt;
function step_forward()&lt;br /&gt;
{&lt;br /&gt;
	local newpos=GetMyPos()+(target-GetMyPos()).Normalised()*0.14;&lt;br /&gt;
	newpos.z=FindZFor2DCoord(newpos.x, newpos.y)+1.0425;&lt;br /&gt;
	SetLocalValue(V_POS, newpos);&lt;br /&gt;
	SetLocalValue(F_ANGLE, atan2(-(target.x-GetMyPosX()),target.y-GetMyPosY()));&lt;br /&gt;
	if((target-GetMyPos()).Length()&amp;lt;0.8)//reached destination&lt;br /&gt;
	{&lt;br /&gt;
		if(timerid!=null)&lt;br /&gt;
			KillTimer(timerid);&lt;br /&gt;
		timerid=null;&lt;br /&gt;
		//stop timer of server&lt;br /&gt;
		RFC(F(&amp;quot;compilestring&amp;quot;)(&amp;quot;WalkTimer&amp;quot;+GetMyName()+&amp;quot;.Delete()&amp;quot;))();&lt;br /&gt;
	}&lt;br /&gt;
	else SendOnFootSyncDataLV();&lt;br /&gt;
	if(timerid==null)&lt;br /&gt;
		onDestinationReached();&lt;br /&gt;
}&lt;br /&gt;
function OnNPCSpawn() &lt;br /&gt;
{ &lt;br /&gt;
	SetTimerEx(&amp;quot;SetMyPos&amp;quot;,700, 1, WALK_START );&lt;br /&gt;
//	SetMyPos(WALK_START);&lt;br /&gt;
	print(GetMyPos());&lt;br /&gt;
	SetTimerEx(&amp;quot;WalkToPoint&amp;quot;, 1000, 1, WALK_END );&lt;br /&gt;
	//WalkToPoint( WALK_END );&lt;br /&gt;
	//Acquire weapon and skin&lt;br /&gt;
	RFC(F(&amp;quot;compilestring&amp;quot;)(&amp;quot;FindPlayer(&amp;quot;+GetMyID()+&amp;quot;).SetWeapon(4,1);&amp;quot;))();&lt;br /&gt;
	RFC(F(&amp;quot;compilestring&amp;quot;)(&amp;quot;FindPlayer(&amp;quot;+GetMyID()+&amp;quot;).Skin=1&amp;quot;))();&lt;br /&gt;
	SetTimerEx(&amp;quot;SetLocalValue&amp;quot;, 1000,1, I_CURWEP, 4);&lt;br /&gt;
}&lt;br /&gt;
function OnNPCScriptLoad(params)&lt;br /&gt;
{&lt;br /&gt;
	if(!MiamiScale_Init(&amp;quot;default.map&amp;quot;))&lt;br /&gt;
	{&lt;br /&gt;
		SendChat(&amp;quot;My map is not loaded. Bye&amp;quot;);&lt;br /&gt;
		QuitServer();&lt;br /&gt;
	}&lt;br /&gt;
}&lt;br /&gt;
function OnNPCScriptUnload()&lt;br /&gt;
{&lt;br /&gt;
	MiamiScale_Unload();&lt;br /&gt;
}&amp;lt;/source&amp;gt;&lt;/div&gt;</summary>
		<author><name>Habi</name></author>
	</entry>
	<entry>
		<id>https://npc-for-vcmp.sourceforge.io/wikiw/index.php?title=IsPlaybackPaused&amp;diff=1903</id>
		<title>IsPlaybackPaused</title>
		<link rel="alternate" type="text/html" href="https://npc-for-vcmp.sourceforge.io/wikiw/index.php?title=IsPlaybackPaused&amp;diff=1903"/>
		<updated>2024-10-29T17:34:27Z</updated>

		<summary type="html">&lt;p&gt;Habi: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{v1_8_beta}}&lt;br /&gt;
{{Welcome|desc=This function tells whether any playback is in paused state.|&lt;br /&gt;
params=&amp;lt;source&amp;gt;NoParams&amp;lt;/source&amp;gt;|&lt;br /&gt;
example=&amp;lt;source lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
if(IsPlaybackRunning())&lt;br /&gt;
{&lt;br /&gt;
     if(IsPlaybackPaused())&lt;br /&gt;
          print(&amp;quot;The playback is paused\n&amp;quot;);&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/source&amp;gt;|&lt;br /&gt;
retvals=true, if playback is paused and false otherwise(playback is not running or running but not paused)|&lt;br /&gt;
note=This function returns false when playback is not running|&lt;br /&gt;
relfuncs=*[[IsPlaybackRunning]]&lt;br /&gt;
}}&lt;/div&gt;</summary>
		<author><name>Habi</name></author>
	</entry>
	<entry>
		<id>https://npc-for-vcmp.sourceforge.io/wikiw/index.php?title=IsPlaybackPaused&amp;diff=1902</id>
		<title>IsPlaybackPaused</title>
		<link rel="alternate" type="text/html" href="https://npc-for-vcmp.sourceforge.io/wikiw/index.php?title=IsPlaybackPaused&amp;diff=1902"/>
		<updated>2024-10-29T17:34:02Z</updated>

		<summary type="html">&lt;p&gt;Habi: Created page with &amp;quot;{{v1_8_beta}} {{Welcome|desc=This function tells whether any playback is in paused state.| params=&amp;lt;source&amp;gt;NoParams&amp;lt;/source&amp;gt;| example=&amp;lt;source lang=&amp;quot;lua&amp;quot;&amp;gt; if(IsPlaybackRunning()) {      if(IsPlaybackPaused())           print(&amp;quot;The playback is paused\n&amp;quot;); }| retvals=true, if playback is paused and false otherwise(playback is not running or running but not paused)| note=This function returns false when playback is not running| relfuncs=*IsPlaybackRunning }}&amp;quot;&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{v1_8_beta}}&lt;br /&gt;
{{Welcome|desc=This function tells whether any playback is in paused state.|&lt;br /&gt;
params=&amp;lt;source&amp;gt;NoParams&amp;lt;/source&amp;gt;|&lt;br /&gt;
example=&amp;lt;source lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
if(IsPlaybackRunning())&lt;br /&gt;
{&lt;br /&gt;
     if(IsPlaybackPaused())&lt;br /&gt;
          print(&amp;quot;The playback is paused\n&amp;quot;);&lt;br /&gt;
}|&lt;br /&gt;
retvals=true, if playback is paused and false otherwise(playback is not running or running but not paused)|&lt;br /&gt;
note=This function returns false when playback is not running|&lt;br /&gt;
relfuncs=*[[IsPlaybackRunning]]&lt;br /&gt;
}}&lt;/div&gt;</summary>
		<author><name>Habi</name></author>
	</entry>
	<entry>
		<id>https://npc-for-vcmp.sourceforge.io/wikiw/index.php?title=IsPlaybackRunning&amp;diff=1901</id>
		<title>IsPlaybackRunning</title>
		<link rel="alternate" type="text/html" href="https://npc-for-vcmp.sourceforge.io/wikiw/index.php?title=IsPlaybackRunning&amp;diff=1901"/>
		<updated>2024-10-29T17:29:35Z</updated>

		<summary type="html">&lt;p&gt;Habi: Created page with &amp;quot;{{v1_8_beta}} {{Welcome|desc=This function is used to determine if the playback is running| params=&amp;lt;source&amp;gt;NoParams&amp;lt;/source&amp;gt;| retvals=false, if playback is not running or paused. true otherwise| relfuncs=*IsPlaybackPaused *StartRecordingPlayback *StopRecordingPlayback *PauseRecordingPlayback *ResumeRecordingPlayback}}&amp;quot;&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{v1_8_beta}}&lt;br /&gt;
{{Welcome|desc=This function is used to determine if the playback is running|&lt;br /&gt;
params=&amp;lt;source&amp;gt;NoParams&amp;lt;/source&amp;gt;|&lt;br /&gt;
retvals=false, if playback is not running or paused. true otherwise|&lt;br /&gt;
relfuncs=*[[IsPlaybackPaused]]&lt;br /&gt;
*[[StartRecordingPlayback]]&lt;br /&gt;
*[[StopRecordingPlayback]]&lt;br /&gt;
*[[PauseRecordingPlayback]]&lt;br /&gt;
*[[ResumeRecordingPlayback]]}}&lt;/div&gt;</summary>
		<author><name>Habi</name></author>
	</entry>
	<entry>
		<id>https://npc-for-vcmp.sourceforge.io/wikiw/index.php?title=GetMyColor&amp;diff=1900</id>
		<title>GetMyColor</title>
		<link rel="alternate" type="text/html" href="https://npc-for-vcmp.sourceforge.io/wikiw/index.php?title=GetMyColor&amp;diff=1900"/>
		<updated>2024-10-29T17:25:29Z</updated>

		<summary type="html">&lt;p&gt;Habi: Created page with &amp;quot;{{v1_8_beta}} {{Welcome|desc=This function is used to find the color(r,g,b) of NPC itself.| params=&amp;lt;source&amp;gt;NoParams&amp;lt;/source&amp;gt;| retvals=This function returns a table with keys &amp;lt;source inline&amp;gt;r,g,b&amp;lt;/source&amp;gt;.| relfuncs=*GetPlayerColor}}&amp;quot;&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{v1_8_beta}}&lt;br /&gt;
{{Welcome|desc=This function is used to find the color(r,g,b) of NPC itself.|&lt;br /&gt;
params=&amp;lt;source&amp;gt;NoParams&amp;lt;/source&amp;gt;|&lt;br /&gt;
retvals=This function returns a table with keys &amp;lt;source inline&amp;gt;r,g,b&amp;lt;/source&amp;gt;.|&lt;br /&gt;
relfuncs=*[[GetPlayerColor]]}}&lt;/div&gt;</summary>
		<author><name>Habi</name></author>
	</entry>
	<entry>
		<id>https://npc-for-vcmp.sourceforge.io/wikiw/index.php?title=GetPlayerColor&amp;diff=1899</id>
		<title>GetPlayerColor</title>
		<link rel="alternate" type="text/html" href="https://npc-for-vcmp.sourceforge.io/wikiw/index.php?title=GetPlayerColor&amp;diff=1899"/>
		<updated>2024-10-29T17:24:09Z</updated>

		<summary type="html">&lt;p&gt;Habi: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{v1_8_beta}}&lt;br /&gt;
{{Welcome|desc=This function is used to find the color(r,g,b) of another player(the marker in map as well as name tag).|&lt;br /&gt;
params=&amp;lt;source&amp;gt;(playerid)&amp;lt;/source&amp;gt;&lt;br /&gt;
&amp;lt;poem&amp;gt;::playerid : The  ID of the target player whose color is to be found.&lt;br /&gt;
&amp;lt;/poem&amp;gt;|&lt;br /&gt;
retvals=This function returns a table with keys &amp;lt;source inline&amp;gt;r,g,b&amp;lt;/source&amp;gt; on success and null on failure(target player does not exist)|&lt;br /&gt;
relfuncs=*[[GetMyColor]]}}&lt;/div&gt;</summary>
		<author><name>Habi</name></author>
	</entry>
	<entry>
		<id>https://npc-for-vcmp.sourceforge.io/wikiw/index.php?title=GetPlayerColor&amp;diff=1898</id>
		<title>GetPlayerColor</title>
		<link rel="alternate" type="text/html" href="https://npc-for-vcmp.sourceforge.io/wikiw/index.php?title=GetPlayerColor&amp;diff=1898"/>
		<updated>2024-10-29T17:23:46Z</updated>

		<summary type="html">&lt;p&gt;Habi: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{v1_8_beta}}&lt;br /&gt;
{{Welcome|desc=This function is used to find the color(r,g,b) of another player(the marker in map as well as name tag).|&lt;br /&gt;
params=&amp;lt;source&amp;gt;(playerid)&amp;lt;/source&amp;gt;&lt;br /&gt;
&amp;lt;poem&amp;gt;::playerid : The  ID of the target player whose color is to be found.&lt;br /&gt;
&amp;lt;/poem&amp;gt;|&lt;br /&gt;
retvals=This function returns a table with keys &amp;lt;source inline&amp;gt;r,g,b&amp;lt;/source&amp;gt; on success and null on failure(target player does not exist)|&lt;br /&gt;
*relfuncs=*[[GetMyColor]]}}&lt;/div&gt;</summary>
		<author><name>Habi</name></author>
	</entry>
	<entry>
		<id>https://npc-for-vcmp.sourceforge.io/wikiw/index.php?title=GetPlayerColor&amp;diff=1897</id>
		<title>GetPlayerColor</title>
		<link rel="alternate" type="text/html" href="https://npc-for-vcmp.sourceforge.io/wikiw/index.php?title=GetPlayerColor&amp;diff=1897"/>
		<updated>2024-10-29T17:23:08Z</updated>

		<summary type="html">&lt;p&gt;Habi: Created page with &amp;quot;{{v1_8_beta}} {{Welcome|desc=This function is used to find the color(r,g,b) of another player(the marker in map as well as name tag).| params=&amp;lt;source&amp;gt;(playerid)&amp;lt;/source&amp;gt; &amp;lt;poem&amp;gt;::playerid : The  ID of the target player whose color is to be found. &amp;lt;/poem&amp;gt;| retvals=This function returns a table with keys &amp;lt;source inline&amp;gt;r,g,b&amp;lt;/source&amp;gt; on success and null on failure(target player does not exist)|}}&amp;quot;&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{v1_8_beta}}&lt;br /&gt;
{{Welcome|desc=This function is used to find the color(r,g,b) of another player(the marker in map as well as name tag).|&lt;br /&gt;
params=&amp;lt;source&amp;gt;(playerid)&amp;lt;/source&amp;gt;&lt;br /&gt;
&amp;lt;poem&amp;gt;::playerid : The  ID of the target player whose color is to be found.&lt;br /&gt;
&amp;lt;/poem&amp;gt;|&lt;br /&gt;
retvals=This function returns a table with keys &amp;lt;source inline&amp;gt;r,g,b&amp;lt;/source&amp;gt; on success and null on failure(target player does not exist)|}}&lt;/div&gt;</summary>
		<author><name>Habi</name></author>
	</entry>
	<entry>
		<id>https://npc-for-vcmp.sourceforge.io/wikiw/index.php?title=SendPrivMsg&amp;diff=1896</id>
		<title>SendPrivMsg</title>
		<link rel="alternate" type="text/html" href="https://npc-for-vcmp.sourceforge.io/wikiw/index.php?title=SendPrivMsg&amp;diff=1896"/>
		<updated>2024-10-29T17:17:02Z</updated>

		<summary type="html">&lt;p&gt;Habi: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{v1_8_beta}}&lt;br /&gt;
{{Welcome|desc=This function sends a private message to another player.|&lt;br /&gt;
params=&amp;lt;source&amp;gt;(playerid, message)&amp;lt;/source&amp;gt;&lt;br /&gt;
&amp;lt;poem&amp;gt;&lt;br /&gt;
::playerid : The ID of the target player to whom private message is to be send.&lt;br /&gt;
::message : The message to send.&lt;br /&gt;
&amp;lt;/poem&amp;gt;|&lt;br /&gt;
example=&amp;lt;source&amp;gt;&lt;br /&gt;
function OnPlayerStreamIn(playerid)&lt;br /&gt;
{&lt;br /&gt;
	SendPrivMsg(playerid, &amp;quot;Come near me&amp;quot;);&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/source&amp;gt;|&lt;br /&gt;
retvals=true on success, false on failure(invalid playerid)|&lt;br /&gt;
relfuncs=*[[SendChat]]&lt;br /&gt;
*[[SendCommand]]}}&lt;/div&gt;</summary>
		<author><name>Habi</name></author>
	</entry>
	<entry>
		<id>https://npc-for-vcmp.sourceforge.io/wikiw/index.php?title=SendPrivMsg&amp;diff=1895</id>
		<title>SendPrivMsg</title>
		<link rel="alternate" type="text/html" href="https://npc-for-vcmp.sourceforge.io/wikiw/index.php?title=SendPrivMsg&amp;diff=1895"/>
		<updated>2024-10-29T17:16:16Z</updated>

		<summary type="html">&lt;p&gt;Habi: Created page with &amp;quot;{{v1_8_beta}} {{Welcome|desc=This function sends a private message to another player.| params=&amp;lt;source&amp;gt;(playerid, message)&amp;lt;/source&amp;gt; &amp;lt;poem&amp;gt; ::playerid : The ID of the target player to whom private message is to be send. ::message : The message to send. &amp;lt;/poem&amp;gt;| example=&amp;lt;source&amp;gt; function OnPlayerStreamIn(playerid) { 	SendPrivMsg(playerid, &amp;quot;Come near me&amp;quot;); } &amp;lt;/source&amp;gt;| retvals=true on success, false on failure(invalid playerid)| relfuncs=*SendChat}}&amp;quot;&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{v1_8_beta}}&lt;br /&gt;
{{Welcome|desc=This function sends a private message to another player.|&lt;br /&gt;
params=&amp;lt;source&amp;gt;(playerid, message)&amp;lt;/source&amp;gt;&lt;br /&gt;
&amp;lt;poem&amp;gt;&lt;br /&gt;
::playerid : The ID of the target player to whom private message is to be send.&lt;br /&gt;
::message : The message to send.&lt;br /&gt;
&amp;lt;/poem&amp;gt;|&lt;br /&gt;
example=&amp;lt;source&amp;gt;&lt;br /&gt;
function OnPlayerStreamIn(playerid)&lt;br /&gt;
{&lt;br /&gt;
	SendPrivMsg(playerid, &amp;quot;Come near me&amp;quot;);&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/source&amp;gt;|&lt;br /&gt;
retvals=true on success, false on failure(invalid playerid)|&lt;br /&gt;
relfuncs=*[[SendChat]]}}&lt;/div&gt;</summary>
		<author><name>Habi</name></author>
	</entry>
	<entry>
		<id>https://npc-for-vcmp.sourceforge.io/wikiw/index.php?title=GetMyArmour&amp;diff=1894</id>
		<title>GetMyArmour</title>
		<link rel="alternate" type="text/html" href="https://npc-for-vcmp.sourceforge.io/wikiw/index.php?title=GetMyArmour&amp;diff=1894"/>
		<updated>2024-10-29T17:10:10Z</updated>

		<summary type="html">&lt;p&gt;Habi: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{v1_8_beta}}&lt;br /&gt;
{{Welcome|desc=This function returns the Armour of the NPC|params=&amp;lt;source&amp;gt;NoParams&amp;lt;/source&amp;gt;|&lt;br /&gt;
example=&amp;lt;source&amp;gt;&lt;br /&gt;
if(AmISpawned())&lt;br /&gt;
{&lt;br /&gt;
		print(&amp;quot;I  have armour &amp;quot;+GetMyArmour()+&amp;quot;\n&amp;quot;);&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/source&amp;gt;|&lt;br /&gt;
retvals=The amount of armour the npc has as integer.|&lt;br /&gt;
relfuncs=*[[GetPlayerArmour]]&lt;br /&gt;
*[[GetMyHealth]]}}&lt;/div&gt;</summary>
		<author><name>Habi</name></author>
	</entry>
	<entry>
		<id>https://npc-for-vcmp.sourceforge.io/wikiw/index.php?title=GetMyArmour&amp;diff=1893</id>
		<title>GetMyArmour</title>
		<link rel="alternate" type="text/html" href="https://npc-for-vcmp.sourceforge.io/wikiw/index.php?title=GetMyArmour&amp;diff=1893"/>
		<updated>2024-10-29T17:09:36Z</updated>

		<summary type="html">&lt;p&gt;Habi: Created page with &amp;quot;{{v1_8_beta}} {{Welcome|desc=This function returns the Armour of the NPC|params=&amp;lt;source&amp;gt;NoParams&amp;lt;/source&amp;gt;| example=&amp;lt;source&amp;gt; if(AmISpawned()) { 		print(&amp;quot;I  have armour &amp;quot;+GetMyArmour()+&amp;quot;\n&amp;quot;); } &amp;lt;/source&amp;gt;| retvals=The Armour of npc.| relfuncs=*GetPlayerArmour *GetMyHealth}}&amp;quot;&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{v1_8_beta}}&lt;br /&gt;
{{Welcome|desc=This function returns the Armour of the NPC|params=&amp;lt;source&amp;gt;NoParams&amp;lt;/source&amp;gt;|&lt;br /&gt;
example=&amp;lt;source&amp;gt;&lt;br /&gt;
if(AmISpawned())&lt;br /&gt;
{&lt;br /&gt;
		print(&amp;quot;I  have armour &amp;quot;+GetMyArmour()+&amp;quot;\n&amp;quot;);&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/source&amp;gt;|&lt;br /&gt;
retvals=The Armour of npc.|&lt;br /&gt;
relfuncs=*[[GetPlayerArmour]]&lt;br /&gt;
*[[GetMyHealth]]}}&lt;/div&gt;</summary>
		<author><name>Habi</name></author>
	</entry>
	<entry>
		<id>https://npc-for-vcmp.sourceforge.io/wikiw/index.php?title=GetMyTeam&amp;diff=1892</id>
		<title>GetMyTeam</title>
		<link rel="alternate" type="text/html" href="https://npc-for-vcmp.sourceforge.io/wikiw/index.php?title=GetMyTeam&amp;diff=1892"/>
		<updated>2024-10-29T17:06:55Z</updated>

		<summary type="html">&lt;p&gt;Habi: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{v1_8_beta}}&lt;br /&gt;
{{Welcome|desc=This function will return the team ID (0-255) of NPC.|&lt;br /&gt;
params=&amp;lt;source &amp;gt;NoParams&amp;lt;/source&amp;gt;|example=&amp;lt;source&amp;gt;print(&amp;quot;My Team ID is &amp;quot;+ GetMyTeam()+ &amp;quot;\n&amp;quot;);&amp;lt;/source&amp;gt;|&lt;br /&gt;
retvals=The Team ID of the npc|relfuncs=&lt;br /&gt;
*[[GetPlayerTeam]]&lt;br /&gt;
*[[GetMySkin]]|}}&lt;/div&gt;</summary>
		<author><name>Habi</name></author>
	</entry>
	<entry>
		<id>https://npc-for-vcmp.sourceforge.io/wikiw/index.php?title=GetMyTeam&amp;diff=1891</id>
		<title>GetMyTeam</title>
		<link rel="alternate" type="text/html" href="https://npc-for-vcmp.sourceforge.io/wikiw/index.php?title=GetMyTeam&amp;diff=1891"/>
		<updated>2024-10-29T17:06:26Z</updated>

		<summary type="html">&lt;p&gt;Habi: Created page with &amp;quot;{{v1_8_beta}} {{Welcome|desc=This function will return the team ID (0-255) of NPC.| params=&amp;lt;source inline&amp;gt;NoParams&amp;lt;/source&amp;gt;|example=&amp;lt;source&amp;gt;print(&amp;quot;My Team ID is &amp;quot;+ GetMyTeam()+ &amp;quot;\n&amp;quot;);&amp;lt;/source&amp;gt;| retvals=The Team ID of the npc|relfuncs= *GetPlayerTeam *GetMySkin|}}&amp;quot;&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{v1_8_beta}}&lt;br /&gt;
{{Welcome|desc=This function will return the team ID (0-255) of NPC.|&lt;br /&gt;
params=&amp;lt;source inline&amp;gt;NoParams&amp;lt;/source&amp;gt;|example=&amp;lt;source&amp;gt;print(&amp;quot;My Team ID is &amp;quot;+ GetMyTeam()+ &amp;quot;\n&amp;quot;);&amp;lt;/source&amp;gt;|&lt;br /&gt;
retvals=The Team ID of the npc|relfuncs=&lt;br /&gt;
*[[GetPlayerTeam]]&lt;br /&gt;
*[[GetMySkin]]|}}&lt;/div&gt;</summary>
		<author><name>Habi</name></author>
	</entry>
	<entry>
		<id>https://npc-for-vcmp.sourceforge.io/wikiw/index.php?title=GetMySkin&amp;diff=1890</id>
		<title>GetMySkin</title>
		<link rel="alternate" type="text/html" href="https://npc-for-vcmp.sourceforge.io/wikiw/index.php?title=GetMySkin&amp;diff=1890"/>
		<updated>2024-10-29T17:03:54Z</updated>

		<summary type="html">&lt;p&gt;Habi: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{v1_8_beta}}&lt;br /&gt;
{{Welcome|Returns the skin ID of the NPC.|&lt;br /&gt;
params=&amp;lt;source&amp;gt;NoParams&amp;lt;/source&amp;gt;|&lt;br /&gt;
example=&amp;lt;source&amp;gt;local myskin = GetMySkin()&amp;lt;/source&amp;gt;|&lt;br /&gt;
retvals=The Skin ID of the NPC.|&lt;br /&gt;
relfuncs=*[[GetPlayerSkin]]&lt;br /&gt;
*[[GetMyTeam]]|}}&lt;/div&gt;</summary>
		<author><name>Habi</name></author>
	</entry>
	<entry>
		<id>https://npc-for-vcmp.sourceforge.io/wikiw/index.php?title=GetMySkin&amp;diff=1889</id>
		<title>GetMySkin</title>
		<link rel="alternate" type="text/html" href="https://npc-for-vcmp.sourceforge.io/wikiw/index.php?title=GetMySkin&amp;diff=1889"/>
		<updated>2024-10-29T17:03:32Z</updated>

		<summary type="html">&lt;p&gt;Habi: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{v1_8_beta}}&lt;br /&gt;
{{Welcome|Returns the skin ID of the NPC.|&lt;br /&gt;
params=&amp;lt;source&amp;gt;NoParams&amp;lt;/source&amp;gt;|&lt;br /&gt;
example=&amp;lt;source&amp;gt;local myskin=GetMySkin()&amp;lt;/source&amp;gt;|&lt;br /&gt;
retvals=The Skin ID of the NPC.|&lt;br /&gt;
relfuncs=*[[GetPlayerSkin]]&lt;br /&gt;
*[[GetMyTeam]]|}}&lt;/div&gt;</summary>
		<author><name>Habi</name></author>
	</entry>
	<entry>
		<id>https://npc-for-vcmp.sourceforge.io/wikiw/index.php?title=GetMySkin&amp;diff=1888</id>
		<title>GetMySkin</title>
		<link rel="alternate" type="text/html" href="https://npc-for-vcmp.sourceforge.io/wikiw/index.php?title=GetMySkin&amp;diff=1888"/>
		<updated>2024-10-29T17:03:16Z</updated>

		<summary type="html">&lt;p&gt;Habi: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{v1_8_beta}}&lt;br /&gt;
{{Welcome|Returns the skin ID of the NPC.|&lt;br /&gt;
params=&amp;lt;source&amp;gt;NoParams&amp;lt;/source&amp;gt;|&lt;br /&gt;
example=&amp;lt;source inline&amp;gt;local myskin=GetMySkin()&amp;lt;/source&amp;gt;|&lt;br /&gt;
retvals=The Skin ID of the NPC.|&lt;br /&gt;
relfuncs=*[[GetPlayerSkin]]&lt;br /&gt;
*[[GetMyTeam]]|}}&lt;/div&gt;</summary>
		<author><name>Habi</name></author>
	</entry>
	<entry>
		<id>https://npc-for-vcmp.sourceforge.io/wikiw/index.php?title=GetMySkin&amp;diff=1887</id>
		<title>GetMySkin</title>
		<link rel="alternate" type="text/html" href="https://npc-for-vcmp.sourceforge.io/wikiw/index.php?title=GetMySkin&amp;diff=1887"/>
		<updated>2024-10-29T17:02:41Z</updated>

		<summary type="html">&lt;p&gt;Habi: Created page with &amp;quot;{{v1_8_beta}} {{Welcome|Returns the skin ID of the NPC.| params=&amp;lt;source&amp;gt;NoParams&amp;lt;/source&amp;gt;| example=&amp;lt;source inline&amp;gt;local myskin=GetMySkin()&amp;lt;/source&amp;gt;| retvals=The Skin ID of the NPC.| relfuncs=*GetPlayerSkin|}}&amp;quot;&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{v1_8_beta}}&lt;br /&gt;
{{Welcome|Returns the skin ID of the NPC.|&lt;br /&gt;
params=&amp;lt;source&amp;gt;NoParams&amp;lt;/source&amp;gt;|&lt;br /&gt;
example=&amp;lt;source inline&amp;gt;local myskin=GetMySkin()&amp;lt;/source&amp;gt;|&lt;br /&gt;
retvals=The Skin ID of the NPC.|&lt;br /&gt;
relfuncs=*[[GetPlayerSkin]]|}}&lt;/div&gt;</summary>
		<author><name>Habi</name></author>
	</entry>
	<entry>
		<id>https://npc-for-vcmp.sourceforge.io/wikiw/index.php?title=LookAtPos&amp;diff=1886</id>
		<title>LookAtPos</title>
		<link rel="alternate" type="text/html" href="https://npc-for-vcmp.sourceforge.io/wikiw/index.php?title=LookAtPos&amp;diff=1886"/>
		<updated>2024-10-29T16:58:39Z</updated>

		<summary type="html">&lt;p&gt;Habi: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Welcome|&lt;br /&gt;
desc=This function sets the angle of npc such that it looks at the position given|&lt;br /&gt;
params=&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
pos&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&amp;lt;poem&amp;gt;::pos : The Vector position to which npc must look&amp;lt;/poem&amp;gt;|&lt;br /&gt;
example=&lt;br /&gt;
The following code makes to look at player with ID 0.&lt;br /&gt;
&amp;lt;source lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
LookAtPos(GetPlayerPos(0))&amp;lt;/source&amp;gt;|&lt;br /&gt;
relfuncs=*[[LookAtPlayer]]|&lt;br /&gt;
retvals=true on success and false on failure (npc not spawned or npc is in vehicle).|&lt;br /&gt;
}}&lt;/div&gt;</summary>
		<author><name>Habi</name></author>
	</entry>
	<entry>
		<id>https://npc-for-vcmp.sourceforge.io/wikiw/index.php?title=LookAtPos&amp;diff=1885</id>
		<title>LookAtPos</title>
		<link rel="alternate" type="text/html" href="https://npc-for-vcmp.sourceforge.io/wikiw/index.php?title=LookAtPos&amp;diff=1885"/>
		<updated>2024-10-29T16:58:12Z</updated>

		<summary type="html">&lt;p&gt;Habi: Created page with &amp;quot;{{Welcome| desc=This function sets the angle of npc such that it looks at the position given| params=&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt; pos&amp;lt;/syntaxhighlight&amp;gt; &amp;lt;poem&amp;gt;::pos : The Vector position to which npc must look&amp;lt;/poem&amp;gt;| example= The following code makes to look at player with ID 0. &amp;lt;source lang=&amp;quot;lua&amp;quot;&amp;gt; LookAtPos(GetPlayerPos(0))&amp;lt;/source&amp;gt;| relfuncs=*LookAtPlayer| retvals=true on success and false on failure (npc not spawned or npc is in vehicle.| }}&amp;quot;&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Welcome|&lt;br /&gt;
desc=This function sets the angle of npc such that it looks at the position given|&lt;br /&gt;
params=&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
pos&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&amp;lt;poem&amp;gt;::pos : The Vector position to which npc must look&amp;lt;/poem&amp;gt;|&lt;br /&gt;
example=&lt;br /&gt;
The following code makes to look at player with ID 0.&lt;br /&gt;
&amp;lt;source lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
LookAtPos(GetPlayerPos(0))&amp;lt;/source&amp;gt;|&lt;br /&gt;
relfuncs=*[[LookAtPlayer]]|&lt;br /&gt;
retvals=true on success and false on failure (npc not spawned or npc is in vehicle.|&lt;br /&gt;
}}&lt;/div&gt;</summary>
		<author><name>Habi</name></author>
	</entry>
	<entry>
		<id>https://npc-for-vcmp.sourceforge.io/wikiw/index.php?title=Main_Page&amp;diff=1884</id>
		<title>Main Page</title>
		<link rel="alternate" type="text/html" href="https://npc-for-vcmp.sourceforge.io/wikiw/index.php?title=Main_Page&amp;diff=1884"/>
		<updated>2024-10-25T16:17:48Z</updated>

		<summary type="html">&lt;p&gt;Habi: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;__NOEDITSECTION__ __NOTOC__&lt;br /&gt;
&amp;lt;big&amp;gt;&lt;br /&gt;
== Introduction ==&lt;br /&gt;
NPCs (Non Player Characters) or bots can be created in vcmp server. They can be created at ammunition stores, toolshop or mall. They can chat with players, send command to server. They can be used to play a previous recording like driving a car around an area repeatedly. Like normal players, they use server slot.&lt;br /&gt;
Their intelligence can be scripted in separate squirrel scripts. These scripts with &#039;artificial intelligence&#039; of NPC reside in &#039;&#039;&#039;npcscripts&#039;&#039;&#039; directory. &lt;br /&gt;
&lt;br /&gt;
Each NPC run in its own process. The NPC scripts have functions as well as callbacks. &lt;br /&gt;
&lt;br /&gt;
Since v1.5, adding an npc is simple as a call to [[ConnectNPC]] and if you do not want to give npc any artificial intelligence, the script parameter can be omitted. &lt;br /&gt;
{| style=height:1em&lt;br /&gt;
|scope=&amp;quot;col&amp;quot; style=&amp;quot;width: 300px; text-align:left; vertical-align: top;&amp;quot;| &lt;br /&gt;
== NPC script callbacks ==&lt;br /&gt;
|scope=&amp;quot;col&amp;quot; style=&amp;quot;width: 630px;vertical-align: top;&amp;quot; |  &lt;br /&gt;
== NPC script functions == &lt;br /&gt;
|scope=&amp;quot;col&amp;quot; style=&amp;quot;width: 300px;vertical-align: top;&amp;quot; | &lt;br /&gt;
==ServerData ==&lt;br /&gt;
|-style=&amp;quot;vertical-align: top;&amp;quot;&lt;br /&gt;
| &lt;br /&gt;
* [[OnNPCScriptLoad]]&lt;br /&gt;
* [[OnNPCScriptUnload]]&lt;br /&gt;
* [[OnNPCConnect]]&lt;br /&gt;
* [[OnNPCDisconnect]]&lt;br /&gt;
* [[OnNPCSpawn]]&lt;br /&gt;
* [[OnNPCEnterVehicle]]&lt;br /&gt;
* [[OnNPCExitVehicle]]&lt;br /&gt;
* [[OnClientMessage]]&lt;br /&gt;
* [[OnPlayerDeath]]&lt;br /&gt;
* [[OnPlayerText]]&lt;br /&gt;
* [[OnPlayerStreamIn]]&lt;br /&gt;
* [[OnPlayerStreamOut]]&lt;br /&gt;
* [[OnVehicleStreamIn]]&lt;br /&gt;
* [[OnVehicleStreamOut]]&lt;br /&gt;
* [[OnRecordingPlaybackEnd]]        &lt;br /&gt;
* [[OnPlayerUpdate]]&lt;br /&gt;
* [[OnSniperRifleFired]]&lt;br /&gt;
* [[OnConsoleInput]]&lt;br /&gt;
* [[OnServerData]]&lt;br /&gt;
* [[OnExplosion]]&lt;br /&gt;
* [[OnProjectileFired]]&lt;br /&gt;
* [[OnNPCClassSelect]] &lt;br /&gt;
* [[OnServerShareTick]]&lt;br /&gt;
*[[OnTimeWeatherSync]]&lt;br /&gt;
==Constants==&lt;br /&gt;
* [[Bodypart| BodyParts]]&lt;br /&gt;
* [[field| LocalValue fields]]&lt;br /&gt;
* [[Keys|Game Keys]]&lt;br /&gt;
* [[Player_States|Player States]]&lt;br /&gt;
* [[Play_Flags|Play Flags]]&lt;br /&gt;
== Classes ==&lt;br /&gt;
*[[Vector]]&lt;br /&gt;
*[[Quaternion]]&lt;br /&gt;
== Player functions ==&lt;br /&gt;
*[[GetPlayerState]]&lt;br /&gt;
*[[GetPlayerPos]]&lt;br /&gt;
*[[GetPlayerVehicleID]]&lt;br /&gt;
*[[GetPlayerArmedWeapon]]&lt;br /&gt;
*[[GetPlayerHealth]]&lt;br /&gt;
*[[GetPlayerArmour]]&lt;br /&gt;
*[[GetPlayerKeys]]&lt;br /&gt;
*[[GetPlayerFacingAngle]]&lt;br /&gt;
*[[IsPlayerInRangeOfPoint]]&lt;br /&gt;
*[[GetPlayerName]]&lt;br /&gt;
*[[IsPlayerConnected]] &lt;br /&gt;
* [[GetPlayerSkin]] &lt;br /&gt;
* [[GetPlayerTeam]] &lt;br /&gt;
* [[GetPlayerSlotWeapon]] &lt;br /&gt;
* [[GetPlayerSlotAmmo]] &lt;br /&gt;
*[[GetPlayerSpeed]]&lt;br /&gt;
*[[GetPlayerAction]] &lt;br /&gt;
* [[WhereIsPlayer]] &lt;br /&gt;
== Modules ==&lt;br /&gt;
* [[LibRPC]]&lt;br /&gt;
* [[LibAction]]&lt;br /&gt;
* [[npcmodule]] (to be renamed)&lt;br /&gt;
* [[z-finder]] &lt;br /&gt;
== v1.8 ==&lt;br /&gt;
* [[Suicide]]&lt;br /&gt;
* [[SetMyHealth]]&lt;br /&gt;
* [[GetMyHealth]]&lt;br /&gt;
* [[LookAtPos]]&lt;br /&gt;
* [[LookAtPlayer]]&lt;br /&gt;
* [[GetMyClass]]&lt;br /&gt;
* [[RequestClassAbs]]&lt;br /&gt;
* [[AmISpawned]]&lt;br /&gt;
* [[GetMySkin]]&lt;br /&gt;
* [[GetMyTeam]]&lt;br /&gt;
* [[GetMyArmour]]&lt;br /&gt;
* [[SendPrivMsg]]&lt;br /&gt;
* [[SetConfig]]&lt;br /&gt;
* [[GetPlayerColor]]&lt;br /&gt;
* [[GetMyColor]]&lt;br /&gt;
* [[IsPlaybackRunning]]&lt;br /&gt;
* [[IsPlaybackPaused]]&lt;br /&gt;
* [[InPoly]]&lt;br /&gt;
 || &lt;br /&gt;
* [[StartRecordingPlayback]]&lt;br /&gt;
* [[StopRecordingPlayback]]&lt;br /&gt;
* [[PauseRecordingPlayback]]&lt;br /&gt;
* [[ResumeRecordingPlayback]]&lt;br /&gt;
* [[SendChat]]&lt;br /&gt;
* [[SendCommand]]&lt;br /&gt;
* [[GetMyPos]]&lt;br /&gt;
* [[SetMyPos]]&lt;br /&gt;
* [[GetMyFacingAngle]]&lt;br /&gt;
* [[SetMyFacingAngle]]&lt;br /&gt;
* [[GetDistanceFromMeToPoint]]&lt;br /&gt;
* [[IsVehicleStreamedIn]]&lt;br /&gt;
* [[IsPlayerStreamedIn]]&lt;br /&gt;
* [[SelectWeapon]] (v1.6 b4p2)&lt;br /&gt;
* [[GetAvailableWeapons]]&lt;br /&gt;
* [[GetAmmoOfMyWeapon]]&lt;br /&gt;
* [[SetTimer]]&lt;br /&gt;
* [[SetTimerEx]] &lt;br /&gt;
* [[KillTimer]]&lt;br /&gt;
* [[GetMyName]] &lt;br /&gt;
* [[GetMyID]] &lt;br /&gt;
* [[QuitServer]]&lt;br /&gt;
* [[RequestClass]]&lt;br /&gt;
* [[ReqeustClassAbs]]&lt;br /&gt;
* [[RequestSpawn]]&lt;br /&gt;
* [[GetTickCount]]&lt;br /&gt;
* [[GetClosestPlayer]]&lt;br /&gt;
* [[GetSlotFromWeaponId]] &lt;br /&gt;
* [[FaceNPCToPlayer]]&lt;br /&gt;
==Advanced functions==&lt;br /&gt;
* [[SendOnFootSyncData]]&lt;br /&gt;
* [[SendOnFootSyncDataEx]]&lt;br /&gt;
* [[SendOnFootSyncDataLV]]&lt;br /&gt;
* [[SendInCarSyncData]]&lt;br /&gt;
* [[SendInCarSyncDataEx]]&lt;br /&gt;
* [[SendInCarSyncDataLV]]&lt;br /&gt;
* [[SendPassengerSyncData]]&lt;br /&gt;
* [[FireSniperRifle]]&lt;br /&gt;
* [[FireSniperRifleEx]]&lt;br /&gt;
* [[FireProjectile]]&lt;br /&gt;
* [[SendShotInfo]]&lt;br /&gt;
* [[SendDeathInfo]]&lt;br /&gt;
* [[GetLocalValue]]&lt;br /&gt;
* [[SetLocalValue]]&lt;br /&gt;
== Functions used only in server scripts==&lt;br /&gt;
* [[ConnectNPC]]&lt;br /&gt;
* [[ConnectNPCEx]]&lt;br /&gt;
* [[IsPlayerNPC]]&lt;br /&gt;
* [[ShowNPCConsole]]&lt;br /&gt;
* [[StartRecordingPlayerData]]&lt;br /&gt;
* [[StopRecordingPlayerData]]&lt;br /&gt;
* [[RFC]]&lt;br /&gt;
* [[F]]&lt;br /&gt;
* [[Examples]] (Remote calls)&lt;br /&gt;
* [[StartRecordingAllPlayerData]] (v1.8)&lt;br /&gt;
* [[StopRecordingAllPlayerData]]&lt;br /&gt;
* [[PutServerInRecordingMode]]&lt;br /&gt;
* [[StopServerInRecordingMode]]&lt;br /&gt;
* [[IsPlayerRecording]]&lt;br /&gt;
* [[IsServerInRecordingMode]]&lt;br /&gt;
* [[ConnectMultipleNpcs]]&lt;br /&gt;
* [[StopConnectingMultipleNpcs]]&lt;br /&gt;
* [[Server.cfg|server.cfg values]]&lt;br /&gt;
==Tools==&lt;br /&gt;
* [[recupdate]]&lt;br /&gt;
* [[recEdit]]&lt;br /&gt;
==0.4.7.1==&lt;br /&gt;
* [[FireBullet]]&lt;br /&gt;
* [[OnBulletFired]]&lt;br /&gt;
==Store==&lt;br /&gt;
* [[GetStoreLocation]]&lt;br /&gt;
* [[IsStoreDownloading]]&lt;br /&gt;
* [[OnStoreDownloadComplete]]&lt;br /&gt;
* [[GetStoreURL]]&lt;br /&gt;
||&lt;br /&gt;
* [[SendServerData]]&lt;br /&gt;
* [[ReadInt]]&lt;br /&gt;
* [[ReadByte]]&lt;br /&gt;
* [[ReadFloat]]&lt;br /&gt;
* [[ReadString]]&lt;br /&gt;
* [[WriteInt]]&lt;br /&gt;
*[[WriteByte]]&lt;br /&gt;
*[[WriteFloat]]&lt;br /&gt;
*[[WriteString]]&lt;br /&gt;
==Pickup==&lt;br /&gt;
*[[ClaimPickup]]&lt;br /&gt;
*[[IsPickupStreamedIn]]&lt;br /&gt;
*[[GetPickupModel]]&lt;br /&gt;
*[[GetPickupAlpha]]&lt;br /&gt;
*[[GetPickupQuantity]]&lt;br /&gt;
*[[GetPickupPos]]&lt;br /&gt;
*[[GetPickupCount]]&lt;br /&gt;
*[[OnPickupStreamIn]]&lt;br /&gt;
*[[OnPickupDestroyed]]&lt;br /&gt;
*[[OnPickupUpdate]]&lt;br /&gt;
==Checkpoint==&lt;br /&gt;
*[[OnCheckpointStreamIn]]&lt;br /&gt;
*[[OnCheckpointDestroyed]]&lt;br /&gt;
*[[OnCheckpointUpdate]]&lt;br /&gt;
*[[IsCheckpointStreamedIn]]&lt;br /&gt;
*[[GetCheckpointRadius]]&lt;br /&gt;
*[[GetCheckpointPos]]&lt;br /&gt;
*[[GetCheckpointColor]]&lt;br /&gt;
*[[IsCheckpointSphere]]&lt;br /&gt;
*[[ClaimEnterCheckpoint]]&lt;br /&gt;
*[[ClaimExitCheckpoint]]&lt;br /&gt;
*[[GetCheckpointCount]]&lt;br /&gt;
==Vehicle==&lt;br /&gt;
*[[EnterVehicle]]&lt;br /&gt;
*[[GetVehicleDriver]]&lt;br /&gt;
*[[GetVehicleModel]]&lt;br /&gt;
*[[GetVehicleTurretRot]]&lt;br /&gt;
*[[GetVehicleRotation]]&lt;br /&gt;
*[[GetVehiclePos]]&lt;br /&gt;
*[[GetVehicleSpeed]]&lt;br /&gt;
*[[GetVehicleHealth]]&lt;br /&gt;
*[[GetVehicleDamage]]&lt;br /&gt;
*[[ExitVehicle]] &lt;br /&gt;
*[[ExitVehicleEx]] &lt;br /&gt;
==Objects==&lt;br /&gt;
*[[OnObjectStreamIn]]&lt;br /&gt;
*[[OnObjectDestroyed]]&lt;br /&gt;
*[[OnObjectUpdate]]&lt;br /&gt;
*[[IsObjectStreamedIn]]&lt;br /&gt;
*[[GetObjectModel]]&lt;br /&gt;
*[[GetObjectPos]]&lt;br /&gt;
*[[GetObjectRotation]]&lt;br /&gt;
*[[GetObjectAlpha]]&lt;br /&gt;
*[[IsObjectTouchReportEnabled]]&lt;br /&gt;
*[[IsObjectShotReportEnabled]]&lt;br /&gt;
*[[ClaimObjectTouch]]&lt;br /&gt;
*[[ClaimObjectShot]]&lt;br /&gt;
*[[GetObjectCount]]&lt;br /&gt;
== More ==&lt;br /&gt;
*[[NPC Installation]]&lt;br /&gt;
* [[Squirrel Standard Library Functions]]&lt;br /&gt;
* [[NPCHide]]&lt;br /&gt;
* [[Command-line usage]]&lt;br /&gt;
* [[Attack Script]] (v1.5)&lt;br /&gt;
* [[walking_man|Walking cop script]]&lt;br /&gt;
|}&lt;br /&gt;
&amp;lt;/big&amp;gt;&lt;br /&gt;
&amp;lt;poem style=&amp;quot;border: 2px solid #d6d2c5; background-color: #19f4e6; &amp;quot;&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;04 February 2023: Hiding/Changing name of NPC In-Game New Plugin. [[NPCHide|see]]&lt;br /&gt;
&amp;lt;/poem&amp;gt;&lt;br /&gt;
&amp;lt;Poem style=&amp;quot;border: 2px solid #4682B4; background-color: #FFE4B5; &amp;quot;&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;03 October 2024: NPC v1.8 Beta 3 is released&#039;&#039;&#039;. (new) [[V1_8_beta3_release_notes|&#039;&#039;&#039;click here&#039;&#039;&#039;]]&lt;br /&gt;
&amp;lt;/poem&amp;gt;&lt;br /&gt;
&amp;lt;Poem style=&amp;quot;border: 2px solid #4682B4; background-color: #FFE4B5; &amp;quot;&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;25 October 2024: NPC v1.8 Beta 4&#039;&#039;&#039;. (new) [[V1_8_beta4_release_notes|&#039;&#039;&#039;click here&#039;&#039;&#039;]]&lt;br /&gt;
&amp;lt;/poem&amp;gt;&lt;/div&gt;</summary>
		<author><name>Habi</name></author>
	</entry>
	<entry>
		<id>https://npc-for-vcmp.sourceforge.io/wikiw/index.php?title=V1_8_beta4_release_notes&amp;diff=1883</id>
		<title>V1 8 beta4 release notes</title>
		<link rel="alternate" type="text/html" href="https://npc-for-vcmp.sourceforge.io/wikiw/index.php?title=V1_8_beta4_release_notes&amp;diff=1883"/>
		<updated>2024-10-25T16:16:52Z</updated>

		<summary type="html">&lt;p&gt;Habi: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;poem style=&amp;quot;border: 2px solid #d6d2c5; background-color: #ffd789; padding: 1em;&amp;quot;&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Version 1.8 beta 4&#039;&#039;&#039;&lt;br /&gt;
Release date : 24.October.2024&lt;br /&gt;
&amp;lt;/poem&amp;gt;&lt;br /&gt;
*Fixed Vehicle Driver not reset(GetVehicleDriver) when a player as driver exit the  vehicle.&lt;br /&gt;
*Added function [[FireBullet]] reenabling npc to shoot things.&lt;br /&gt;
*API is now 1.8&lt;br /&gt;
*Fixed npc not able to get into vehicle as driver when player is inside vehicle as passenger.&lt;br /&gt;
*Fixed npc not closing doors after exiting vehicle.&lt;br /&gt;
*Npcclient can now download store files (-d or -D &amp;quot;relative/path/to/new/download/location&amp;quot; )&lt;br /&gt;
*Added function to get store-url of server ( GetStoreURL() )&lt;br /&gt;
*Added command-line argument to disable automatic spawn of npc. (-M --Manual-Spawn)&lt;br /&gt;
*Fixed bug with API(plugin.h) causing crash( LibAction, npcmodule )&lt;br /&gt;
*Added a small table in squirrel script called &#039;npc&#039;, which has functions npc.fire(), npc.punch(), npc.wep(), npc.prewep(), npc.sit() and npc.stand()&lt;br /&gt;
&lt;br /&gt;
==API Version==&lt;br /&gt;
1.8&lt;br /&gt;
&lt;br /&gt;
==Rec Files Version==&lt;br /&gt;
*Plays rec files with identifier 1004, 1005&lt;br /&gt;
*Creates rec files with identifier 1005&lt;br /&gt;
&lt;br /&gt;
== Downloads ==&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! Operating system !! Version !! Link&lt;br /&gt;
|-&lt;br /&gt;
| Windows || 0.4.7.1 || [https://sourceforge.net/projects/npc-for-vcmp/files/npc_vcmp_0471_windows_v1.8-beta-4.zip/download npc_vcmp_0471_windows_v1.8-beta-4.zip]&lt;br /&gt;
|-&lt;br /&gt;
| Linux x64 || 0.4.7.1 || [https://sourceforge.net/projects/npc-for-vcmp/files/npc_vcmp_0471_linux_x64_v1.8-beta-4.zip/download npc_vcmp_0471_linux_x64_v1.8-beta-4.zip]&lt;br /&gt;
|-&lt;br /&gt;
| Linux x86 || 0.4.7.1 || [https://sourceforge.net/projects/npc-for-vcmp/files/npc_vcmp_0471_linux_x86_v1.8-beta-4.zip/download npc_vcmp_0471_linux_x86_v1.8-beta-4.zip]&lt;br /&gt;
|-&lt;br /&gt;
| Windows || rel006 || [https://sourceforge.net/projects/npc-for-vcmp/files/npc_vcmp_rel006_windows_v1.8-beta-4.zip/download npc_vcmp_rel006_windows_v1.8-beta-4.zip]&lt;br /&gt;
|-&lt;br /&gt;
| Linux x64 || rel006 || [https://sourceforge.net/projects/npc-for-vcmp/files/npc_vcmp_rel006_linux_x64_v1.8-beta-4.zip/download npc_vcmp_rel006_linux_x64_v1.8-beta-4.zip]&lt;br /&gt;
|-&lt;br /&gt;
| Linux x86 || rel006 || [https://sourceforge.net/projects/npc-for-vcmp/files/npc_vcmp_rel006_linux_x86_v1.8-beta-4.zip/download npc_vcmp_rel006_linux_x86_v1.8-beta-4.zip]&lt;br /&gt;
|-&lt;br /&gt;
| Windows/Linux (rel004) || rel004 || [https://sourceforge.net/projects/npc-for-vcmp/files/npc_vcmp_rel004_win_lin_v1.8-beta-4.zip/download npc_vcmp_rel004_win_lin_v1.8-beta-4.zip]&lt;br /&gt;
|-&lt;br /&gt;
| Source Code || All || [https://sourceforge.net/projects/npc-for-vcmp/files/NPC-VCMP-master-v1.8-beta-4.zip/download NPC-VCMP-master-v1.8-beta-4.zip]&lt;br /&gt;
|-&lt;br /&gt;
| API Plugin || 1.8 || [https://sourceforge.net/projects/npc-for-vcmp/files/npc_vcmp_plugin_API_1_8.zip/download npc_vcmp_plugin_API_1_8.zip]&lt;br /&gt;
|-&lt;br /&gt;
| Windows (Setup) || rel004, rel006, 0.4.7.1 || [https://sourceforge.net/projects/npc-for-vcmp/files/npcclient_v1.8_beta4_setup.exe/download npcclient_v1.8_beta4_setup.exe]&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==Related==&lt;br /&gt;
*[[v1_8_beta3_release_notes| 1.8 beta 3]] (01.October 2024)&lt;br /&gt;
*[[v1_8_beta_release_notes| 1.8 beta]] (29.February 2024)&lt;br /&gt;
*[[V1_7_beta3_release_notes| 1.7 beta3]] (08.October.2023)&lt;br /&gt;
*[[V1_7_beta2_release_notes| 1.7 beta2]] (28.August.2023)&lt;br /&gt;
*[[V1_7_beta_release_notes| 1.7 beta]] (24.August.2023)&lt;/div&gt;</summary>
		<author><name>Habi</name></author>
	</entry>
	<entry>
		<id>https://npc-for-vcmp.sourceforge.io/wikiw/index.php?title=V1_8_beta4_release_notes&amp;diff=1882</id>
		<title>V1 8 beta4 release notes</title>
		<link rel="alternate" type="text/html" href="https://npc-for-vcmp.sourceforge.io/wikiw/index.php?title=V1_8_beta4_release_notes&amp;diff=1882"/>
		<updated>2024-10-25T16:14:39Z</updated>

		<summary type="html">&lt;p&gt;Habi: /* Downloads */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;poem style=&amp;quot;border: 2px solid #d6d2c5; background-color: #ffd789; padding: 1em;&amp;quot;&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Version 1.8 beta 4&#039;&#039;&#039;&lt;br /&gt;
Release date : 24.October.2024&lt;br /&gt;
&amp;lt;/poem&amp;gt;&lt;br /&gt;
*Fixed Vehicle Driver not reset(GetVehicleDriver) when a player as driver exit the  vehicle.&lt;br /&gt;
*Added function [[FireBullet]] reenabling npc to shoot things.&lt;br /&gt;
*API is now 1.8&lt;br /&gt;
*Fixed npc not able to get into vehicle as driver when player is inside vehicle as passenger.&lt;br /&gt;
*Fixed npc not closing doors after exiting vehicle.&lt;br /&gt;
*Npcclient can now download store files (-d or -D &amp;quot;relative/path/to/new/download/location&amp;quot; )&lt;br /&gt;
*Added function to get store-url of server ( GetStoreURL() )&lt;br /&gt;
*Added command-line argument to disable automatic spawn of npc. (-M --Manual-Spawn)&lt;br /&gt;
*Fixed bug with API(plugin.h) causing crash( LibAction, npcmodule )&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==API Version==&lt;br /&gt;
1.8&lt;br /&gt;
&lt;br /&gt;
==Rec Files Version==&lt;br /&gt;
*Plays rec files with identifier 1004, 1005&lt;br /&gt;
*Creates rec files with identifier 1005&lt;br /&gt;
&lt;br /&gt;
== Downloads ==&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! Operating system !! Version !! Link&lt;br /&gt;
|-&lt;br /&gt;
| Windows || 0.4.7.1 || [https://sourceforge.net/projects/npc-for-vcmp/files/npc_vcmp_0471_windows_v1.8-beta-4.zip/download npc_vcmp_0471_windows_v1.8-beta-4.zip]&lt;br /&gt;
|-&lt;br /&gt;
| Linux x64 || 0.4.7.1 || [https://sourceforge.net/projects/npc-for-vcmp/files/npc_vcmp_0471_linux_x64_v1.8-beta-4.zip/download npc_vcmp_0471_linux_x64_v1.8-beta-4.zip]&lt;br /&gt;
|-&lt;br /&gt;
| Linux x86 || 0.4.7.1 || [https://sourceforge.net/projects/npc-for-vcmp/files/npc_vcmp_0471_linux_x86_v1.8-beta-4.zip/download npc_vcmp_0471_linux_x86_v1.8-beta-4.zip]&lt;br /&gt;
|-&lt;br /&gt;
| Windows || rel006 || [https://sourceforge.net/projects/npc-for-vcmp/files/npc_vcmp_rel006_windows_v1.8-beta-4.zip/download npc_vcmp_rel006_windows_v1.8-beta-4.zip]&lt;br /&gt;
|-&lt;br /&gt;
| Linux x64 || rel006 || [https://sourceforge.net/projects/npc-for-vcmp/files/npc_vcmp_rel006_linux_x64_v1.8-beta-4.zip/download npc_vcmp_rel006_linux_x64_v1.8-beta-4.zip]&lt;br /&gt;
|-&lt;br /&gt;
| Linux x86 || rel006 || [https://sourceforge.net/projects/npc-for-vcmp/files/npc_vcmp_rel006_linux_x86_v1.8-beta-4.zip/download npc_vcmp_rel006_linux_x86_v1.8-beta-4.zip]&lt;br /&gt;
|-&lt;br /&gt;
| Windows/Linux (rel004) || rel004 || [https://sourceforge.net/projects/npc-for-vcmp/files/npc_vcmp_rel004_win_lin_v1.8-beta-4.zip/download npc_vcmp_rel004_win_lin_v1.8-beta-4.zip]&lt;br /&gt;
|-&lt;br /&gt;
| Source Code || All || [https://sourceforge.net/projects/npc-for-vcmp/files/NPC-VCMP-master-v1.8-beta-4.zip/download NPC-VCMP-master-v1.8-beta-4.zip]&lt;br /&gt;
|-&lt;br /&gt;
| API Plugin || 1.8 || [https://sourceforge.net/projects/npc-for-vcmp/files/npc_vcmp_plugin_API_1_8.zip/download npc_vcmp_plugin_API_1_8.zip]&lt;br /&gt;
|-&lt;br /&gt;
| Windows (Setup) || rel004, rel006, 0.4.7.1 || [https://sourceforge.net/projects/npc-for-vcmp/files/npcclient_v1.8_beta4_setup.exe/download npcclient_v1.8_beta4_setup.exe]&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==Related==&lt;br /&gt;
*[[v1_8_beta3_release_notes| 1.8 beta 3]] (01.October 2024)&lt;br /&gt;
*[[v1_8_beta_release_notes| 1.8 beta]] (29.February 2024)&lt;br /&gt;
*[[V1_7_beta3_release_notes| 1.7 beta3]] (08.October.2023)&lt;br /&gt;
*[[V1_7_beta2_release_notes| 1.7 beta2]] (28.August.2023)&lt;br /&gt;
*[[V1_7_beta_release_notes| 1.7 beta]] (24.August.2023)&lt;/div&gt;</summary>
		<author><name>Habi</name></author>
	</entry>
	<entry>
		<id>https://npc-for-vcmp.sourceforge.io/wikiw/index.php?title=V1_8_beta4_release_notes&amp;diff=1881</id>
		<title>V1 8 beta4 release notes</title>
		<link rel="alternate" type="text/html" href="https://npc-for-vcmp.sourceforge.io/wikiw/index.php?title=V1_8_beta4_release_notes&amp;diff=1881"/>
		<updated>2024-10-25T16:01:45Z</updated>

		<summary type="html">&lt;p&gt;Habi: /* Downloads */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;poem style=&amp;quot;border: 2px solid #d6d2c5; background-color: #ffd789; padding: 1em;&amp;quot;&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Version 1.8 beta 4&#039;&#039;&#039;&lt;br /&gt;
Release date : 24.October.2024&lt;br /&gt;
&amp;lt;/poem&amp;gt;&lt;br /&gt;
*Fixed Vehicle Driver not reset(GetVehicleDriver) when a player as driver exit the  vehicle.&lt;br /&gt;
*Added function [[FireBullet]] reenabling npc to shoot things.&lt;br /&gt;
*API is now 1.8&lt;br /&gt;
*Fixed npc not able to get into vehicle as driver when player is inside vehicle as passenger.&lt;br /&gt;
*Fixed npc not closing doors after exiting vehicle.&lt;br /&gt;
*Npcclient can now download store files (-d or -D &amp;quot;relative/path/to/new/download/location&amp;quot; )&lt;br /&gt;
*Added function to get store-url of server ( GetStoreURL() )&lt;br /&gt;
*Added command-line argument to disable automatic spawn of npc. (-M --Manual-Spawn)&lt;br /&gt;
*Fixed bug with API(plugin.h) causing crash( LibAction, npcmodule )&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==API Version==&lt;br /&gt;
1.8&lt;br /&gt;
&lt;br /&gt;
==Rec Files Version==&lt;br /&gt;
*Plays rec files with identifier 1004, 1005&lt;br /&gt;
*Creates rec files with identifier 1005&lt;br /&gt;
&lt;br /&gt;
== Downloads ==&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! Operating system !! Version !! Link&lt;br /&gt;
|-&lt;br /&gt;
| Windows || 0.4.7.1 || [https://sourceforge.net/projects/npc-for-vcmp/files/npc_vcmp_0471_windows_v1.8-beta-4.zip/download npc_vcmp_0471_windows_v1.8-beta-4.zip]&lt;br /&gt;
|-&lt;br /&gt;
| Linux x64 || 0.4.7.1 || [https://sourceforge.net/projects/npc-for-vcmp/files/npc_vcmp_0471_linux_x64_v1.8-beta-4.zip/download npc_vcmp_0471_linux_x64_v1.8-beta-4.zip]&lt;br /&gt;
|-&lt;br /&gt;
| Linux x86 || 0.4.7.1 || [https://sourceforge.net/projects/npc-for-vcmp/files/npc_vcmp_0471_linux_x86_v1.8-beta-4.zip/download npc_vcmp_0471_linux_x86_v1.8-beta-4.zip]&lt;br /&gt;
|-&lt;br /&gt;
| Windows || rel006 || [https://sourceforge.net/projects/npc-for-vcmp/files/npc_vcmp_rel006_windows_v1.8-beta-4.zip/download npc_vcmp_rel006_windows_v1.8-beta-4.zip]&lt;br /&gt;
|-&lt;br /&gt;
| Linux x64 || rel006 || [https://sourceforge.net/projects/npc-for-vcmp/files/npc_vcmp_rel006_linux_x64_v1.8-beta-4.zip/download npc_vcmp_rel006_linux_x64_v1.8-beta-4.zip]&lt;br /&gt;
|-&lt;br /&gt;
| Linux x86 || rel006 || [https://sourceforge.net/projects/npc-for-vcmp/files/npc_vcmp_rel006_linux_x86_v1.8-beta-4.zip/download npc_vcmp_rel006_linux_x86_v1.8-beta-4.zip]&lt;br /&gt;
|-&lt;br /&gt;
| Windows/Linux (rel004) || rel004 || [https://sourceforge.net/projects/npc-for-vcmp/files/npc_vcmp_rel004_win_lin_v1.8-beta-4.zip/download npc_vcmp_rel004_win_lin_v1.8-beta-4.zip]&lt;br /&gt;
|-&lt;br /&gt;
| Source Code || rel006 || [https://sourceforge.net/projects/npc-for-vcmp/files/NPC-VCMP-master-v1.8-beta-4.zip/download NPC-VCMP-master-v1.8-beta-4.zip]&lt;br /&gt;
|-&lt;br /&gt;
| API Plugin || 1.8 || [https://sourceforge.net/projects/npc-for-vcmp/files/npc_vcmp_plugin_API_1_8.zip/download npc_vcmp_plugin_API_1_8.zip]&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==Related==&lt;br /&gt;
*[[v1_8_beta3_release_notes| 1.8 beta 3]] (01.October 2024)&lt;br /&gt;
*[[v1_8_beta_release_notes| 1.8 beta]] (29.February 2024)&lt;br /&gt;
*[[V1_7_beta3_release_notes| 1.7 beta3]] (08.October.2023)&lt;br /&gt;
*[[V1_7_beta2_release_notes| 1.7 beta2]] (28.August.2023)&lt;br /&gt;
*[[V1_7_beta_release_notes| 1.7 beta]] (24.August.2023)&lt;/div&gt;</summary>
		<author><name>Habi</name></author>
	</entry>
	<entry>
		<id>https://npc-for-vcmp.sourceforge.io/wikiw/index.php?title=V1_8_beta4_release_notes&amp;diff=1880</id>
		<title>V1 8 beta4 release notes</title>
		<link rel="alternate" type="text/html" href="https://npc-for-vcmp.sourceforge.io/wikiw/index.php?title=V1_8_beta4_release_notes&amp;diff=1880"/>
		<updated>2024-10-25T16:01:10Z</updated>

		<summary type="html">&lt;p&gt;Habi: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;poem style=&amp;quot;border: 2px solid #d6d2c5; background-color: #ffd789; padding: 1em;&amp;quot;&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Version 1.8 beta 4&#039;&#039;&#039;&lt;br /&gt;
Release date : 24.October.2024&lt;br /&gt;
&amp;lt;/poem&amp;gt;&lt;br /&gt;
*Fixed Vehicle Driver not reset(GetVehicleDriver) when a player as driver exit the  vehicle.&lt;br /&gt;
*Added function [[FireBullet]] reenabling npc to shoot things.&lt;br /&gt;
*API is now 1.8&lt;br /&gt;
*Fixed npc not able to get into vehicle as driver when player is inside vehicle as passenger.&lt;br /&gt;
*Fixed npc not closing doors after exiting vehicle.&lt;br /&gt;
*Npcclient can now download store files (-d or -D &amp;quot;relative/path/to/new/download/location&amp;quot; )&lt;br /&gt;
*Added function to get store-url of server ( GetStoreURL() )&lt;br /&gt;
*Added command-line argument to disable automatic spawn of npc. (-M --Manual-Spawn)&lt;br /&gt;
*Fixed bug with API(plugin.h) causing crash( LibAction, npcmodule )&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==API Version==&lt;br /&gt;
1.8&lt;br /&gt;
&lt;br /&gt;
==Rec Files Version==&lt;br /&gt;
*Plays rec files with identifier 1004, 1005&lt;br /&gt;
*Creates rec files with identifier 1005&lt;br /&gt;
&lt;br /&gt;
== Downloads ==&lt;br /&gt;
== Downloads ==&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! Operating system !! Version !! Link&lt;br /&gt;
|-&lt;br /&gt;
| Windows || 0.4.7.1 || [https://sourceforge.net/projects/npc-for-vcmp/files/npc_vcmp_0471_windows_v1.8-beta-4.zip/download npc_vcmp_0471_windows_v1.8-beta-4.zip]&lt;br /&gt;
|-&lt;br /&gt;
| Linux x64 || 0.4.7.1 || [https://sourceforge.net/projects/npc-for-vcmp/files/npc_vcmp_0471_linux_x64_v1.8-beta-4.zip/download npc_vcmp_0471_linux_x64_v1.8-beta-4.zip]&lt;br /&gt;
|-&lt;br /&gt;
| Linux x86 || 0.4.7.1 || [https://sourceforge.net/projects/npc-for-vcmp/files/npc_vcmp_0471_linux_x86_v1.8-beta-4.zip/download npc_vcmp_0471_linux_x86_v1.8-beta-4.zip]&lt;br /&gt;
|-&lt;br /&gt;
| Windows || rel006 || [https://sourceforge.net/projects/npc-for-vcmp/files/npc_vcmp_rel006_windows_v1.8-beta-4.zip/download npc_vcmp_rel006_windows_v1.8-beta-4.zip]&lt;br /&gt;
|-&lt;br /&gt;
| Linux x64 || rel006 || [https://sourceforge.net/projects/npc-for-vcmp/files/npc_vcmp_rel006_linux_x64_v1.8-beta-4.zip/download npc_vcmp_rel006_linux_x64_v1.8-beta-4.zip]&lt;br /&gt;
|-&lt;br /&gt;
| Linux x86 || rel006 || [https://sourceforge.net/projects/npc-for-vcmp/files/npc_vcmp_rel006_linux_x86_v1.8-beta-4.zip/download npc_vcmp_rel006_linux_x86_v1.8-beta-4.zip]&lt;br /&gt;
|-&lt;br /&gt;
| Windows/Linux (rel004) || rel004 || [https://sourceforge.net/projects/npc-for-vcmp/files/npc_vcmp_rel004_win_lin_v1.8-beta-4.zip/download npc_vcmp_rel004_win_lin_v1.8-beta-4.zip]&lt;br /&gt;
|-&lt;br /&gt;
| Source Code || rel006 || [https://sourceforge.net/projects/npc-for-vcmp/files/NPC-VCMP-master-v1.8-beta-4.zip/download NPC-VCMP-master-v1.8-beta-4.zip]&lt;br /&gt;
|-&lt;br /&gt;
| API Plugin || 1.8 || [https://sourceforge.net/projects/npc-for-vcmp/files/npc_vcmp_plugin_API_1_8.zip/download npc_vcmp_plugin_API_1_8.zip]&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==Related==&lt;br /&gt;
*[[v1_8_beta3_release_notes| 1.8 beta 3]] (01.October 2024)&lt;br /&gt;
*[[v1_8_beta_release_notes| 1.8 beta]] (29.February 2024)&lt;br /&gt;
*[[V1_7_beta3_release_notes| 1.7 beta3]] (08.October.2023)&lt;br /&gt;
*[[V1_7_beta2_release_notes| 1.7 beta2]] (28.August.2023)&lt;br /&gt;
*[[V1_7_beta_release_notes| 1.7 beta]] (24.August.2023)&lt;/div&gt;</summary>
		<author><name>Habi</name></author>
	</entry>
	<entry>
		<id>https://npc-for-vcmp.sourceforge.io/wikiw/index.php?title=Field&amp;diff=1879</id>
		<title>Field</title>
		<link rel="alternate" type="text/html" href="https://npc-for-vcmp.sourceforge.io/wikiw/index.php?title=Field&amp;diff=1879"/>
		<updated>2024-10-23T18:58:55Z</updated>

		<summary type="html">&lt;p&gt;Habi: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;big&amp;gt;To be used with [[SetLocalValue]]. I_xx means integer, F_yy means float and V_ means vector. &lt;br /&gt;
For example &amp;lt;source inline&amp;gt;GetLocalValue(F_CAR_HEALTH)&amp;lt;/source&amp;gt; returns the health of the car in which npc is currently sitting.&lt;br /&gt;
&amp;lt;source lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
I_KEYS &lt;br /&gt;
F_POSX&lt;br /&gt;
F_POSY&lt;br /&gt;
F_POSZ&lt;br /&gt;
F_ANGLE&lt;br /&gt;
I_HEALTH&lt;br /&gt;
I_ARMOUR&lt;br /&gt;
I_CURWEP&lt;br /&gt;
I_CURWEP_AMMO &lt;br /&gt;
I_ACTION (since 1.7 beta2)&lt;br /&gt;
V_ONFOOT_SPEED (since v1.6 beta3)&lt;br /&gt;
V_AIMPOS (since v1.6 beta3)&lt;br /&gt;
V_AIMDIR (since v1.6 beta3)&lt;br /&gt;
V_POS&lt;br /&gt;
Q_CAR_ROTATION&lt;br /&gt;
V_CAR_SPEED&lt;br /&gt;
I_CAR_DAMAGE&lt;br /&gt;
F_CAR_HEALTH&lt;br /&gt;
F_CAR_TURRETX&lt;br /&gt;
F_CAR_TURRETY&lt;br /&gt;
B_CROUCHING (since v1.8 beta 4)&lt;br /&gt;
B_RELOADING (since v1.8 beta 4)&lt;br /&gt;
B_AIM_UPDATE (since v1.8 beta 4)  //true for firing&lt;br /&gt;
&amp;lt;/source&amp;gt;&amp;lt;/big&amp;gt;&lt;/div&gt;</summary>
		<author><name>Habi</name></author>
	</entry>
	<entry>
		<id>https://npc-for-vcmp.sourceforge.io/wikiw/index.php?title=Field&amp;diff=1878</id>
		<title>Field</title>
		<link rel="alternate" type="text/html" href="https://npc-for-vcmp.sourceforge.io/wikiw/index.php?title=Field&amp;diff=1878"/>
		<updated>2024-10-23T18:49:20Z</updated>

		<summary type="html">&lt;p&gt;Habi: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;big&amp;gt;To be used with [[SetLocalValue]]. I_xx means integer, F_yy means float and V_ means vector. &lt;br /&gt;
For example &amp;lt;source inline&amp;gt;GetLocalValue(F_CAR_HEALTH)&amp;lt;/source&amp;gt; returns the health of the car in which npc is currently sitting.&lt;br /&gt;
&amp;lt;source lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
I_KEYS &lt;br /&gt;
F_POSX&lt;br /&gt;
F_POSY&lt;br /&gt;
F_POSZ&lt;br /&gt;
F_ANGLE&lt;br /&gt;
I_HEALTH&lt;br /&gt;
I_ARMOUR&lt;br /&gt;
I_CURWEP&lt;br /&gt;
I_CURWEP_AMMO &lt;br /&gt;
I_ACTION (since 1.7 beta2)&lt;br /&gt;
V_ONFOOT_SPEED (since v1.6 beta3)&lt;br /&gt;
V_AIMPOS (since v1.6 beta3)&lt;br /&gt;
V_AIMDIR (since v1.6 beta3)&lt;br /&gt;
V_POS&lt;br /&gt;
Q_CAR_ROTATION&lt;br /&gt;
V_CAR_SPEED&lt;br /&gt;
I_CAR_DAMAGE&lt;br /&gt;
F_CAR_HEALTH&lt;br /&gt;
F_CAR_TURRETX&lt;br /&gt;
F_CAR_TURRETY&lt;br /&gt;
B_CROUCHING (since v1.8 beta 4)&lt;br /&gt;
B_RELOADING (since v1.8 beta 4)&lt;br /&gt;
B_AIM_UPDATE (since v1.8 beta 4)&lt;br /&gt;
&amp;lt;/source&amp;gt;&amp;lt;/big&amp;gt;&lt;/div&gt;</summary>
		<author><name>Habi</name></author>
	</entry>
	<entry>
		<id>https://npc-for-vcmp.sourceforge.io/wikiw/index.php?title=Field&amp;diff=1877</id>
		<title>Field</title>
		<link rel="alternate" type="text/html" href="https://npc-for-vcmp.sourceforge.io/wikiw/index.php?title=Field&amp;diff=1877"/>
		<updated>2024-10-23T10:27:09Z</updated>

		<summary type="html">&lt;p&gt;Habi: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;big&amp;gt;To be used with [[SetLocalValue]]. I_xx means integer, F_yy means float and V_ means vector. &lt;br /&gt;
For example &amp;lt;source inline&amp;gt;GetLocalValue(F_CAR_HEALTH)&amp;lt;/source&amp;gt; returns the health of the car in which npc is currently sitting.&lt;br /&gt;
&amp;lt;source lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
I_KEYS &lt;br /&gt;
F_POSX&lt;br /&gt;
F_POSY&lt;br /&gt;
F_POSZ&lt;br /&gt;
F_ANGLE&lt;br /&gt;
I_HEALTH&lt;br /&gt;
I_ARMOUR&lt;br /&gt;
I_CURWEP&lt;br /&gt;
I_CURWEP_AMMO &lt;br /&gt;
I_ACTION (since 1.7 beta2)&lt;br /&gt;
V_ONFOOT_SPEED (since v1.6 beta3)&lt;br /&gt;
V_AIMPOS (since v1.6 beta3)&lt;br /&gt;
V_AIMDIR (since v1.6 beta3)&lt;br /&gt;
V_POS&lt;br /&gt;
Q_CAR_ROTATION&lt;br /&gt;
V_CAR_SPEED&lt;br /&gt;
I_CAR_DAMAGE&lt;br /&gt;
F_CAR_HEALTH&lt;br /&gt;
F_CAR_TURRETX&lt;br /&gt;
F_CAR_TURRETY&lt;br /&gt;
B_CROUCHING (since v1.8 beta 4)&lt;br /&gt;
B_RELOADING (since v1.8 beta 4)&lt;br /&gt;
&amp;lt;/source&amp;gt;&amp;lt;/big&amp;gt;&lt;/div&gt;</summary>
		<author><name>Habi</name></author>
	</entry>
	<entry>
		<id>https://npc-for-vcmp.sourceforge.io/wikiw/index.php?title=Field&amp;diff=1876</id>
		<title>Field</title>
		<link rel="alternate" type="text/html" href="https://npc-for-vcmp.sourceforge.io/wikiw/index.php?title=Field&amp;diff=1876"/>
		<updated>2024-10-23T10:26:46Z</updated>

		<summary type="html">&lt;p&gt;Habi: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;big&amp;gt;To be used with [[SetLocalValue]]. I_xx means integer, F_yy means float and V_ means vector. &lt;br /&gt;
For example &amp;lt;source inline&amp;gt;GetLocalValue(F_CAR_HEALTH)&amp;lt;/source&amp;gt; returns the health of the car in which npc is currently sitting.&lt;br /&gt;
&amp;lt;source lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
I_KEYS &lt;br /&gt;
F_POSX&lt;br /&gt;
F_POSY&lt;br /&gt;
F_POSZ&lt;br /&gt;
F_ANGLE&lt;br /&gt;
I_HEALTH&lt;br /&gt;
I_ARMOUR&lt;br /&gt;
I_CURWEP&lt;br /&gt;
I_CURWEP_AMMO &lt;br /&gt;
I_ACTION (since 1.7 beta2)&lt;br /&gt;
V_ONFOOT_SPEED (since v1.6 beta3)&lt;br /&gt;
V_AIMPOS (since v1.6 beta3)&lt;br /&gt;
V_AIMDIR (since v1.6 beta3)&lt;br /&gt;
V_POS&lt;br /&gt;
Q_CAR_ROTATION&lt;br /&gt;
V_CAR_SPEED&lt;br /&gt;
I_CAR_DAMAGE&lt;br /&gt;
F_CAR_HEALTH&lt;br /&gt;
F_CAR_TURRETX&lt;br /&gt;
F_CAR_TURRETY&lt;br /&gt;
B_CROUCHING&lt;br /&gt;
B_RELOADING&lt;br /&gt;
&amp;lt;/source&amp;gt;&amp;lt;/big&amp;gt;&lt;/div&gt;</summary>
		<author><name>Habi</name></author>
	</entry>
	<entry>
		<id>https://npc-for-vcmp.sourceforge.io/wikiw/index.php?title=FireBullet&amp;diff=1875</id>
		<title>FireBullet</title>
		<link rel="alternate" type="text/html" href="https://npc-for-vcmp.sourceforge.io/wikiw/index.php?title=FireBullet&amp;diff=1875"/>
		<updated>2024-10-23T10:20:40Z</updated>

		<summary type="html">&lt;p&gt;Habi: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;poem style=&amp;quot;border: 2px solid #d6d2c5; background-color: #f9f4e6; padding: 1em;&amp;quot;&amp;gt;&lt;br /&gt;
This function was added in v1.8 beta 4 and will not work in previous versions.&lt;br /&gt;
&amp;lt;/poem&amp;gt;&lt;br /&gt;
{{Welcome|&lt;br /&gt;
desc=This will send a bullet-fired packet to server.|&lt;br /&gt;
params=&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;( weaponid, posx, posy, posz)&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&amp;lt;poem&amp;gt;::weaponid: The ID of the weapon whose bullet is fired&lt;br /&gt;
::posx : The x co-ordinate of bullet-origin position&lt;br /&gt;
::posy : The y co-ordinate of bullet-origin position&lt;br /&gt;
::posz : The z co-ordinate of bullet-origin position&lt;br /&gt;
::The posx, posy are approximately same as that of npc&#039;s position. However posz when given must be slightly greater (+0.5) than npc&#039;s z-coordinate.&lt;br /&gt;
&amp;lt;/poem&amp;gt;|&lt;br /&gt;
example=&amp;lt;source lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
FireBullet(26, GetMyPos().x, GetMyPos().y, GetMyPos().z+0.5 );&lt;br /&gt;
&amp;lt;/source&amp;gt;|&lt;br /&gt;
note=It has been found on testing that when the posx, posy and posz are invalid, (0,0,0) for example then the npc shoots correctly according to value in aimdir. This solves problem like bullet firing above gun or below gun and timings of fire. &lt;br /&gt;
&amp;lt;source lang=lua&amp;gt;FireBullet(weaponid, 0, 0, 0 )&amp;lt;/source&amp;gt;&lt;br /&gt;
In above code, subsequent calls to FireBullet may not be required. npc fires as long as onfoot-sync data is send.&lt;br /&gt;
|&lt;br /&gt;
retvals=The function always returns null.|&lt;br /&gt;
relfuncs=&lt;br /&gt;
*[[FireSniperRifle]]&lt;br /&gt;
*[[FireSniperRifleEx]]&lt;br /&gt;
}}&lt;/div&gt;</summary>
		<author><name>Habi</name></author>
	</entry>
	<entry>
		<id>https://npc-for-vcmp.sourceforge.io/wikiw/index.php?title=FireBullet&amp;diff=1874</id>
		<title>FireBullet</title>
		<link rel="alternate" type="text/html" href="https://npc-for-vcmp.sourceforge.io/wikiw/index.php?title=FireBullet&amp;diff=1874"/>
		<updated>2024-10-23T10:18:59Z</updated>

		<summary type="html">&lt;p&gt;Habi: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;poem style=&amp;quot;border: 2px solid #d6d2c5; background-color: #f9f4e6; padding: 1em;&amp;quot;&amp;gt;&lt;br /&gt;
This function was added in v1.8 beta 4 and will not work in previous versions.&lt;br /&gt;
&amp;lt;/poem&amp;gt;&lt;br /&gt;
{{Welcome|&lt;br /&gt;
desc=This will send a bullet-fired packet to server.|&lt;br /&gt;
params=&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;( weaponid, posx, posy, posz)&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&amp;lt;poem&amp;gt;::weaponid: The ID of the weapon whose bullet is fired&lt;br /&gt;
::posx : The x co-ordinate of bullet-origin position&lt;br /&gt;
::posy : The y co-ordinate of bullet-origin position&lt;br /&gt;
::posz : The z co-ordinate of bullet-origin position&lt;br /&gt;
::The posx, posy are approximately same as that of npc&#039;s position. However posz when given must be slightly greater (+0.5) than npc&#039;s z-coordinate.&lt;br /&gt;
&amp;lt;/poem&amp;gt;|&lt;br /&gt;
example=&amp;lt;source lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
FireBullet(26, GetMyPos().x, GetMyPos().y, GetMyPos().z+0.5 );&lt;br /&gt;
&amp;lt;/source&amp;gt;|&lt;br /&gt;
note=It has been found on testing that when the posx, posy and posz are invalid, (0,0,0) for example then the npc shoots correctly according to value in aimdir. This solves problem like bullet firing above gun or below gun and timings of fire.&lt;br /&gt;
&amp;lt;source lang=lua&amp;gt;FireBullet(weaponid, 0, 0, 0 )&amp;lt;/source&amp;gt;|&lt;br /&gt;
retvals=The function always returns null.|&lt;br /&gt;
relfuncs=&lt;br /&gt;
*[[FireSniperRifle]]&lt;br /&gt;
*[[FireSniperRifleEx]]&lt;br /&gt;
}}&lt;/div&gt;</summary>
		<author><name>Habi</name></author>
	</entry>
	<entry>
		<id>https://npc-for-vcmp.sourceforge.io/wikiw/index.php?title=FireBullet&amp;diff=1873</id>
		<title>FireBullet</title>
		<link rel="alternate" type="text/html" href="https://npc-for-vcmp.sourceforge.io/wikiw/index.php?title=FireBullet&amp;diff=1873"/>
		<updated>2024-10-23T10:16:16Z</updated>

		<summary type="html">&lt;p&gt;Habi: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;poem style=&amp;quot;border: 2px solid #d6d2c5; background-color: #f9f4e6; padding: 1em;&amp;quot;&amp;gt;&lt;br /&gt;
This function was added in v1.8 beta 4 and will not work in previous versions.&lt;br /&gt;
&amp;lt;/poem&amp;gt;&lt;br /&gt;
{{Welcome|&lt;br /&gt;
desc=This will send a bullet-fired packet to server.|&lt;br /&gt;
params=&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;( weaponid, posx, posy, posz)&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&amp;lt;poem&amp;gt;::weaponid: The ID of the weapon whose bullet is fired&lt;br /&gt;
::posx : The x co-ordinate of bullet-origin position&lt;br /&gt;
::posy : The y co-ordinate of bullet-origin position&lt;br /&gt;
::posz : The z co-ordinate of bullet-origin position&lt;br /&gt;
::The posx, posy are approximately same as that of npc&#039;s position. However posz when given must be slightly greater (+0.5) than npc&#039;s z-coordinate.&lt;br /&gt;
&amp;lt;/poem&amp;gt;|&lt;br /&gt;
example=&amp;lt;source lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
FireBullet(26, GetMyPos().x, GetMyPos().y, GetMyPos().z+0.5 );&lt;br /&gt;
&amp;lt;/source&amp;gt;|&lt;br /&gt;
note=It has been found on testing that when the posx, posy and posz are invalid, (0,0,0) for example then the npc shoots correctly according to value in aimdir. This solves problem like bullet firing above gun or below gun and timings of fire.|&lt;br /&gt;
retvals=The function always returns null.|&lt;br /&gt;
relfuncs=&lt;br /&gt;
*[[FireSniperRifle]]&lt;br /&gt;
*[[FireSniperRifleEx]]&lt;br /&gt;
}}&lt;/div&gt;</summary>
		<author><name>Habi</name></author>
	</entry>
</feed>