[INC] WInts - Wolly's Interiors -
:wollodya: - 17.01.2010
WInts - Wolly's Interiors
About:
This include, I wanted to create a long time but now I realize it even though despite the fact that I do not work in the pawn yet. This is an imitation of the original entry into the interior in the GTA.
Preview:
Video:
Wints
How it works:
The principle is that the car is under the floor, I set up player objective through SetVehicleParamsForPlayer. Under the car is still object, to keep the car under the floor (anyway car is falling down, and down..). The player then sees only the yellow arrow, whereas only that protrudes from the ground and everything else is hidden under the floor.
Disadvantages:
- yellow arrow is paler than the original
- on the map are displayed annoying and unnecessary yellow icons
- arrow disappears (and thus the icons on the map) at a greater distance because of the bug in SA:MP
Detail info:
This script I made haste, and therefore some things are not done professionally. During scripting, I encountered a few bugs, and therefore objects to remake some things differently, I just fix them and go further.
The arrow above the car can not be switched off by SetVehicleParamsForPlayer. Luckily, in 0.3 is streaming of and turns off itself as soon as the car is streamed out. Unfortunately, this is dependent on the settings of streaming distance in the config.
Include streams objects under car for each player separately. Defined max. number of objects.
Include contains a script for effective cut off San Andreas to a number of areas (every value is definable) and the stream of cars only in areas where at least some players, rather in close of areas. Currently, there is set 100 meters. This means that if a player is close to 100 meters of a zone, the zone will be marked as active. It is therefore, to avoid the situation when you stand on the edge of some zone and interior entry is created on the edge of neighboring zone. Although you are only a few meters from entry but not directly in the zone and therefore it don't appears. It is important that the number of zones is not too high so the cycle too onerous. Currently it is cut off to 6 Ч 6 (36 zones), each with a width of 1000 meters plus 100 meters around the "active zone".
As a compromise I recommend to set stream_distance in the server.cfg to 200.0!
The original entries into the interior in SA: MP is shown around at a distance of 40 meters. WInts is set to 50 meters, of course it's possible to change.
Fading screen I have used Seifader from Seif, as it is scripted quite easily and I did not want to deal with other shit that would only stretch time release.
Don't fear of increase the size of compiled file. This is due to the large number of transformations. Eg. MidoStream FS is compiled about 2 megabytes big.
Do not create interiors for some uneven places because the car will stand out on the ground.
Installation and using:
Instalation into your gamemode:
put #include <wints> below #include <a_samp>
Wints_Init(); put into OnGameModeInit public
Wints_Exit(); put into OnGameModeExit public
Wints_OnPlayerConnect(playerid); put into OnPlayerConnect public
Wints_OnPlayerDisconnect(playerid, reason); put into OnPlayerDisconnect public
Wints_OnPlayerInteriorChange(playerid, newinteriorid, oldinteriorid); put into OnPlayerInteriorChange public
put the include file into pawno/include folder
Using the function:
Код:
CreateWInterior(Float:arrowX,Float:arrowY,Float:arrowZ,arrowInterior,Float:targetX,Float:targetY,Float:targetZ,Float:targetAngle,targetInterior);
arrowX, arrowY, arrowZ - coordinates where it will be displayed arrow (just save over /save command, beware!, you should not be saving the position when you are beeing in the vehicle because the arrow will be lower and will cross the floor)
arrowInterior - id of interior where it will be placed arrow (if you place the arrow in any building, for check the current interior use command /interior)
targetX, targetY, targetZ - position where it will spawn a player after entering into the arrow
targetAngle - facing agle of the player on the position the player will be moved
targetInterior - id of the interior where the player will be moved
For example:
Код:
CreateWInterior(2127.5737,2379.4404,10.8203,0,246.3751,109.2462,1003.2188,0.0000,10);
means that the arrow is in position
2127.5737,2379.4404,10.8203 in interior
0 (outside), and entering the player moved to the position
246.3751,109.2462,1003.2188 player with facing angle
0.000000 into the interior
10.
Function
CreateWInterior put into the public
OnGameModeInit.
Credits:
- Seif - Seifader - his Seifader script (fading screen)
- Luk_Ass - some help with scripting
- SpiriX23 - help with testing and providing the server
- CorteZz - creating of the demo video
Conclusion:
I hope that someone makes better and more efficient script like this.
I'm sorry for any spelling mistakes, I hope you all important things.
Some screens from testing:





