Kucikuc24 Posted December 5, 2010 Share Posted December 5, 2010 Hi everybody. One of the biggest problems of modders si how to open Prison Gate. Answer for our question we can find in one .SCO script in TLAD. That is named "stubbs4.sco". I have decompiled version of that script in .cpp file, but code doesnt using NATIVEs, but HEXes and it have a lot of variables and someones are not defined. You can download decompiled .cpp file Here: ->CLICK<- Now, we can start finding some code for it. But my problem is, it looks chaotic and i dont have a lot of time for decrypting. But i think, that code can be here: 0x3e7d3074(L[4605].v0, L[4605].v1, L[4605].v2, &L[4634]);0x7533ec9(4, &L[4338], &L[4339], &L[4340], &L[4341]);0x1d8800e3(L[4634], (((L[4338] * 0x1000000) + (L[4339] * 65536)) + (L[4340] * 256)) + L[4341]);sub_152e0(); My wish is pls try to help my and other modders, what have similar problem. Link to comment Share on other sites More sharing options...
sjaak327 Posted December 5, 2010 Share Posted December 5, 2010 I doubt that section is the right one: ADD_BLIP_FOR_COORD(L[4605].v0, L[4605].v1, L[4605].v2, &L[4634]); GET_HUD_COLOUR(4, &L[4338], &L[4339], &L[4340], &L[4341]); CHANGE_BLIP_COLOUR(L[4634], (((L[4338] * 0x1000000) + (L[4339] * 65536)) + (L[4340] * 256)) + L[4341]); sub_152e0(); I have decompiled all the scripts for you (IV, TLAD, TBOGT, both SP and MP scripts), using ScruffIV (part of sparkIV): Scripts IV Link to comment Share on other sites More sharing options...
FatAssCartman Posted December 5, 2010 Share Posted December 5, 2010 http://www.gtaforums.com/index.php?showtopic=399873 ? Link to comment Share on other sites More sharing options...
Kucikuc24 Posted December 5, 2010 Author Share Posted December 5, 2010 (edited) FatAssCartman: no i need source code Sjaak: THX i will try it it can be here: while (L[4327] <= (L[3905] - 1)){ DELETE_OBJECT(&(L[3905][L[4327] * 21].v0)); CREATE_OBJECT_NO_OFFSET(L[3948][L[4327] * 21].v1, L[3948][L[4327] * 21].v2.v0, L[3948][L[4327] * 21].v2.v1, L[3948][L[4327] * 21].v2.v2, &(L[3948][L[4327] * 21].v0), 1); SET_OBJECT_HEADING(L[3948][L[4327] * 21].v0, L[3948][L[4327] * 21].v17); FREEZE_OBJECT_POSITION(L[3948][L[4327] * 21].v0, 1); L[4327] = L[4327] + 1;} But again undeclared variables... Edited December 5, 2010 by Kucikuc24 Link to comment Share on other sites More sharing options...
Erem Posted December 5, 2010 Share Posted December 5, 2010 L[4327] is simply an iterator. I.e.: i = 0;while (i <= (L[3905] - 1)){ DELETE_OBJECT(&(L[3905][i * 21].v0)); CREATE_OBJECT_NO_OFFSET(L[3948][i * 21].v1, L[3948][i * 21].v2.v0, L[3948][i * 21].v2.v1, L[3948][i * 21].v2.v2, &(L[3948][i * 21].v0), 1); SET_OBJECT_HEADING(L[3948][i * 21].v0, L[3948][i * 21].v17); FREEZE_OBJECT_POSITION(L[3948][i * 21].v0, 1); i = i + 1;} L[3905] and L[3948] appear to be assigned here: L[3905][0 * 21].v2.v0 = -1140,936f;L[3905][0 * 21].v2.v1 = -371,516f;L[3905][0 * 21].v2.v2 = 3,8f;L[3905][0 * 21].v17 = 270.0f;L[3905][0 * 21].v1 = 0x47eed4d0;L[3905][1 * 21].v2.v0 = -1140,936f;L[3905][1 * 21].v2.v1 = -378,051f;L[3905][1 * 21].v2.v2 = 3,8f;L[3905][1 * 21].v17 = 270.0f;L[3905][1 * 21].v1 = 0x99ccf88f;L[3948][0 * 21].v2.v0 = -1140,936f;L[3948][0 * 21].v2.v1 = -371,516f;L[3948][0 * 21].v2.v2 = 3,84f;L[3948][0 * 21].v17 = 270.0f;L[3948][0 * 21].v1 = 0xf372eaae;L[3948][1 * 21].v2.v0 = -1140,936f;L[3948][1 * 21].v2.v1 = -378,051f;L[3948][1 * 21].v2.v2 = 3,84f;L[3948][1 * 21].v17 = 270.0f;L[3948][1 * 21].v1 = 0x9ac26a7e; I struggle to understand these scripts even when they're decompiled, but that looks like four groups of x, y and z co-ordinates (if you read the commas as decimal points), headings and model hashes. Link to comment Share on other sites More sharing options...
Kucikuc24 Posted December 5, 2010 Author Share Posted December 5, 2010 YES ! NOW WE CAN UNLOCK/LOCK PRISON GATE ! SOURCE CODE: SetStateOfClosestDoorOfType(0x47eed4d0, -1140.936f, -371.516f, 3.8f, 0, 0);SetStateOfClosestDoorOfType(0x99ccf88f, -1140.936f, -378.051f, 3.8f, 0, 0); Thanks to everybody who helped, Credits goes to Kucikuc24 a.k.a. Kuci, sjaak327 and Erem ! Link to comment Share on other sites More sharing options...
SA2IV Posted December 5, 2010 Share Posted December 5, 2010 o sweet now i can have it unlocked. Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now