IMG

 
IMG
IMG   IMG
  Welcome to GTAForums! Be sure to check out the Grand Theft Auto V Forum.

You are not registered! (If you are, click here to login) Registering is fast, free and easy and allows you to instantly reply to any topic on GTAForums.
Why wait? Click here to register your own unique username and become part of the ever-growing community!


( Log In | Register | Revalidate Validation E-mail )
Quick Log-In:
  IMG
       
>
Forum Rules GTA Modification Forums

Please post mod releases in the Mod Showroom

GTAGarage.com
free mod hosting from GTANet, simply login with your GTAForums account details

GTAModding.com
GTANet's modding wiki

GTA Modding Chatroom
provided by irc.gtanet.com (Don't have an IRC client? Click here)


Pages: (12) « First ... 4 5 [6] 7 8 ... Last »  ( Go to first unread post ) Closed TopicStart new topicStart Poll

 The Modders Lounge

 Ideas/Feedback/Suggestions
 
Ify24  
Posted: Tuesday, Jul 31 2012, 18:12
Quote Post


0x00000000 --> invisible
Group Icon
Group: Members
Joined: Aug 17, 2011

yu.gif

XXXXX



Oh silly me.

Thanks guys.

EDIT:

So, as you may noticed, I am making a new health bar.
I will use it for my mod.

And I need a little help.

So here is the script:

CODE
// Thread: Health
:HEALTH
thread 'HEALTH'
wait 100 ms

:HEALTH_1
wait 0 ms
0223: set_actor $PLAYER_ACTOR health_to 90
0390: load_txd_dictionary 'BAR'
038F: load_texture "BARONELO" as 1 // Load dictionary with 0390 first
038F: load_texture "BARONELO1" as 2 // Load dictionary with 0390 first
03F0: enable_text_draw 1

:DRAW
wait 0 ms
0226: $HEALTH = actor $PLAYER_ACTOR health
03E3: set_texture_to_be_drawn_antialiased 1
038D: draw_texture 1 position 209.5 415.0 size 120.0 12.0 RGBA 255 255 255 255
:Check_5
wait 0 ms
if
 not $HEALTH > 85
jf @DRAW
jump @DRAW_2

:DRAW_2
wait 1 ms
03E3: set_texture_to_be_drawn_antialiased 1
038D: draw_texture 2 position 209.5 415.0 size 120.0 12.0 RGBA 255 255 255 255
jump @DRAW_2


This is just a example.

So basicly what I will be doing is drawing new texture whenever will player loss or gain health.

But there is a little 'problem' in script.

First bar baronelo is blinking until baronelo1 is drawn.

And I knew this will happen, but how to fix it?

This post has been edited by Ify24 on Wednesday, Aug 1 2012, 11:51
PM
  Top
 

 
oksa8  
Posted: Thursday, Aug 2 2012, 15:14
Quote Post


Just call me Oksu
Group Icon
Group: Members
Joined: Sep 30, 2010

sf.gif

Member Award




@ify24

Remove second "wait 0 ms", un-needed.
Users WebsitePM
  Top
 

 
Ify24  
Posted: Thursday, Aug 2 2012, 19:40
Quote Post


0x00000000 --> invisible
Group Icon
Group: Members
Joined: Aug 17, 2011

yu.gif

XXXXX



QUOTE (oksa8 @ Thursday, Aug 2 2012, 15:14)
@ify24

Remove second "wait 0 ms", un-needed.

Thanks
PM
  Top
 

 
fireguy109  
Posted: Wednesday, Aug 8 2012, 05:30
Quote Post


Chronic post editor.
Group Icon
Group: Leone Family Mafia
Joined: Aug 30, 2010

us.gif

XXXXX



Howdy. Can somebody test this script in Vice City for me? Just drive to the icon in any car and stop in the garage, then follow the readme. All I need is a verification that each feature works, and a screenshot of the menu and garage if possible (not that big a deal). Thanks in advance.

The script - http://upload.tjbp.net/vcgarage2_2.zip
Users WebsitePMPlayStation Network
  Top
 

 
Mister X  
Posted: Wednesday, Aug 8 2012, 09:11
Quote Post


Square Civilian
Group Icon
Group: Members
Joined: Dec 25, 2007

XXXXX



Someone can help me?

I'm really shame opening thread for every silly thing,so I think someone can help me from here happy.gif

I'm doing a script on some pickup. The problem is: for some problem,I cannot use the opcode "if picked up" because it's a Bribe,and if anyone has ever picked up a single bribe the IF would return me every time YES,so the script f*cked up very soon. So,I must use another way: if the player is near the bribe (VERY close),I clear the wanted level. Easy:

CODE
00D6: if
8039:   not  7@ == 0 // integer values
80F6:   not player $PLAYER_CHAR 0 -1093.1843 -711.0524 11.7914 radius 2.0 2.0 2.0
004D: jump_if_false @LABELBRIBEPICKED


Off course,doesn't work if I'm on a vehicle (it doesn't never jump on desidered label).. I used EVERY opcode related to player-vehicle,but I can't do it work...Some advice? So what opcode I can use to check if player vehicle is "going" into that coordinates?

Unfortunatelly I'm coding Vice City,so it's hard to find good opcode.

This post has been edited by Mister X on Wednesday, Aug 8 2012, 09:21
PM
  Top
 

 
SilentPL  
Posted: Wednesday, Aug 8 2012, 11:49
Quote Post


Senior File Manager
Group Icon
Group: Members
Joined: Feb 1, 2010

pl.gif

Member Award




QUOTE (Mister X @ Wednesday, Aug 8 2012, 11:11)
I'm doing a script on some pickup. The problem is: for some problem,I cannot use the opcode "if picked up" because it's a Bribe,and if anyone has ever picked up a single bribe the IF would return me every time YES,so the script f*cked up very soon. So,I must use another way: if the player is near the bribe (VERY close),I clear the wanted level.

Bribes clear wanted level automatically, no need to code anything in SCM.
Users WebsitePMMSNXbox Live
  Top
 

 
Mister X  
Posted: Wednesday, Aug 8 2012, 12:35
Quote Post


Square Civilian
Group Icon
Group: Members
Joined: Dec 25, 2007

XXXXX



QUOTE (SilentPL @ Wednesday, Aug 8 2012, 11:49)
QUOTE (Mister X @ Wednesday, Aug 8 2012, 11:11)
I'm doing a script on some pickup. The problem is: for some problem,I cannot use the opcode "if picked up" because it's a Bribe,and if anyone has ever picked up a single bribe the IF would return me every time YES,so the script f*cked up very soon. So,I must use another way: if the player is near the bribe (VERY close),I clear the wanted level.

Bribes clear wanted level automatically, no need to code anything in SCM.

Yup,I know. But that bribe delete ALL wanted stars at once.

So I must code that. Work on foot,doesn't work (obliviously,opcode 80F6 work only on foot) on car.
PM
  Top
 

 
JACK JONES  
Posted: Wednesday, Aug 8 2012, 12:47
Quote Post


Booom!!!
Group Icon
Group: Members
Joined: Dec 6, 2011

sr.gif

XXXXX



Did you try this:
CODE
{$CLEO .cs}
thread 'Jack'

:0
wait 250
if
0256:   player $PLAYER_CHAR defined
jf @0
0213: 0@ = create_pickup -4 type 15 at X Y Z // define this coord

:1
wait 0
if
0214:   pickup 0@ picked_up
jf @1
010D: set_player $PLAYER_CHAR wanted_level_to 6
05DC: end_custom_thread
PM
  Top
 

 
Mister X  
Posted: Wednesday, Aug 8 2012, 13:40
Quote Post


Square Civilian
Group Icon
Group: Members
Joined: Dec 25, 2007

XXXXX



QUOTE (JACK JONES @ Wednesday, Aug 8 2012, 12:47)
Did you try this:
CODE
{$CLEO .cs}
thread 'Jack'

:0
wait 250
if
0256:   player $PLAYER_CHAR defined
jf @0
0213: 0@ = create_pickup -4 type 15 at X Y Z // define this coord

:1
wait 0
if
0214:   pickup 0@ picked_up
jf @1
010D: set_player $PLAYER_CHAR wanted_level_to 6
05DC: end_custom_thread

Yup biggrin.gif

First thing I tried.


But it suffer a "strange" problem: after some test,I discovered that if the player has ever picked up at least one bribe (even the original ones in city) the

CODE
0214:   pickup 0@ picked_up
return every time YES.

This happen ONLY with bribe: some custom pickup and other kind works well. In fact,with other pickup I only use,simply,the 0214 opcode.


So doesn't work...I've done "that" trick (posted previously) and works good,but it doesn't work if I drive onto it with vehicle like normal bribe because

CODE
80F6:   not player $PLAYER_CHAR 0 -1093.1843 -711.0524 11.7914 radius 2.0 2.0 2.0


refer to a "on foot" player. I must find an opcode that work even on a car.
PM
  Top
 

 
SilentPL  
Posted: Wednesday, Aug 8 2012, 13:42
Quote Post


Senior File Manager
Group Icon
Group: Members
Joined: Feb 1, 2010

pl.gif

Member Award




Just recreate the bribe after player has picked it up. Wait 30 seconds or so before doing this and voila.
Users WebsitePMMSNXbox Live
  Top
 

 
Mister X  
Posted: Wednesday, Aug 8 2012, 14:01
Quote Post


Square Civilian
Group Icon
Group: Members
Joined: Dec 25, 2007

XXXXX



QUOTE (SilentPL @ Wednesday, Aug 8 2012, 13:42)
Just recreate the bribe after player has picked it up. Wait 30 seconds or so before doing this and voila.

Too bad: I cannot make a 30000 wait because the script manage several thing that happen around the city happy.gif

If I cannot find a good opcode to insert into "that" if,I leave it in that way.---
PM
  Top
 

 
fireguy109  
Posted: Wednesday, Aug 8 2012, 14:08
Quote Post


Chronic post editor.
Group Icon
Group: Leone Family Mafia
Joined: Aug 30, 2010

us.gif

XXXXX



Use a varuable like 32@ that increases by 1 each millisecond. Set this = 0 and then just do a check to see if it > 29999, which is 30 seconds. You can probably build in other loops if you do that.
Users WebsitePMPlayStation Network
  Top
 

 
Ify24  
Posted: Wednesday, Aug 8 2012, 17:02
Quote Post


0x00000000 --> invisible
Group Icon
Group: Members
Joined: Aug 17, 2011

yu.gif

XXXXX



What is the ID number of object #GRASSPLANT ?
PM
  Top
 

 
JACK JONES  
Posted: Wednesday, Aug 8 2012, 17:14
Quote Post


Booom!!!
Group Icon
Group: Members
Joined: Dec 6, 2011

sr.gif

XXXXX



At the begining of the main.scm file you'll find all of the object number IDs. It looks like this:
CODE
DEFINE OBJECT INFO                     // Object number -1

In this case the object ID is -1
PM
  Top
 

 
Ify24  
Posted: Wednesday, Aug 8 2012, 17:16
Quote Post


0x00000000 --> invisible
Group Icon
Group: Members
Joined: Aug 17, 2011

yu.gif

XXXXX



QUOTE (JACK JONES @ Wednesday, Aug 8 2012, 17:14)
At the begining of the main.scm file you'll find all of the object number IDs. It looks like this:
CODE
DEFINE OBJECT INFO                     // Object number -1

In this case the object ID is -1

Oh, I forgot, thanks
PM
  Top
 

 
Link2012  
Posted: Wednesday, Aug 8 2012, 18:13
Quote Post


Wut?
Group Icon
Group: Members
Joined: Jan 30, 2011

ba.gif

XXXXX



This is not a ID at all, It's a reference to a ID, it can vary from main to main, it's best to check in the IDE files.
PMMSN
  Top
 

 
Ify24  
Posted: Wednesday, Aug 8 2012, 19:59
Quote Post


0x00000000 --> invisible
Group Icon
Group: Members
Joined: Aug 17, 2011

yu.gif

XXXXX



QUOTE (Link2012 @ Wednesday, Aug 8 2012, 18:13)
This is not a ID at all, It's a reference to a ID, it can vary from main to main, it's best to check in the IDE files.

Yeah, but it's fine to use to creat a object. That's why I needed it
PM
  Top
 

 
Deji  
Posted: Wednesday, Aug 8 2012, 20:27
Quote Post


Coding like a Rockstar!
Group Icon
Group: Members
Joined: Dec 24, 2007

ja.gif

XXXXX



Just write #INFO, select it and press Ctrl+Alt+H and Sanny Builder will convert it to a working model ID.
Users WebsitePM
  Top
 

 
Link2012  
Posted: Thursday, Aug 9 2012, 02:29
Quote Post


Wut?
Group Icon
Group: Members
Joined: Jan 30, 2011

ba.gif

XXXXX



QUOTE (Ify24 @ Wednesday, Aug 8 2012, 16:59)
QUOTE (Link2012 @ Wednesday, Aug 8 2012, 18:13)
This is not a ID at all, It's a reference to a ID, it can vary from main to main, it's best to check in the IDE files.

Yeah, but it's fine to use to creat a object. That's why I needed it

Will be same thing, will vary on each main, if you put -1 in the create_object and the user has a stripped main without any model reference, I don't know the behaviour of your script, but for sure will not create the object that you want.
PMMSN
  Top
 

 
HeresOtis  
Posted: Thursday, Aug 9 2012, 02:54
Quote Post


Mark Chump
Group Icon
Group: Members
Joined: Apr 29, 2011

XXXXX



How would one spawn a car by using test cheat opcode? This snippet of coding seems to be slow, as I type the name, the car takes about 100-1000 milliseconds to spawn (I'm guessing it waits until the code loops back to that specific car model). How can this code be better?

CODE
for 1@ = 400 to 612 step 1
   wait 0
   if or
       0A01:   model 1@ car
       0820:   model 1@ heli
   then    
       0ADB: 2@v = car_model 1@ name
//        0AD0: show_formatted_text_lowpriority "%s" time 100 2@v
       if
           0ADC:   test_cheat 2@v
       then
       
           repeat
               Model.Load(1@)
               wait 0
           until Model.Available(1@)
           
           00A5: 0@ = create_car 1@ at 0.0 0.0 0.0
           Car.RemoveReferences(0@)
           
       end
   end
end
PM
  Top
 

 

0 User(s) are reading this topic (0 Guests and 0 Anonymous Users)

0 Members:

Pages: (12) « First ... 4 5 [6] 7 8 ... Last »

Topic Options Closed TopicStart new topicStart Poll
Search topic for posted by (exact match)



 
IMG IMG