Update 1.01:
- some small corrections to prevent potential bugs
Download:
PASTEBIN
Re: [INC] WInts - Wolly's Interiors -
pagie1111 - 17.01.2010
Sounds good.
Re: [INC] WInts - Wolly's Interiors -
Cry_Wolf - 17.01.2010
This is amazing man, Thanks ! :P
Re: [INC] WInts - Wolly's Interiors -
Correlli - 17.01.2010
Nice one.
Re: [INC] WInts - Wolly's Interiors -
:wollodya: - 17.01.2010
thanks
Re: [INC] WInts - Wolly's Interiors -
Kurence - 17.01.2010
Quote:
Include streamuje objekty pod autom pre kaћdйho hrбča osobitne. Definovanэ max. počet objektov.
Obsahuje efektнvny script na rozdelenie San Andreas na určitэ počet zуn (vљetko je definovateľnй) a streaming бut len v zуnach v ktorэch je aspoň nejakэ hrбč, teda v blнzkozti nejakej zуny. Momentбlne je tam nastavenэch 100 metrov. To znamenб ћe ak sa hrбč nachбdza na sъradniciach 0 a 0 tak budъ aktнvne 4 okolitй zуny (za predpokladu ћe počet zуn na љнrku je pбrny a v sъradniciach 0 a 0 je stred rohov 4 zуn). Je to preto aby sa nestalo ћe vstup bude na okraji jednej zуny a hrбč bude na okraji vedľajљej zуny. Sнce by bol len pбr metrov od neho ale nebude priamo v zуne a preto sa mu nezobrazн. Dфleћitй je aby počet zуn nebol privysokэ aby cyklus nebol viac zataћujъci ako keby to bolo vobec bez streamovania cez zуny (momentбlne nastavenй na 6 Ч 6, teda 36 zуn, kaћdб so љнrkou 1000 metrov, plus 100 metrov okolo "aktнvne pбsmo".
|
Translate it better
Re: [INC] WInts - Wolly's Interiors -
Correlli - 17.01.2010
Quote:
Originally Posted by Kurence
Translate it better 
|
You also have an English version in the first post.
Re: [INC] WInts - Wolly's Interiors -
:wollodya: - 17.01.2010
Quote:
Originally Posted by Kurence
Translate it better 
|
je to preloženй hneď nadtэm len som to zabudol zmazat :/
Re: [INC] WInts - Wolly's Interiors -
[Ask]Terminator - 17.01.2010
nice , can i know how you made the yellow icons? You used the object id ? ( what's the id ) or another way.. ?
Re: [INC] WInts - Wolly's Interiors -
Correlli - 17.01.2010
Quote:
Originally Posted by Ask.Terminator
nice , can i know how you made the yellow icons? You used the object id ? ( what's the id ) or another way.. ?
|
It's an object, check the script to see the ID.
Re: [INC] WInts - Wolly's Interiors -
Karkanos - 17.01.2010
awesome
Re: [INC] WInts - Wolly's Interiors -
:wollodya: - 17.01.2010
Quote:
Originally Posted by Don Correlli
Quote:
Originally Posted by Ask.Terminator
nice , can i know how you made the yellow icons? You used the object id ? ( what's the id ) or another way.. ?
|
It's an object, check the script to see the ID.
|
read the first post
Quote:
How it works:
The principle is that the car is under the floor, I set up player objective through SetVehicleParamsForPlayer. Under the car is still object, to keep the car under the floor (anyway car is falling down, and down..). The player then sees only the yellow arrow, whereas only that protrudes from the ground and everything else is hidden under the floor.
|
under the floor is an car, with "SetVehicleParamsForPlayer(playerid, vehicleid,
true true);" (player objective)

Re: [INC] WInts - Wolly's Interiors -
Sayaron - 18.01.2010
nice idea
Re: [INC] WInts - Wolly's Interiors -
:wollodya: - 23.01.2010
thanks all
Re: [INC] WInts - Wolly's Interiors -
DRIFT_HUNTER - 23.01.2010
relly nice idea (idk for script i dint test it and im SUX scipter)
Re: [INC] WInts - Wolly's Interiors -
Mr L - 23.01.2010
shit this is amazing i searching about this 1year Thank you very much!
Re: [INC] WInts - Wolly's Interiors -
Mr L - 23.01.2010
can someone tell me how i can instal it? im puting only this CreateWInterior and i got Error
Re: [INC] WInts - Wolly's Interiors -
pierhs - 23.01.2010
CreateWInterior fuctions is added on OnGameModeInit? Like a pickup or something?
Re: [INC] WInts - Wolly's Interiors -
:wollodya: - 23.01.2010
please read the first post ...there are written installation instructions
Re: [INC] WInts - Wolly's Interiors -
Juanxz - 24.01.2010
Error:
Код:
gamemodes\SP.pwn(234) : error 017: undefined symbol "Wints_Init"
Код:
public OnGameModeInit()
{
for (new i = 0; i < MAX_PLAYERS; i++)
{
// Check if player is connected and not a NPC
if (IsPlayerConnected(i) && !IsPlayerNPC(i))
{
// Set the default speed boost for each player
SpeedBoostMultiplier[i] = 1.5;
}
}
Msg = 0;
SetTimer("GlobalAnnouncement",100000,true);
Wints_Init();
SetTimer("UpdateCmdFreq",2000,1);
StartSystem();
SetTimer("AutoR", 1000, 1);
UsePlayerPedAnims();
EnableStuntBonusForAll(true);
AllowInteriorWeapons(true);
SetGameModeText("Stunt/RP/Free Roam/DM");
for(new i = 0; i < 299; i++)
{
What the f is going on here?