Koq Player Ikut mati
3 posters
Halaman 1 dari 1
Koq Player Ikut mati
Info-Obj_player
Information about object: obj_player
Sprite: player
Solid: true
Visible: true
Depth: 0
Persistent: false
Parent: <no parent>
Mask: <same as sprite>
Create Event:
set the health relative to 100
Step Event:
execute code:
if keyboard_check(ord("W"))
{
y-=5
}
if keyboard_check(ord("S"))
{
y+=5
}
if keyboard_check(ord("D"))
{
x+=5
}
if keyboard_check(ord("A"))
{
x-=5
}
image_angle=point_direction(x,y,obj_crosshair.x,obj_crosshair.y)
Keyboard Event for <no key> Key:
start moving in directions 000010000 with speed set relative to 4
Mouse Event for Glob Left Pressed:
execute code:
instance_create(x,y,obj_playerbullet)
Other Event: No More Health:
destroy the instance
--------------------------------------------------------------------------
Info obj_spambot
Information about object: spambot
Sprite: spambot
Solid: true
Visible: true
Depth: 0
Persistent: false
Parent: <no parent>
Mask: <same as sprite>
Create Event:
start moving in directions 010101010 with speed set to 3
set Alarm 0 relative to 2+random(10)
set the health to 100
Alarm Event for alarm 0:
start moving in directions 010101010 with speed set to 3
set Alarm 0 relative to 2+random(10)
Collision Event with object obj_player:
destroy the instance
Collision Event with object obj_playerbullet:
set the health relative to -50
Collision Event with object block:
bounce not precisely against solid objects
Other Event: No More Health:
destroy the instance
--------------------------------------------------
Info for obj_playerbullet
Information about object: obj_playerbullet
Sprite: bullet
Solid: true
Visible: true
Depth: 0
Persistent: false
Parent: <no parent>
Mask: <same as sprite>
Create Event:
execute code:
speed = 10
direction=point_direction(obj_player.x,obj_player.y,obj_crosshair.x,obj_crosshair.y)
Step Event:
execute code:
image_angle=direction
Collision Event with object spambot:
destroy the instance
Information about object: obj_player
Sprite: player
Solid: true
Visible: true
Depth: 0
Persistent: false
Parent: <no parent>
Mask: <same as sprite>
Create Event:
set the health relative to 100
Step Event:
execute code:
if keyboard_check(ord("W"))
{
y-=5
}
if keyboard_check(ord("S"))
{
y+=5
}
if keyboard_check(ord("D"))
{
x+=5
}
if keyboard_check(ord("A"))
{
x-=5
}
image_angle=point_direction(x,y,obj_crosshair.x,obj_crosshair.y)
Keyboard Event for <no key> Key:
start moving in directions 000010000 with speed set relative to 4
Mouse Event for Glob Left Pressed:
execute code:
instance_create(x,y,obj_playerbullet)
Other Event: No More Health:
destroy the instance
--------------------------------------------------------------------------
Info obj_spambot
Information about object: spambot
Sprite: spambot
Solid: true
Visible: true
Depth: 0
Persistent: false
Parent: <no parent>
Mask: <same as sprite>
Create Event:
start moving in directions 010101010 with speed set to 3
set Alarm 0 relative to 2+random(10)
set the health to 100
Alarm Event for alarm 0:
start moving in directions 010101010 with speed set to 3
set Alarm 0 relative to 2+random(10)
Collision Event with object obj_player:
destroy the instance
Collision Event with object obj_playerbullet:
set the health relative to -50
Collision Event with object block:
bounce not precisely against solid objects
Other Event: No More Health:
destroy the instance
--------------------------------------------------
Info for obj_playerbullet
Information about object: obj_playerbullet
Sprite: bullet
Solid: true
Visible: true
Depth: 0
Persistent: false
Parent: <no parent>
Mask: <same as sprite>
Create Event:
execute code:
speed = 10
direction=point_direction(obj_player.x,obj_player.y,obj_crosshair.x,obj_crosshair.y)
Step Event:
execute code:
image_angle=direction
Collision Event with object spambot:
destroy the instance
- Uups:
- Itu kan kodenya mas kevin
Pinneaple Studios- GM Intermediate
-
Jumlah posting : 839
Points : 980
Join date : 06.01.13
Age : 22
Lokasi : Depok :D
Re: Koq Player Ikut mati
Coba code komplit utk collission event spambot dgn objplayerbullet.
Variabel healthnya apa? Ngga boleh sekedar "health" aja lho, krn itu milik objplayernya (jadinya playernya yang mati)
Variabel healthnya apa? Ngga boleh sekedar "health" aja lho, krn itu milik objplayernya (jadinya playernya yang mati)
Re: Koq Player Ikut mati
seep, aku dah bikin custom variables
tapi.....
gimana caranya biar dia hancur, kan aku pake
global.plhealth //untuk player
//dan
global.sphealth //untuk spambot
cara spambotnya mati gmn?
tapi.....
gimana caranya biar dia hancur, kan aku pake
global.plhealth //untuk player
//dan
global.sphealth //untuk spambot
cara spambotnya mati gmn?
Pinneaple Studios- GM Intermediate
-
Jumlah posting : 839
Points : 980
Join date : 06.01.13
Age : 22
Lokasi : Depok :D
Re: Koq Player Ikut mati
meskipun udah kurang dari NOL masih idup si spambot
Pinneaple Studios- GM Intermediate
-
Jumlah posting : 839
Points : 980
Join date : 06.01.13
Age : 22
Lokasi : Depok :D
Re: Koq Player Ikut mati
semua spambotnya mati
Pinneaple Studios- GM Intermediate
-
Jumlah posting : 839
Points : 980
Join date : 06.01.13
Age : 22
Lokasi : Depok :D
Re: Koq Player Ikut mati
kirain spambot cma ad 1
kalo gitu jgn pke global var, pake var biasa aja, jdi di create event (spambot) buat var sphealth = 100 (atau brp pun)
trus gnti global.sphealth jdi sphealth
kalo gitu jgn pke global var, pake var biasa aja, jdi di create event (spambot) buat var sphealth = 100 (atau brp pun)
trus gnti global.sphealth jdi sphealth
Re: Koq Player Ikut mati
langsung mati spambotnya
kasi SS klo bisa
kasi SS klo bisa
Pinneaple Studios- GM Intermediate
-
Jumlah posting : 839
Points : 980
Join date : 06.01.13
Age : 22
Lokasi : Depok :D
Re: Koq Player Ikut mati
Pinneaple Studios wrote:langsung mati spambotnya
kasi SS klo bisa
obj_spambot
Create:
sphealth = 100
Step:
if sphealth <= 0 instance_destroy()
ya kmu tau sndiri kan logika ny gimana?
Similar topics
» beginer mau ikut nimbrung
» block di atas player
» [Ask] Player Nyangkut
» [script] Health bar mengikuti player. For Dyeva
» cara menyimpan informasi player pakai INI files gimana?
» block di atas player
» [Ask] Player Nyangkut
» [script] Health bar mengikuti player. For Dyeva
» cara menyimpan informasi player pakai INI files gimana?
Halaman 1 dari 1
Permissions in this forum:
Anda tidak dapat menjawab topik